Close Dropdown When Opening New?
Jun 30, 2009
I have found this show/hide script which I have altered to my needs.
What I want it to do is when I have a list of ex. users, I want to be able to click on a link and it shows some information for that user... This part I have figured out, but when I click on another user I want the previous show to hide and the new one show...
Here is my javascript code...
View 6 Replies
ADVERTISEMENT
Nov 14, 2011
I've managed to do that so when i click on the first tab it will close the other open tab.The problem i'm facing is when i click on the first tab that it supposedly will not open even if clicked.It does not open but from times to times when i click a lot of times , go out of the accordion and then bring the mouse again in and click just right at the bottom of the first tab(the one it cannot be opened) and the second it sometimes open the first tab!!!
My code:
$(function() {
$("#accordion").accordion({
collapsible: true, active: false
});
[Code].....
View 2 Replies
View Related
Jul 6, 2009
Unfortunately I don't know a great deal about javascript. I have used some to construct a collapsible menu on this site : [URL] Unfortunately what it doesn't do is close the previously opened menu item on opening the next. I hope that makes sense. Is there a onclick behaviour I can add to the li's to close any open list items. I downloaded the files and tutorial from here: [URL]
View 2 Replies
View Related
Dec 8, 2011
I have a dropdown list that I use to navigate pages on an external website. Currently, my dropdown list will open a new page in my current window. I want to be able to open the page in a new window. I'm sure it's a simple fix, but being somewhat of a noob to Javascript I can't figure out how to solve it.
View 2 Replies
View Related
Sep 16, 2009
I'm having trouble with hiding a dropdown which is opened when the user clicks on an input.
I can manage to close it when the user clicks on a menu item, but I can't figure it out how to close it when the user clicks outside the menu.
I tried to close it with $("body").click(function() { ... }); which works one time, but the dropdown won't reapper again.
function dropDown() {
$(".dropdown input").click(function() {
var firstLevel = $(this).parent().children("ul");
// expand first level (onclick)
[Code].....
View 1 Replies
View Related
Aug 5, 2009
Is there a way to close the superfish dropdown after click? I have some 'onclick' functions that kick off some behavior and then return false. How do I get the dropdown to go away? I suppose I need to somehow call "hideSuperfishUl"
View 1 Replies
View Related
Jan 29, 2010
I have a HTML and I am opening another link in a separate window using window.open() . The child window is something like 'http://yahoo.com' which is out side html. I need to refresh the parent window when the child window is closed.
View 4 Replies
View Related
Jul 20, 2005
I want to trap the window.close() event when the user clicks on the close button of the browser using javascript. Can anyone shed light on this problem ?
View 1 Replies
View Related
Jul 20, 2005
As per the rather long subject, I would like to (well, my boss would like me to...) on a popup have one button to close and another to close but then redirect to another page.
View 4 Replies
View Related
Nov 16, 2009
Suppose,closing the browser through Browser Close Button(Top Right Corner cross(x) button), i have to execute some ASP script , for that, in body onUnLoad Event calling a fucntion called CloseWin(e,frm), it is working in Internet Explorer successfully , But in FireFox not working. how to solve this problem. or any other way to get the co-ordinates of browser close button( code for both IE and Firefox).
code follows
function CloseWin(e,frm)
{
//frm required for my program
var bButtonClicked = false;
[Code]....
View 1 Replies
View Related
Dec 3, 2011
I want to use a drop down menu and found a horizontal example from John Resig. But I want to turn it into a vertical menu. How can I do that?
View 2 Replies
View Related
Jul 24, 2010
I have a project where I need a selection of one dropdown menu may affect the select of multiple other dropdown menus on the same page.First, a table is generated, and within each row, it contains a dropdown menu. Assume: Rows A, B, C, etc..., and Dropdown selection: 1, 2, & 3If dropdown in Row A selects 2, then I want the selection of dropdowns in rows B & C to dynamically change to 2.And if in Row C user selects 3, then the selection in dropdowns in rows A & B should dynamically change to 3.
View 1 Replies
View Related
Jan 22, 2011
I just needed a simple dropdown. So what better solution than jquery right? Well, when I finished it, I tested it out and it works until you try to click a link in the dropdown. It then disappears. Not sure if theres something overlaying throwing it off but I didn't see anything in firebug.
Website: [url] (hover over the rentals link in the top nav)
Code:
View 1 Replies
View Related
Jul 13, 2010
I have code for autosuggestion while typing in a text box written in Javascript and PHP. When I start typing a number I get a list of matching numbers and I'm able to select one of them with the mouse click. Now I have an other text box which should display a list of numbers based on the selection from the first textbox.
View 3 Replies
View Related
Jun 23, 2011
Using Jquery I want to populate a 2nd dropdown from the choice of the first dropdown.
View 1 Replies
View Related
Oct 14, 2010
The first dropdown has some options as :
abc(a)
bcd(a)
cde(b)
[Code]....
On selecting abc(a) in first dropdown the 'a' must get selected in second dropdown,on selecting cde(b) second dropdown must have 'b' and so on,also the second dropdown value should be disabled(grayed out) for user.Need the code in javascript.
View 4 Replies
View Related
Mar 7, 2010
I have 4 strands of hair left... I have been fighting with this one for almost a week now. I'm trying to pass the value of this dropdown to a function and enable another dropdown(and in the future create the populated dropdown based on this choice). If the original 'Select...' option is chosen it will then hide that second dropdown. In the following code the function actually resides in a js file which has been imported and is working properly. I have tried this as text and as value and both seem to be passing a null value regardless of the option selected.
View 5 Replies
View Related
May 16, 2009
I am using the following code in to open a pop-up window (in Flash hence the actionscript tags ..):
This is working fine. My problem is how to close this window from other pages on the website.
I have tried:
And it is not working. What would be the correct javascript to use to close the pop-up window that is opened using the code above?
View 4 Replies
View Related
Apr 5, 2009
I need to know if the user close the browser or to open the window � browser without or with a disable close window button How can I???
View 6 Replies
View Related
Sep 6, 2011
I have two drop-down prompt controls with month names. One has just one value (say "July") and the other has all the months of the year ("January".."December"). The first prompt control is hidden on the page. How do I set the default selection of the second prompt control to the value present in the first prompt control? So, when the page is run, the second prompt control should automatically show "July".
I was reading up on the selectedIndex property (?), but I know that it won't work because I want Index 0 to be selected in the first control and Index 6 in the second, and I expect it to change every month (next month it will be index 7 that should be automatically selected).
View 2 Replies
View Related
Feb 2, 2009
Ive searched this forum for a simple solution to this. I want have a drop down of countries. Only if USA is selected, it shows states, otherwise it is hidden. I have a function which is 'trying' to write the state dropdown to an empty span.
Code HTML4Strict:
<script>
function test(){
document.usstate.write("<select name='state'><option value='' selected>--</option><option value='New Jersey'>New Jersey</option><option value='New York'>New York</option><option value='California'>California</option></select>");
[Code]....
View 16 Replies
View Related
Apr 7, 2010
- I have a button on my Flash site that opens an HTML page in a popup window. In Flash, I open the new window using Actiosnscript 2.0:
- Within the popup window are links to other HTML pages. They all open in the same window. I've been using the following to create the links in Dreamweaver:
- On each page, I have a "Return to Main Menu" button that should close the popup window. To do this, I have been using:
- The problem is that it works differently in each browser, and I can't even get it to consistently close the window in most browsers:
Internet Explorer = popup message appears, asking "Are you sure you want to close this window?" or something similar; window closes after clicking "Yes."
Safari = Only closes if I'm on the original HTML page. If I click on any of the other links (note that these all open in the same window), those pages' "Return to Main Menu" buttons cease to work. However, if I keep clicking "Back" until I get to the original page, it closes.
Opera = Button actually works for each page.
Firefox & Chrome = Does not close the window at all.
I looked into it and saw that others have used a window.opener to solve similar issues. But, since my popup window is opened using Flash/AS2, I need to find a way around it.
I've tried preceding "window.close()" with "window.opener=null" (i.e. -onClick="window.opener=null; window.close()"), but I don't think I'm doing it right because it still doesn't work.
I've also seen others use codes that involve functions and variables, but it is beyond my current coding knowledge to implement this. Like I said, I'm sort of new at this.
View 5 Replies
View Related
Apr 20, 2011
I have two dropdown lists with the second one being dependent on the selection in the first.
Options in list 1: 1,3 or 4
List two should be enabled when 3 or 4 is selected in list 1.
So far so good, managed to get it to work with only one set of lists, but I actually have 18 of those sets in this form:
<select name="fw[$i]" id="fw[$i]">
<option value="1">FWH</option>
<option value="3">links</option>
<option value="4">rechts</option>
[Code]....
I'm not that adept in javascript programming, more like a trial and error guy, how has hit the wall with this problem.
View 20 Replies
View Related
Jun 12, 2007
What I want is user to select option from a dropdown menu then the dropdown below it to be populated.
View 1 Replies
View Related
Dec 15, 2003
I heard elsewhere that this may not be possible; still, I thought I'd check.
I'd like to be able to open a new webpage in a new *tab* if the browser allows for it, otherwise, just a new window.
Possible?
View 3 Replies
View Related
Jul 23, 2005
I am using the following code to display an image in a seperate
window.
<form>
<input type=button
onClick='window.open("image1.jpg","","width=260,height=260,resizable=0,border=0")'
value=Shhow Picture'>
</form>
I want the window to be the exact size of the image so I set the width
and height of the window the same as the width & height of the image.
The code works, however there is a white border on the top and left
side of the image. If I add 20 to the width and height of the window
then there is a white border around the whole image.
Is there anyway to have the window the exact size of the image,
without this white border? I know there is probably a simple solution,
but I'm a beginner at JavaScript.
View 2 Replies
View Related