forms

How can I use decorators to implement my PHP Form class?

I am developing a Form class in PHP responsible for displaying and validating an HTML form. I know generally what the Decorator design pattern is, and I know Zend_Form uses the pattern extensively to provide easy customization to its output of the form. I have looked through the source for Zend_Form, and cannot make heads or tails of h...

How can we create a partial read-only textbox in windows forms c#?

Hi Friends, I want to get details of the names where their surname is fixed(readonly) in the textbox and original name should be typed from the user end....Is there anyway to make it in windows forms...Please help me I would be really thankful. ...

MS Access 2003/2007 - Chart Object on a sub form, not loading when parent forms load

SO I have a subform, that simply has one chart object on it. Its small, and this is the only purpose of this sub. Then I have about 10 forms that each have a sub windows with this form as it's child. I use a UNION query to show the current balance of 10 accounts on each form with this chart for comparative purposes. Everything works fine...

disable autocomplete/pre-populate in IE via HTML?

Demo link: http://elevation-inc.com/dev/test/ieform/ In IE 6/7/8 - if you enter a term into a simple input field, submit the form and then hit the back button - the input field retains the previously submitted term. If you then refresh the page, the value is also retained. How, via HTML, can this pre-population be disabled? We want no...

jQuery - form loaded via ajax.load not responding to click on submit

I'm seeing a strange problem in my jQuery in a Ruby on Rails application: I'm loading content using ajax.load() into an absolute positioned div (modal). The loaded HTML contains a <form>-element with both action and methodparameters as well as a submit-button (input type=submit). I have another form present in the 'main' document (with ...

How do I dynamically add a Dijit widget to a Dojo form?

I'm trying to add a new FilteringSelect widget dynamically to a preexisting form I made out of declarative tags (on page load). prereqs = 0; function addAnotherPrerequisite(){ var newPreReqCursor = dijit.byId("Prerequisite"+(prereqs-1)).domNode; dojo.create("input",{ id:"prerequisite"+prereqs, jsId:"Prerequisi...

A form that writes to excel

I was wondering what the easiest way to write a simple form program or web page that will output to a text file that can be opened in excel easily. I know how to write in C++ but I dont know any GUI and I wanted a simple form. I was thinking I could just write an HTML/PHP page but it has to be able to run without the internet, but I dont...

form trying to open php file

Hi, I'm new to php and I have the following form in my html file: <form id="loginForm" action="login.php" method="post"> <label for="username">Username:</label> <div> <input type="text" name="username" maxlength="255"/> </div> <label for="password">Password:</label> <div> <input type="password" name="...

Pre-populate external website form

Hi, I have a donation form which users fill out and I would like to then send the user to the charities own website with their information already filled in. Is this possible? thanks ...

In rails controllers, how to prevent double submit (when user double-clic submit button or hit enter twice) ?

Well, everything's in the title but I'll explain a little more :-) My rails app contain many forms (Ajaxified or not). To prevent users to submit twice or more some forms, I use Javascript. There's my scenario for a Ajaxified form : the user submit the form (clic or enter) the javascript disable the submit button the rails controlle...

Accessing text in a field placed by JS, via PHP

In PHP, in a particular CMS I am using a custom field, which works like google suggest. As in, for each letter I type an SQL query is performed and matching records are displayed. When clicking on a record it fills the field with that record. I am fairly certain this is all done with JavaScript. I need to know how I can access the res...

Javascript not loading for php generated form

I am using phpBMS, and have made a form, similar to the sample provided. Using the provided input fields, I have made a basic dropdown list containing two items, and a checkbox. I want the checkbox to be selected automatically when one of the options from the dropdown box is selected. Jens F, provided me with a solution to how I shoul...

jQuery impromptu: Form getting submitted even before Yes or No ic clicked

Hi, I am using jquery Impromptu for submitting one of my forms. In the above mentioned URL I am using the Example 2. Now when i try incorporating the same in my form submission, the form is getting submitted even before i clcik on the yes / no button. I am using the following line of code for the form submit <input type="image" name=...

Stop javascript functions from running

I have a few validations happening in the first step of a form. When the next button is clicked, an age verification is run, if it is true then it runs three functions. function checkAge(form) { return false; } else { validate('theForm','email'); hideFormOne(); showPartTwo(); return false; }; and the function is funct...

How to send dinamically generated variables via ajax, using post method.

Ok, the title isn't so easy to understand, i think. First fact: I'm new to ajax. Now on with the show :) I've an html page wich contains a table, some rows and inside any row i checkbox. When i select a checkbox i will to delete the message BUT only when i click a red-button-of-death. Example table    tr(unique_id)       td [checkbox...

When define action for form

When one needs to define action parameter of form ? Across different projects I've seen forms with action defined as {% url app.view parameters %} or simply '/contact/' but also with action = "." . When do we need to provide each type of action ? ...

symfony override BaseForm class howto

I've installed the sfDoctrineGuard plugin. Everything is working, I can use the /sf_guard_user/edit/:id page to edit a user. I didn't like the way the permissions were listed as a select list, I wanted to display them as individual checkboxes split up based on the permission name. To do this I created a custom widget that extends sfWidg...

How to better submit a form?

So I started to make comments module and came to conclusion that I'm not sure how to better do the comment submitting. This is the code I've for comment submitting form. <form action="/rq/comment.php" method="post" id="pcomment" onsubmit="return rq('/rq/comment.php', 'pcomment');"> <input type="hidden" name="pid" value="<?=$id?>"> <div ...

Checkbox checking

Is it a good idea to move checkbox-checking logic out of the markup, specifically the 'checked="checked"' inline script such as <input type="checkbox" name="LikesWork" <%= Model.LikesWork ? "checked=\"checked\"" : "" %> /> and have this be replaced with a some code that takes a dictionary with a javascript (jQuery) selector as the key...

Problems storing content from a form via CMS

I have a MySQL table called sales, containing the fields product, quantity and paid. I am using a CMS like system which has a custom way of doing forms, and custom formfields to use. As far as I can tell, the id given to a formfield is what is used as the table name to insert into. My current form I am using is as follows: <?php ...