I have two selectboxes. I just want it something like this, when I select a value in my first selectbox the second selectbox will show. And when I select different value on my first selectbox, my second selectbox will hide. Meaning, there is one value in my first selectbox that has the ability to show the second selectbox.
I am making this button in a JSP file. I am trying to make the button do two things: save changes to a profile and, when clicked, display the text "saved" below it. The former worked until I added an onlick to the button that triggers the "saved" to appear. Does anybody have any idea why this is? I have attached the code below.[code]...
I want to attach a js function to be called when a img is clicked and I'm changing the functions of onclick based on the image. I used setattribute but it doesn't works in IE. So I decided to use object.onclick = somefunction; but my functions are based on parameters and the whole function runs based on the passed parameter.
So I tried: like this object.onclick = "somefunction('"+mat+"')"; but doesn't work. I need a code which can attach the function on click event for both firefox and IE.
I need to cancel the link and execute a function onclick of all the links within the span tag which has a class of "container" assigned. There will be only one span tag with this class applied.
I know you can get a specific tag using:
document.getElementsByTagName('span'), but I am unsure how to get the one with the class="container". I know there is a getAttribute method, just need a pointer or two to put it all together. Once I know how to access the specific links I want do the equivelant of <a href="hello.do?contain=yes" onclick="someFunction(this);return false">Hello</a>. I am thinking I can add a global function or setAttributes. CODE:
I am trying to get the event to attach to the button but it doesn't want to work the way I was thinking it should I keep getting the error Error: this.altme is not a function Source File: http://trainrec.localhost/jstest.php Line: 22
My code (below) works if I place the selectBoxes in different cells on a table. However, what I want is only ONE selectbox displayed at a time, not the 3 different select boxes in 3 different table cells of the table.
I initially want the citySelect to display, but if user clicks option [-- change country --], then the citySelect is REPLACED by the countrySelect. Then, on making a country selection, the countrySelect is REPLACED by a new citySelect which is populated with the new city list.
Is it possible to have an icon next to a hyperlink to a specific document, that when clicked would fire up Outlook's send mail window and automatically add that document as an attachment?? And if so, how?
There will be plenty of these on each page of my site, so the code would have to be small, preferably one line. Or, one script and all the docs could call that.
I have a select box whose options are populated from an xml file,which works fine for showing one option at a time, but what I would like to do is have one of the selections to be to show all of the options at the same time. At the moment I have it working with a checkbox that works off a separate piece of code, but it would be great to have that option within the select box.
I currently have two selectbox, the first for categories and the second for subcategories. When an option from the category selectbox is chosen I would like the subcategory selectbox to be filled with options drawn from an array.
The following code I have works for Chrome and Firefox but not in IE, I would appreciate any help to fix the code or new code which does a similar function.
have a text box which when searched with 3 characters of vendor name will do ajax request and populate the results below the textbox, beside the box are two arrows pointing to a selectbox, when i clcik on the right arrow after the search the vendor name should to added to the select box....similarly after i add required vendor names, I should be able to delete the name from the select box.I have completed the ajax search part of the textbox, and I am stuck with the passing value to the selectbox portion.
Im trying to create a custom selectbox and Im having some problems, with it. What Im trying to do is have a function that loops through all <select> tags and find ones that only have the class name of "select" and then from there they get a custom select box. From there I have a variable passed in order to get the option. I created a few elements and etc... So at this stage Im just trying to get the text from the <option> tag within each individual <li> element and I can't get it working.
as I know this can be done thru jQuery. I have two selectboxes. I just want it something like this, when I select a value in my first selectbox the second selectbox will show. And when I select different value on my first selectbox, my second selectbox will hide. Meaning, there is one value in my first selectbox that has the ability to show the second selectbox.