I have created a JS function which executes fine when it's included an the 'onclick' action of standard HTML link tag as follows:
<a href="#" onclick="return fb_CheckPermission('publish_stream');">test</a>
However where I really want to use this function is on the 'onsubmit' action of a form but when I include it as follows the functi...
Hello!
Not a programmer, I begin with xml, html forms and xslt on Mac.
I plan to use a form to post short texts in a xhtml page and invite end users to add some annotations to the said text. The users would select a specific part of the text posted and each annotation would stand for one specific chain of characters.
My goal is to c...
I basically need to check if there is an easier way to do this before I rewrite all the code. I have a fairly large form that I have each input named with []'s on the end so I can loop through via php for easy insertion.
<input type="hidden" name="currentdate[]" value="<?php echo date('mdY'); ?>">
<td><input...
I have form in my view like following
1 <div>
2 <% form_tag facebook_user_path do %>
3 <label>Use my photo and name from facebook?</label><br />
4 <%= check_box_tag 'use_name_and_photo', 'yes', true %>
5 <img src="<%= @user.pic %>" /><% @user.name %>
6
7 <%= submit_tag "Finish", :id => "use_name_and_phot...
Hi,
I have a select form element with 5 options. If option 2 is selected I want to display another form input box (this has a style of display:none initially). How can I attach an event to option 2 so that whenever it is selected the input box is shown otherwise it is hidden. I have this currently but this does not handle is option 2 ...
Hi,
I have a form in a webpage where I would like to put the selected item in a drop down list into a testbox. The code I have till now is the following:
<form action = "">
<select name = "Cities">
<option value="----">--Select--</option>
<option value="roma">Roma</option>...
Given the following HTML form:
<form id="myform">
Company: <input type="text" name="Company" value="ACME, INC."/>
First Name: <input type="text" name="Contact.FirstName" value="Daffy"/>
Last Name: <input type="text" name="Contact.LastName" value="Duck"/>
</form>
What is the best way serialize this form in javascript to a JSON ob...
I have the following code:
$postcode = $form->createElement('text', 'postcode');
$postcode->setLabel('Post code:');
$postcode->addValidator('regex', false,
array('/^[a-z]{1,3}[0-9]{1,3} ?[0-9]{1,3}[a-z]{1,3}$/i'));
$postcode->addFilters(array('StringToUpper'));
$postcode->setRequired(true);
It creates an in...
I got this code in my submit form
<form id="myform" action='hello.php' method='GET'>
<input type="button" name="newWin" onclick="frmSubmitSameWindows();">
<input type="button" name="SameWin" onclick="frmSubmitNewWindows();">
<form>
Then use some js functions in the head;
function frmSubmitSameWindows() {
form.target = '';
f...
this question is like this one, except it's for PHP testing via browser. It's about testing your form input.
Right now, i have a form on a single page. It has 12 input boxes. Every time i test the form, i have write those 12 input boxes in my browser.
i know it's not a specific coding question. This question is more about how to do di...
I need to make a form with a Text Area that accepts lines of script, any kind of script be it javascript, css, html, vbscript, whatever. How can the script be passed to a form post?
EDIT: How can this script be modified so it can be inserted into a Database? Specifically SQL Server 2005
...
I have this following setup, a textarea named with some data in it that may have carriage returns and another textarea that has style='display:none' in order to make it hidden as follows:
<textarea id="myTextarea" onBlur="encryptMyData()"></textarea>
<textarea name="encryptedText" style='display:none'></textarea>
the user enters data ...
I have to design a form with an input inside it. I use background image on the input so it would look like a button. Every time somebody clicks it, it would send $POST, a behavior I want to achieve.
But the problem is about the outline around the form. The outline shows when we click the form. It's minor, but it would be great to make ...
Hello all, I'm very VERY new at this whole web thing. And I'm just very confused in general. Basically, what I want to do is take an input via text using HTML and adding that input to database, table trans. Should be simple but I am lost.
<li>Transaction Number</li>
<li><input type=|text| name=|tnumber| </li> // do i need to use...
Most browser cache form input values. So when user refreshes page, the inputs have same values.
Here's my problem. When user clicks Save, server validates POSTed data (e.g. checked products), and if not valid, sends it back to browser. However, as stated above, even if server clears selection for some values, they may still be selected ...
Hello,
I have a form that is generated on a customer's website (lets say customer.com) with javascript that a user fills out and it sends to my site (app.com). I would like to be able to provide information to the customer such as how effective their AdWords campaign was and what search engines users used to end up filling out the form....
I'm doing this in app/views/mymodel/add.ctp:
<?php echo $form->input('Mymodel.mydatefield'); ?>
And then, in app/controllers/mymodel_controller.php:
function add() {
# ... (if we have some submitted data)
$datestring = $this->data['Mymodel']['mydatefield']['year'] . '-' .
$this->data['Mymodel']['mydatefield'...
I have an form that takes a little while for the server to process. I need to ensure that the user waits and does not attempt to resubmit the form by clicking the button again. I tried using the following jQuery code:
<script type="text/javascript">
$(document).ready(function(){
$("form#my_form").submit(function(){
$('input')....
I want to display an HTML form containing labelled text fields, like this:
First Name: [_____________]
Last Name: [_____________]
Date of Birth: [________]
My obvious approach is to use a <TABLE> and simply place the labels and text fields in its cells, but is there a better way, e.g. a CSS-based approach?
EDIT:...
I have a form that needs to run a php script once the submit button is clicked, it needs to be ajax.
<form method="post" action="index.php" id="entryform" name="entryform">
<input type="submit" name="submit" value="Submit" onclick="JavaScript:xmlhttpPost('/web/ee_web/include/email-notification.php', 'entryform')" />
</form>
In this si...