URL Link Dependant On User Input In Form
May 28, 2007
I have a form setup on my webpage that grabs a couple pieces of information from the user (ie name, address, etc.) and when the user enters this information and submits the form, the base URL of Code:
View 3 Replies
ADVERTISEMENT
Apr 9, 2010
I have a drop-down box which lists manufacturers of computer products. I want it so that when a user clicks "Other" from the drop-down box, a new input field appears below it which asks them to specify an alternative manufacturer.
<select name="cat" id="cat" onchange="setCategories();">
<option value="components">Components</option>
<option value="pcs">Desktop Computers</option>
<option value="laptops">Laptops/Netbooks</option>
<option value="monitors">Monitors</option>
<option value="drives">Internal Drives</option>
[Code]...
I know it is to do with the "onchange" attribute of the manufacturer input field, but I am new to JavaScript and don't know what code is required for the function to do this.
View 9 Replies
View Related
Sep 19, 2009
I've just started learning jquery and have been trying to use this code which I found on this forum.I want to detect some text (addClients) in the url and add an css id to a list item with the class m1 (li class="m1") - so I get (li class="m1" id="expanded"):
This is what I have so far (which is not working)$(function() {
$(document).ready(function() {
var url = location.pathname;
[code].....
View 3 Replies
View Related
Oct 11, 2011
I need the code for if the user enters in a code into the field for example E1 and clicks submit it'll redirect them to a certain form. And if another user entered in E2 it would redirect them to a DIFFERENT form.
View 2 Replies
View Related
Nov 9, 2011
I am using jquery.validate.js. I am having 2 input fields. The condition is the second input value should not be less than first input value. The second condition is the first input value should not be greater than 2nd value. I tried with different options but it didnt work. Is there any jquery function for this validation? Or pl
View 2 Replies
View Related
Nov 29, 2009
I want to have twelve pages giving details for each month with a navigation link "This Month" allowing the correct page to be loaded.
View 5 Replies
View Related
May 4, 2009
I need to pass user input from a form to one database field. I'm relatively new to JS but the idea I had was to have several form elements and use JS to collect the users input and send all the values through a hidden element. What's happening is the variable names are being sent rather than the values. The code below is only passing to the next page. Limitations: I am editing an intranet site built by a 3rd party so a lot of the files we've been given are encrypted. I cannot change the method to post.
[Code]....
View 3 Replies
View Related
Sep 1, 2011
I'm now working on kind of invoice form which in it the user can add as much input field as he wants.
The problem is that after adding a new input field - the content in the other fields is deleted.
Code:
View 8 Replies
View Related
Jun 17, 2009
I need to grab whatever the user types in an input box and append it to the URL the page is going to, how do I do that?
javascript:var cbobject= document.searchCatForm.inp_searchCat.value; alert(cbobject);
Code:
<form id="searchCatForm" name="searchCatForm" action="catalogue/search?input=" method="post">
<div class="searchField">
<input id="inp_searchCat" name="inp_searchCat" value="Search catalogue"
[Code]....
View 4 Replies
View Related
Jul 23, 2005
I have a form with a select field. Depending on what is selected in this field, I want to display or not display another select field. For example first field asks the user if they drive, if the user selects "NO" the form doesn't change. If they select "YES", another field appears with different makes to chose from. If they change back to "NO" the second field dissapears again.
View 5 Replies
View Related
Jan 17, 2011
I have two input boxes on a form which receive the first and last name of a user. I want to be able to use charAt() to get the first letter in each box and pass it a third box on the same form. is this doable? May I request some help? I was thinking something like the function below would be the starting point --I stand correct, as it is not working.
<script type="text/javascript">
var str="Mossa";
<!--document.write(str.charAt(0));-->
document.write('<INPUT TYPE=text size=2 VALUE="str.charAt(0);">');
var str="Barandao";
[Code]...
View 4 Replies
View Related
Feb 3, 2001
This is probably easy, but I flipped through the first 100 posts and couldn't find a similar question.
I would like to set up a form with multiple radio boxes in a table. The first row containing two selections, second containing 2..... Once the 1st row/column is selected, the 1st row/2nd column automatically displays the information from the first selection.
I am not necessarily looking for exact code on how to do this, just reference points to go to, and preferably suggestions on the best(meaning quickest) language to do this with.
View 1 Replies
View Related
Jan 11, 2012
I have a form with checkboxes and I want a user to be able to select all checkboxes at once and then deselect. I have some code but it only selects and then if I click it doesnt deselect the input items.
What are some other ways to approach this or anyone know why it doesnt work?
$(function () {
$('#selectall').toggle(
function() {
$('#friendslist .sel_emp').attr('checked', 'checked');
[Code].....
View 2 Replies
View Related
Feb 17, 2010
So I am trying to make a form that will eventually take the user to a specified link. It is a form that uses drop down menus. I based this off of someone elses code (with permission :)), but it shows everything <= user input. I cannot for the life of me figure out how to make it only show only one of the next options.here is the JS code:
<script language="JavaScript">
function ShowMenu(num, menu, max)
{
[code]....
View 56 Replies
View Related
Jan 21, 2010
I've made a page to listen to The Dutch Top 2000 ever.. Example : [URL] After that I want my fewers/listeners to put a new youtube link to my database by giving input from my page. Example: [URL] For my database it is required that the input only 7fXaC07X5M8 instead of the complete link. [URL] My probem is how to handle the input in my form by javascript:
<td><input type="text" name="YourLink" size="256 maxlength="256" value="http://www.youtube.com/watch?v=7fXaC07X5M8&feature=player_embedded#"></td>
To a striped link :7fXaC07X5M8 what is accepteble for my database
View 4 Replies
View Related
Jun 17, 2010
I have a small piece of code (taken largely from W3 Schools)that checks that there is a decimal point entered in a form field, but what I really need is to check that the number entered ends in 2 decimal places.
e.g.
10 is Invalid
10.00 is Valid
My current code is below. Can someone explain what I need to do to ensure that the user enters a number including two trailing decimal places please?
[Code]...
View 1 Replies
View Related
Jan 4, 2006
I have a form that collects information about up to 5 items. I would
like the user to be able to select from a drop down menu how many items
for which they want to compare information, and then have the form
change the number of input fields accordingly.
In other words, if the user selects enter info for 3 items, then input
fields for only 3 items are shown, if they change it to 4 items, then a
fourth column shows up in the table with the appropriate input fields.
View 2 Replies
View Related
Nov 7, 2010
I'm just starting up in web design and I have an interesting challenge that I'm hoping can be solved w/java script. I have a site with an application form. When the form is to be submitted, the form data needs to be emailed to the correct person to handle that particular application. However, that can't be determined by anything specific in the form. It can only be determined by the link that they clicked on to get to the form. I really don't want to have 22 identical forms with just a different EmailTo addie, which is what the previous site developer did. Someone please tell me this can be done w/java script? If not w/java script
View 4 Replies
View Related
Aug 30, 2011
I found this forum while running out of ideas and being extremely desperate to fixing a probably small javascript error in a script. the script is supposed to open a small form window that allows the user to input an email address and update it to proceed. the form item is initially unchecked, but as the user clicks it and enter his email address, it updates the value of the email address and the box becomes "checkable". the problem is that with both IE and firefox, the box doesn't close again, doesn't get checkable and basically doesn't work. in the firefox debugging console, I found the following error:
Quote:
The part responsible in the javascript for this section is:
Quote:
And the html code that is supposed to pop up the box is:
Quote:
View 1 Replies
View Related
Dec 8, 2011
Is is possible to compile a link from form input values? Basically I need to compile a url string to fake a CMS search. It's a crude solution but I have no other options at this point.
So, the user fills this in an clicks submit which takes them to whatever url it has complied.
The url is quite complex but consistent, the resulting values will be at certain points in the url
So... http://somesite.com/search.php?categoryid=435834y59?keyword=KEYWORD VALUE?catalogue_number="CATALOGUE NUMBER VALUE"?price_from=PRICE FROM VALUE?
etc
<label for="keyword">Keyword</label>
<input type="text" name="keyword" value="" id="keyword">
<label for="catalogue_number">Catalogue number</label>
<input type="text" name="catalogue_number" value="" id="catalogue_number">
[Code]....
View 4 Replies
View Related
Feb 24, 2009
I need help with user input. I need to restrict the user to input age greater than 17 and weight restricted to the range of 80-300.
My code is not working:
View 6 Replies
View Related
Jun 15, 2011
I am trying to create a text area input filed for user input, and i want to be able to allow the user to format thier text, just like the ones used in this user forum. I am writing my website in html, php, javascript and css with a MySql database. I am trying to understand how to create such an format-able text area for input.
View 1 Replies
View Related
Apr 14, 2011
I'm working on a search engine that is just like google but customized for me and my friends. I have everything working well from the scripts supplied by google however they don't allow image searches. In order to combat this I added a link that links to google images. Is there a way to make the link go to google images and display my search keyword without having to retype it? The site is [URL] if you need to look at it.
View 1 Replies
View Related
Jan 16, 2010
On a single form, I need to capture the users input on this input box
HTML Code:
<p>
<label for="Student ID">Student ID
</label>
<input type="text" name="sesStudID" />
</p>
to this input box HTML Code: <p><label for="User Name">User Name</label><input type="text" name="sesUserName" disabled="disabled" /></p> so as the user inputs to the first input box it will at the same time appear on the second input box.
View 5 Replies
View Related
Apr 17, 2006
I want to restrict the user from being entering the value in <input type="file">. It works fine in IE but not in Mozilla. I am sending my code also which works in IE and not in Mozilla...
View 2 Replies
View Related
Sep 16, 2011
I haven't been able to find out how to get input from the user. What would be the equivalent way to this line of code in javascript?
do {
String str1;
cout << "blah blah code" << endl;
cin >> str1;
[Code].....
I would like to get '10_01_root_raw.txt' as a string variable from the user, so I could use a different text file as needed.
View 2 Replies
View Related