Creating Dynamic Selection Lists On PDA
Jul 23, 2005
Am having difficulty creating a dynamic <select> element using direct
assignment to the element's option array (ie. someElement.option[i]=new
Option(someText, someValue);)
that will work on Palm devices runing Blazer 3.0 or Web Browser 2.0.
The browsers SEEM to be JavaScript1.1+ capable and the script that I
have works on every desktop-based browser, but not the PDA ones....
Any advice? Or is this a known deficiency?
View 3 Replies
ADVERTISEMENT
Jul 20, 2005
I found a web page with 2 selection lists in a form. The contents of
the second selection list are updated based on the entry in the first
selection list. For example:
if the first selection list has all the states in the USA, the second
list will display all the major cities in the selected state.
View 1 Replies
View Related
Mar 12, 2011
I am trying to create a age calculator using selection lists.
User's age in years, months, and days; How long a person has been living in months, days, hours; Days till user's birthday how to calculate it through date functions. How do I get this to work?
View 2 Replies
View Related
Nov 27, 2011
Dependable dropdown lists (4 level)
1 Level dropdown list
2 Level dropdown list
3 Level dropdown list
4 Level dropdown list
Every dropdown list is depends on another dropdown list
For example if I select a value from 1 dropdown list then 2 dropdown list will appear. And then I select a value from 2 dropdown list then 3 dropdown list will appear. And if I select a value from 3 dropdown list then 4 dropdown list. Multiple selection will be enable. It means every dropdown list may have hundreds of values. Thus, In this situation of multiple selection of values I analyze that, use of dropdown isn't suitable because if a dropdown value has 500 related values then these 500 values disturb the page design.
View 2 Replies
View Related
Nov 11, 2010
I'm trying to create/add options to select elements in a form. My form has several select elements, only first is actually populated and visible. Each select element is on a seperate table row. Depending on the option chosen in the first select list, another row (select element) becomes visible which is then populated depending on the option chosen. I accessed the select element and created the option(s) using this format
[Code]...
View 5 Replies
View Related
Jun 29, 2010
how to populate a dropdown based on Another dropdown selection. This all should be a dynamic. Eg: I have two text boxes one is TechID and other is JOB ID. When I start typing Tech ID it suggests me the list of IDs which start with the input string i have put in Tech textbox. When i select the Tech ID the jobs associated to that Tech ID should be displayed in JOB ID text box as a dropdown list.
View 1 Replies
View Related
Aug 15, 2011
I am trying to figure out how to dynamically show/hide certain form elements based on the selection from the drop down list.My form is defined like so[code]...
View 6 Replies
View Related
Jul 23, 2005
I would like to create a box with the same behavior as the "To" field
in the gmail "Compose Email" page.
That is a simple text box but when you start typing it will suddently
show a list of all the e-mails (for our purpose any string would do) in my address
book that have the given substring in it.
E.g. if I type in "ga" I get all the e-mails where the "ga" substing
shows up.
Then I can select from the list and press enter on the requested
address or I can keep typing if the address is not in the list yet.
View 2 Replies
View Related
Jan 13, 2011
I am using a slide show to display all images associated with a product output by SQL in a very simple shopping cart. The problem is I can't think of a way to assign the div a unique class/id used to group the images into multiple slide shows as well as for use with the pager associated with each. My code now places all images (regardless of which product they are associated with) into the same slide show, and I understand why, I just don't know how to alter the jquery to dynamically assign then call them.I could easily fix this if the I was hard coding each product and the photos.Anyone know how to achieve this?
$j(function() {
$j('.album').wrapAll('<div id="productid"></div>');
$j('#productid').cycle({
[code]....
View 3 Replies
View Related
Oct 24, 2009
i want to make a form. the form will have three text fields and with two buttons. what i want with this form is when the user enters the first three fields and if he wants to add more then he will click on add more button and on the same page three more fields will appear below the first three fields. the user will then enter these three fields then if he wants to add more then he will click on add more button. so three more fields will appear below the first six fields. user will enter these fields. he will be allowed to enter upto eight or less than eight times. once he finishes with this then he will click the second button to insert this data into db.
View 5 Replies
View Related
Feb 3, 2011
I'm trying to create a webpage where users can click on a dynamically generated set of questions:
<?php do { ?>
<p><?php echo $row_rsQuestions['question_text']; ?><?php echo $row_rsQuestions['question_type']; ?></p>
<?php } while ($row_rsQuestions = mysql_fetch_assoc($rsQuestions)); ?>
and by clicking on a particular question, there will be an update for their particular listing of personal questions in a MySql database. I know how to create the database update part, but I think that I would need to javascript to:
1) tell my page that it's time to update (i.e. add a particular question as soon as they click it)
2) pass along the correct variable to the database update portion of the page.
View 2 Replies
View Related
Jul 23, 2005
What I'd like to do is have a dropdown box populated with data from a
database. Based on what you select from the drop down a table will be
generated (in this case a 3 column table) from another query to the
database. I will eventually want a way to select one of the rows from
the table, but for now I'd be happy with just generating the table.
I know it will have to deal with DHTML, dom documents, getElementID,
removeNode, recreating the node. What I am not sure about is how to
1) Dynamically create a table
2) Step 1 with data from a database (recordset)
Like I said, I'd also like to be able to select a row from the table.
I'd be happy with making the ros a radio group, though it would be
interesting to be able to select the row. I take it I'd use CSS to
highlight the row selected then.
View 1 Replies
View Related
Mar 15, 2010
I have a form with a list of subjects (radio buttons) that I get from my database with PHP, and I want to show a list of videos (also from my video table using PHP), based on which subject they choose.
I have tried multiple POST, GET methods with JavaScript examples, but cannot get it to work. I am not having any issues with the PHP getting either list, it is just getting the radio buttons to pass either the POST or GET data to JavaScript, and have it take that value so I can get the list from my database with PHP. I tried to use a div for the list of videos, and didn't have much success.
View 6 Replies
View Related
Jul 29, 2009
I read a lot of things now about creating elements with $("<div/>")and the appendTo method.here is my code I'm trying to get to work:
<html>
<head>
<title>Foobar</title>
[code]....
View 1 Replies
View Related
Sep 8, 2010
I have a php script that lists some items which can be checked or unchecked. Now, I am trying to make a javascript that writes a comment field in a certain "span" - comm_'.$i.', where $i starts from 0 - if the check box is already checked (info retrieved from the database) or if the user checks the check box (when the user unchecks the check box the comment field should disappear). The problem is that I am unable to make it work properly (when I check or uncheck a box it doesn't work at all), I mean it only works for the element above, so if box_1 is checked it can only create the comment field in comm_0.
(Part of the) PHP code:
Code:
//Listing the items
<span class="olistr">
<span class="olistc" id="op">
<input type="checkbox" name="box_'.$i.'" " '.($row['state'] == 0?'checked':'').' onClick=javascript:ckState(this,"comm_","Comment",'.$i.')>
</span>
</span> .....
The error I get is - this is similar to the errors I get when checking and unchecking a check box:
Message: 'null' is null or not an object
Line: 64 (this would be line comSpc.innerHTML = 'something1';)
Char: 4
Code: 0
View 1 Replies
View Related
Feb 14, 2009
I'm trying to do the following thing. Create a dynamic selectboxA0 when a button is pushed. Then, when a value is selected in this selectboxA0, there will be dynamically generated another selectboxB0 with content which is different for each option of the first selectboxA0. When the button is pressed another time SelectboxA1 is generated (which will in his turn generate SelecboxB1).
The code I use is the following:
function addProduct(){
var url = "includes/php/catalog/loadcategories.php";
$.post(url,
function(data){
$('<tr id="catalogid'+invoiceProducts+'"><td>Product-categorie</td><td><select name="category'+invoiceProducts+'" id ="category'+invoiceProducts+'">'+data+'</select></td></tr>').appendTo('#invoiceTable');
$("#category"+invoiceProducts).change(
function(){
var currentCatalogField = $("#category"+invoiceProducts).attr("name");
if($('#product'+invoiceProducts).length > 0){
var currentProduct = $('#product'+invoiceProducts);
var category = $('#category'+invoiceProducts).val();
var selectbox = true;
productSelect(category, selectbox);
}else{
var category = $('#category'+invoiceProducts).val();
var selectbox = false;
productSelect(category, selectbox);
}});}, "html");
invoiceProducts++;
}
The problem I have is that everything revolves around a counter (var invoiceProducts). Therefor when I select a value in SelectboxA0, the value of SelectboxB1 will change (instead of B0). Any way to solve this thing, by for example making the object pass itself when it calls the onchange function so I can get the number out of the name/id attribute or something. A
View 5 Replies
View Related
Mar 12, 2010
My application reads an array of URLs in Javascript and displays them in a table. I need to create mouseover events for each of the links (just an alert message for now.) I have tried this a few ways, but for each one the mouseover event fires for each link before anything else is loaded on the page, and when the page is loaded, no link is displayed. Here are the two ways I've tried:
var cell1 = document.createElement("TD");
cell1.innerHTML = '<A HREF= ' + url + 'onMouseOver="' + alert("my alert box"); + '"> my page </A>';
cell1.innerHTML = '<A HREF= "' + url + '"> my page </A>';
cell1.onMouseOver = alert('alert');
I have also tried many variations of these including:
[Code]..
View 3 Replies
View Related
May 17, 2011
I want to create dynamic radio button group with different names.
<script language="javascript">
function changeIt()
{
[code]...
I want to create a radio button group(2 radio buttons on a group) with different name.
View 2 Replies
View Related
May 31, 2006
I'm trying to build an online form which has different recipients. So i'd be something like: Weather user select any of the optiions (where multiple recipients are) depending on that selection that's where the output will go to an specific email address.
View 1 Replies
View Related
Jan 5, 2007
I have the requirement of autoupdating the drop down lists , when a
selectin is done in another drop down box. I dont have a server through
which i can make it dynamic. I have to hard code it in the html. Can
someone suggest anything.
View 4 Replies
View Related
Feb 6, 2006
I have two select lists and depending on the value selected in the
first select dropdown, I want to populate the second list.
I tired a couple of different ways, but for some reason, it works fine
on IE but not on Firefox. On Firefox the second dropdown list doesnt
get populated.
Any pointers on how to populate the second dropdown..
Heres the code:-
for(var j=0;j<array.length;j++)
{
this.document.getElementById("secondSelectName").options[j] = new
Option("txt", "val");
}
for(var j=0;j<array.length;j++)
{
var oOption = document.createElement("OPTION");
secondSelectlist.options.add(oOption);
oOption.innerText = "txt";
oOption.value = "value";
}
for(var j=0;j<array.length;j++)
{
this.document.getElementById("secondSelectName").add(new Option("txt",
"val"));
}
View 4 Replies
View Related
Jul 20, 2005
Supose I have 2 lists on a form, L! and L2. L1 is populated with data L2 is empty.
I want to select some options from L1 and transfer to L2. How can I do that? Is there a function from List object that helps to add dynamically....
View 1 Replies
View Related
Jan 17, 2009
I have this code in the beginning: document.write("<option id='test' value='move" + i + "'>Fire Blast</option>");
How do I edit the text Fire Blast to something else? The Fire Blast part is not attribute, so it can't be edited like:
document.movelist.name = "Something else";
View 2 Replies
View Related
Aug 24, 2009
I've tried w3schools, tizag, and google, but haven't found exactly what I need. I need some way of easily figuring out which option in a drop down menu is checked, through the use of javascript, like how you can use document.formname.elementname[i].checked to find out which checkbox/radio button is checked. Anything that would return something that allows me to figure out which option has been chosen. I will need to have a function with 3 if statements, one for each option.
View 5 Replies
View Related
Nov 4, 2009
On my web page I have 3 seperate catorgories with 2 drop down lists in each, the first dropdown list in each catergory is for "county"
Here is a snippet of the code
I wanted to know if it is possible to use "list.js" to populate all 3 county dropdown lists or would I need "list.js" "list1.js" etc etc
View 10 Replies
View Related
Dec 21, 2010
I'm looking for some help with drop-down lists.The lists below are populated by lists.js (a script that was kindly written by a friend).What I need to happen is that as soon as an option within one of the lists is selected, the other four become disabled.I'm afraid I've no clue where to start (and I think I have prevailed on my friend's patience for long enough!)
<html>
<head>
<script language="javascript" src="lists.js"></script>
[code]....
View 9 Replies
View Related