Is it possible using html or javascript, to allow users to type in a drop-down box if the option they're after doesn't exist in the list of options? I've defintely seen this before at least in a windows applications, and I'm pretty sure I've seen it online as well.
Does anyone know if this is at all possible? The only alternatives to this is to either have drop-down menu AND a textfield (wastes space), or have a little button which switches between the drop-down menu and a textfield. Both of those alternatives aren't ideal.
I cannot remember the site nor the author, but it works BEAUTIFULLY! I have changed the timeoutInterval to 500 milliseconds as I type with one finger - the original was 250 or even less.
<script language="JavaScript"> // script allows you to type more than one character into a drop-down list // //A typical drop-down need to have ONKEYPRESS and ONKEY functions added // //Example: <SELECT ID='vc_DESCRIPTION' NAME='vc_DESCRIPTION' onkeypress='listbox_onkeypress()' onblur='listbox_onblur()'>
var toFind = ""; // keyboard buffer var timeoutID = ""; // process id for timer - when stopping the timeout var timeoutInterval = 500; // milliseconds - keyboard buffer var timeoutCtr = 0; // initialise of timer countdown var timeoutCtrLimit = 3; // number of times timer is allowed to count down var oControl = ""; // maintains a global reference to the user control
function listbox_onkeypress(){
window.clearInterval(timeoutID) oControl = window.event.srcElement; var keycode = window.event.keyCode;
if(keycode >= 32 ){ var c = String.fromCharCode(keycode); c = c.toUpperCase(); toFind += c ; find(); // search the listbox timeoutID = window.setInterval("idle()", timeoutInterval); // restart the timer } }
function listbox_onblur(){ // function is called when user leaves listbox
window.clearInterval(timeoutID); resetToFind(); }
function idle(){ // function is called if timeout expires - 3rd time stops timer and clear kb buffer
I have to change text input type to password input type and i am using jquery script. This script work for FF, Chrome and Safari browser but not worked on ie7, ie8.
Script is as:-
How can i update my script, so that it works cross the browser.
i'm having with a superfish menu i have tried to add to my wordpress site.The menu seems to work fine for the base-level (top parent pages) menu items.But the drop down menus seem to flash on screen for just a second and then disappear when the mouse hovers over the menu items.To see an example, please check out the top menu on this temporary development page: http:[url].....I have tried adjusting the z-index in superfish.css file but it doesn't seem to be having any effect.
I am implementing auto re-order drop down values in asp.net. My requirement is something: I have five drop down and each has populated using 1 to 5 values. when I changevalue from dropdown, other drop down values(numberordering)should change automatically.
I created a drop down menu for my search bar on my website using JQuery / hover intent..The drop down is activated by the user hovering over a button, and inside there are twocombo boxesand acheck box.If the user tries to choose an option in the combo box, thedrop downdisappears..Chrome, Safari, Opera and FireFox are working fine, but IE7 + 8 have this problemI have uploaded an image of the drop down with the combo box, it is a print screen of itworkingin Chrome--> The second image is where the bug happens in IE
I currently have a Drop-Down menu, which has headers you click on to show the links. This menu only allows one drop to be expanded at a time, and can be viewed here [url].
I would like the headers to be able to have 'sub-headers' inside, which also drop-down,to reveal the links. I want them to have a different header colour, and to have the same rule where only one can be open at a time. while keeping the rule with the main headers.
I have been searching for a long time but have been unsuccessful on how to develop a drop down menu but have the menu items show in a list above the main nav. Not below. I really like the way this functions:[URL].. But I would like the item in the list to appear above the main nav so it animates up not down. Can anyone help me on how to alter this js code to perform this task?
Here is the jQuery file link:[URl].. I tried going through this js file but it very complex. Can anyone tell me what I need to change to have the animation roll up instead of down?
So, what it does: You can successfully drag something anywhere, but when you click it again, it resets to its original position (I don't know why), and when you try to drag it again, as soon as your cursor touches the object it disappears (I don't know why). why it is happening and how to fix it!
// JavaScript Document var posX; var posY; var element;
[Code]....
the html is a simple (position is set to relative):
<p id="square" onmousedown="drag(event)">meep</p>
EDIT: This is the first time I've written javascript code and would like to learn the basics, which is why I am not using a library.
I'm currently redesigning my site, and I have a small quandary.[URL].. Unfortunately, not everyone has the same size monitor as me, therefore sometimes the drop-down menus get cut off. Is there a way with this script for it to auto-detect if it's going past the bottom edge, and when this happens it'll go upwards instead?
I am looking to put a drop down menu in my for i have the drop down set up but i am not sure how to do the make hidden text field pop up when "Other" is selected. I am guessing you use javascript to make this happen
HTML Code: <td><select name="actionrequest" onchange="Select(this,'budget',1);"> <option value="Calibration">Calibration</option> <option value="calibration and repair">Calibration and Repair</option> <option value="repair">Repair</option>
I am trying to create a drop down list which depend to the value selected from the previous drop down list. I can add it without problem, but If I change again the value of the first drop down list I would like to remove the previous drop down list generated from the first value. If I try to remove it when I create the element, it even does not create the element, the remove element function seems to work because when you click on the remove link it works.
iam trying to use 5 drop downs in my form for user to select languages and each select drop down should not allow the user to select the same language again and all my drop downs are populating individually from the DB on the page so if "English" is selected for "dropdown 1" then again "drop down 2" should not allow "English" to be selected.
I believe that this has been answered somewhere but I cannot find it. I have 51 textboxes on page. In 50 I can enter value. 51st should tell me what is average of entered numbers.
As user types I want script to iterate trough form count and sum non-empty fields and than divides this two numbers.I need to sum values from fields that have value (not emty fields) and to divide this number by number of non empty fields. This should occur on every change in any of those 50 textboxes so to have live preview of average.
I'm really new to JS and I don't know even how to sum these numbers.
I have a problem changing the cursor type with javascript. I have a button with an mouseover effect (change of color and cursor type). It works fine in Netscape 7.x and IE 6.x but not in IE 5.5 I'm using the following script:
function change(element,mode) { if (mode=="in") { cursortype = 'pointer' colorval = '#FF491B' } else if (mode=="out") { cursortype = '' colorval = '#F47240' } element.style.cursor=cursortype; element.style.background=colorval; }
The error I'm getting with IE 5.5 is "cursor type not defined..." or something but the pointer is supposed to work even with IE 4.x
I'm a newbie to Javascript, HTML, XHTML, CSS-- and oh god, everything, so please bear with me! I have come to understand that to get any better, I'll need support.
Here is my issue: I'm currently trying to develop a first-draft calculator that will allow me to calculate some values for work and the way I want it requires me to do it with a pair of drop-downs.
Take a look at it here: [url]
I would like to select the first drop-down, on the left-hand side (Current Lighting Products -> Type of Lamp) and for the right-hand side to copy it's selected value (Energy Efficient Products -> Type of Lamp).
Furthermore, it shouldn't interfere with the fact that I'm also using those values with my dependent drop-down, below (Wattage).
Okay I searched (and searched...) and I see the drop down radio button forum but I want to make a drop down dependant drop down. like select option 1 - 70 in list 1 then the second box is changed to fit the possibilities, probably 1 - 20 options for most. I think it could do it with an array but I have never used Java (well no "advanced" stuff.)
If I have this HTML code, the myForm.elements.length is 5, instead of the expected 6. You can click on the image in this case, and it acts like a submit button... proof that the broser recognizes it as part of the form.
So, if I call myForm.elements[4], I get the button, not the image.
It seems goofy to me, and I cannot find any documentation that explains why this is.
Of course, I can get access to the object in many other ways... I am just curious if the is an IE bug.
Some time back we assembled an Explore-type menu system (tree of folders) for a client site which has grown to be a pivotal function of the site in that deep navigation into the South African Education Law all hangs off this structure.
From our side, it has all worked perfectly and the client is about to launch the site, but claims that he has continual problems with some folders opening to pages where files cannot be found, and the menu system then locks up. Fine.... accept that. Except that we cannot replicate the problem. On several machines we have opened the tree structure hundreds of times, and with never a single problem.
The first indication the client has of a problem is when the site loads, and some of the "plus signs" (used to indicate that there are underlying folders) do not show. Just the red background. But if you mouse over where the "plus sign" should be - then the "hand icon" appears and the correct link is shown in the URL box. But if you click to the link it shows "done" but the link won't load. Reverse back to the menus and the buttons now no longer work and most don't display.
This seems to be happening only within the client's site which is a simple Windows Network connecting through a broadband DSL router to the internet. He claims that on three different office machines he can replicate the problem.
The problem is intermittant and will often work fine for an extended session. next visit to the site and the problems will be back.
Could this be a caching issue.? Or older Java engines.? Maybe we should be using a more universal javascripting routine. Sadly our in-house java skills are low and we've just hacked away at public scrips to get this working.....