JQuery :: Simple Hover Over Drop Down Menu One Level?

Sep 24, 2010

Well I have used this same script a few times, but this time I am having an issue, When I hover the text the drop down shows, as soon as I try to hover the drop down it will disappear.I am also trying to make the background stick on main text (hover text) untl the mouse moves off. Been stuck on this for hours.Here is my HTML

<div class="header-nav">
<ul id="navigation">
<li><a href="">home</a></li>

[code].....

View 1 Replies


ADVERTISEMENT

JQuery :: Hover (Top Level Menu) Not Working In Mozilla Firefox

Oct 29, 2010

I have implemented a jQuery hover top level menu & it is working fine in bothIE 7& 8. However, when I am executing the same code in Mozilla Firefox, it is not rendering hover effect at all. Also, I am adding a <span> using jQuery if JavaScript isn't enabled. This span is also not getting added in Mozilla.

Following is the code that I am using.
<script type="text/javascript" src="[URL]"></script>
<script>
$(document).ready(function(){
$("ul.subnav").parent().append("<span></span>");
$("ul.pnode li a").mouseover(function() { //When trigger is clicked...
//Following events are applied to the subnav itself (moving subnav up and down)
$(this).parent().find("ul.subnav").slideDown('fast').show(); //Drop down the subnav on click
$(this).parent().hover(function() {
}, function(){
$(this).parent().find("ul.subnav").slideUp('slow'); //When the mouse hovers out of the subnav, move it back up
});
//Following events are applied to the trigger (Hover events for the trigger)
}).hover(function() {
$(this).addClass("subhover"); //On hover over, add class "subhover"
}, function(){ //On Hover Out
$(this).removeClass("subhover"); //On hover out, remove class "subhover"
});
});
</script>

I came to know that IE & Mozilla see .parent differently.I have tried everything but not able to get this stuff working in Mozilla. I am using Firefox 3.5.5 version.

View 4 Replies View Related

JQuery :: Navigation - Put The Simple Drop Menu From Css ?

Dec 27, 2011

I am working and designing a website, and have put the simple JQuery drop menu from css tricks on my website, but every time i zoom in and out the website using ctrl +&- the site gets smaller or larger however the navigation moves and some bottoms from the menu drop down to the left or right under the first or last buttons, so does anyone know how i can fix and block the menu from moving around using HTML and its own CSS Style page, let me know.

click on the link below to see the demo for the navigation.

[url]

View 2 Replies View Related

Turn A Single Level Flyout Menu Into A Multi Level One?

Jan 7, 2009

I am trying to turn a single level flyout menu into a multi level one.

It uses a dt for the title, and a ul within the dd for the menu items. The dd opens to the right of the dt.

The problem is that the second level menu (a dl within an li within another dl) [URL] - flyout4 & subflyout5.

The z-index is increased each time. I just can't figure why the area is limited.

javascript, css & html follow -

Code JavaScript:
/** FLYOUT = vertical dropdown **/
var Flyout = {
DDSPEED:10,

[Code].....

View 1 Replies View Related

Looking For Hover Delay Script For Css Drop Down Menu?

Apr 19, 2009

What I'm looking for, and can't seem to find is, a JS snippet, that will delay the hover effect (a simple drop down) of my mega drop down menu by 250 millseconds or so. And of course, then hold the drop down in place for the same amount of time on mouseout.

View 4 Replies View Related

Special Values From Drop-down Menu & Total In Simple Form?

May 10, 2011

I have the perfect form for a client - but its missing one thing. She sells hair clips in various colors. A user can select a hair clip color and quantity quite easily (as seen in the code below). My issue is that she wants to be able to give the user a 'special price' based on the quantity ordered by the user. Contrary to simply adding the default price of $7 over and over again based on the quantity selected.The way I want it to work...

1 clip is $7
2 clips are $12
3 clips are $22
5 clips are....etc.

...however, with the way that the javascript is set up now I'm only able to select one default price. This means that whatever quantity is selected -- it's simply multiplied by the number 7 to provide a total.

1 clip is $7
2 clips are $14
3 clips are $21
5 clips are....etc.[code].....

View 7 Replies View Related

Vertical Menu - Height Of The Second Level Menu Results In Their Being Gaps In Between Each Menu Item

Jun 3, 2009

The problem is that the height of the second level menu results in their being gaps in between each menu item so that as you move your mouse down the second menu items it quickly closes again. scripting novice fix this by telling me which variable I need to change either in the Java script or the CSS files.

View 2 Replies View Related

JQuery :: Superfish Menu Disable Link At Top Level?

May 16, 2011

I have inherited a site with superfish used as the menu which seems to work fine except that I wish to disable the links at the top level so that a click on the top level of the menu goes nowhere only clicks on the sub menu list. At the moment each top level menu item is a section and the sub menu list categories. There is nothing I need or want to place in the Section heading so a link from this is unnecessary but at the moment clicking on the top level (section) leads to a page i do not want.Example:-Top Level Section (no link to anywhere)2nd level Category 1 (link to article)3rd level Category 2 (link to article)etc.

Is this possible to do. I feel sure it should be as it is a normal facility on a drop down menu but I cannot find anywhere in the options which enables this. I am not sufficiently conversant with CSS to try playing with the current layout which other than this seems to be working ok.

View 1 Replies View Related

JQuery :: Superfish: Top Level Navigation Menu Prints As A List

Jul 11, 2011

I have implemented Superfish in SAP Portal. there is a small issue when I take a print using the browser's print option. When I try printing the Web Page from the browser, the Top Level Navigation Menu appears as a list of links (vertical). This is happening in both IE as well as Firefox.

I have seen the same issue in the website from where I downloaded Superfish :-|

1. Goto: [URL]

2. Click on 'Print Preview' button in your Browser.

3. The Superfish Menu below the text 'The result:' will appear as a list of links in the print preview.

View 6 Replies View Related

JQuery :: Simple Img Hover Change Not Working?

Sep 14, 2010

Frustrated and exhausted. I've created a menu with the following code, but I'm getting this error ("invalid assignment left-hand side

<a class="nav-image" href="/menu-link'">
<img class="image-menu-rollover" src="/image.png">
<span class="nav-txt">menu-title</span>

[code]....

View 1 Replies View Related

JQuery :: Simple Show - Hide Div On Hover

Jun 7, 2011

I have a series of links on a page whereby when the user hovers over the title then an image appears next to the link so it basically shows/hides the image on mouseenter and mouseout. I'm presuming this is a fairly basic jQuery request but I've been hunting around for a while now and can only seem to find more complex examples that I can't seem to disect.

The code in my page is:

So when the user hovers over the "Link" then it will show "myimage.jpg" next to the link.

View 4 Replies View Related

JQuery :: Simple Show/Hide Div On Hover

Sep 11, 2011

I'm doing a show/hide div on hover, and what I have works...only when I hover over the .pics-nav div, it blinks repeatedly.

$(document).ready(function() {
$('#product-images').mouseover(function(){
$('.pics-nav').fadeIn();
}).mouseleave(function(){

[Code].....

how to solve a situation like this? Just a super-duper simple thing, but I'm having lots of problems with it.

View 1 Replies View Related

Multi - Level Drop Down Menus In A Tpl File

Aug 11, 2011

I have a website script written in php, now the menu it has is in php and uses a tpl file. This is very crude compared to what i need, now i post here in DHTML because the DHTML drop down menus are more what i need.

Here's the problem. I want to install this for the top navigation bar. It should appear on the whole site. But how do you get a DHTML menu into php script. The current menu is php script, and it is linked in each of the php pages at the bottom. And it needs to have the ability to recognize whether the user is logged in.

View 9 Replies View Related

JQuery :: Superfish Drop Down Menu - Drop Down Menus Seem To Flash On Screen For Just A Second And Then Disappear?

Nov 4, 2011

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.

View 1 Replies View Related

Add 3rd Level To Vertical Menu?

May 3, 2010

I would like to use the menu that is linked below. I implemented it on my website but I discovered that it can only go 2 levels deep. I would like it to go one more level and I think that would be done in the javascript but I can't tell for sure. Could someone steer me in the right direction? [URL]

View 2 Replies View Related

Four Level Connected Dropdown Boxes - All The Options To Be Available If Nothing Is Selected In The Previous Drop Down

May 31, 2010

I'm looking for four level connected drop down boxes. Unlike all the scripts I have seen on the internet I need all the options to be available if nothing is selected in the previous drop down. So I want something like combination of connected drop downs and ordinary drop down. If the selection is made, display appropriate options in other drop downs... Hope I'm clear...

[Code]....

View 4 Replies View Related

AJAX 2-level Menu Maker

Feb 13, 2007

Tested in IE6 and Firefox. Hover on main menu items, sub-items are displayed. Main menu items are not required to have sub items.

MenuTree.xml

<?xml version="1.0" ?>
<menu>
<main>
<text>First</text>
<sub>
<text>Anything</text>
<link>links/anything.html</link>
</sub>
<sub>
<text>Everything</text>
<link>links/everything.html</link>
</sub>
<sub>
<text>Nothing</text>
<link>links/nothing.html</link>
</sub>
</main>
<main>
<text>Second</text>
<link>links/apples.html</link>
</main>
<main>
<text>Third</text>
<sub>
<text>Something</text>
<link>links/something.html</link>
</sub>
</main>
<main>
<text>Fourth</text>
<link>links/oranges.html</link>
</main>
</menu>



<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<script type="text/javascript">

var response = "";
var nContainer = "";
var mainItemsText = [];
var mainItemsLink = [];
var subItemsText = [];
var subItemsLink = [];
var mainItemsWithSubs = [];
var IE = true;
if (navigator.appName != "Microsoft Internet Explorer"){IE = false}

function hideSubs(nMain){

var nSubs = nMain.getElementsByTagName('dd');
for (i=0; i<nSubs.length; i++)
{
nSubs[i].style.display = 'none'
}
}

function showSubs(nMain){

var nSubs = nMain.getElementsByTagName('dd');
for (i=0; i<nSubs.length; i++)
{
nSubs[i].style.display = ''
}
}

function setHoverDisplay(){

if (IE)
{
for (i=0; i<mainItemsWithSubs.length; i++)
{
for (n=0; n<subItemsText[i].length; n++)
{
nContainer.childNodes[mainItemsWithSubs[i]].childNodes[n+1].style.display = 'none'
nContainer.childNodes[mainItemsWithSubs[i]].onmouseover = function(){showSubs(this)}
nContainer.childNodes[mainItemsWithSubs[i]].onmouseout = function(){hideSubs(this)}
}
}
}
else {
for (i=0; i<mainItemsWithSubs.length; i++)
{
for (n=0; n<subItemsText[i].length; n++)
{
nContainer.childNodes[mainItemsWithSubs[i]+1].childNodes[n+1].style.display = 'none'
nContainer.childNodes[mainItemsWithSubs[i]+1].onmouseover = function(){showSubs(this)}
nContainer.childNodes[mainItemsWithSubs[i]+1].onmouseout = function(){hideSubs(this)}
}
}
}
}

function buildMenu(){

nContainer = document.getElementById('menuContainer');
mainItemsWithSubs = [];
var n = 0;
for (i=0; i<mainItemsText.length; i++)
{
var nItem = document.createElement('dt');
var nLink = document.createElement('a');
nItem.appendChild(nLink);
nLink.appendChild(document.createTextNode(mainItemsText[i]));
if (mainItemsLink[i] != undefined)
{
nLink.setAttribute('href',mainItemsLink[i]);
}
else{
nLink.setAttribute('href',"#");
nLink.onclick = function(){return false;}
mainItemsWithSubs[n++] = i;
}
nContainer.appendChild(nItem);
}
for (i=0; i<mainItemsWithSubs.length; i++)
{
for (s=0; s<subItemsText[i].length; s++)
{
nItem = document.createElement('dd');
nLink = document.createElement('a');
nItem.appendChild(nLink);
nLink.appendChild(document.createTextNode(subItemsText[i][s]));
nLink.setAttribute('href',subItemsLink[i][s]);
if (IE){nContainer.childNodes[mainItemsWithSubs[i]].appendChild(nItem)}
else {nContainer.childNodes[mainItemsWithSubs[i]+1].appendChild(nItem)}
}
}
setHoverDisplay();
}

function parseResponse(){

var n = 0;
var s = 0;
var mainItems = response.getElementsByTagName('main');
if (IE)
{
for (i=0; i<mainItems.length; i++)
{
mainItemsText[n] = mainItems[i].firstChild.text;
if (mainItems[i].childNodes[1].nodeName == "link")
{
mainItemsLink[n] = mainItems[i].childNodes[1].text;
}
n++;
}
}
else {
for (i=0; i<mainItems.length; i++)
{
mainItemsText[n] = mainItems[i].childNodes[1].firstChild.data;
if (mainItems[i].childNodes[3].nodeName == "link")
{
mainItemsLink[n] = mainItems[i].childNodes[3].firstChild.data;
}
n++;
}
}
for (i=0; i<mainItems.length; i++)
{
if (IE && mainItems[i].childNodes[1].nodeName == "sub")
{
subItemsText[s] = [];
subItemsLink[s] = [];
for (n=0; n<mainItems[i].getElementsByTagName('sub').length; n++)
{
subItemsText[s][n] = mainItems[i].childNodes[n+1].childNodes[0].text;
subItemsLink[s][n] = mainItems[i].childNodes[n+1].childNodes[1].text;
}
s++;
}
if (!IE && mainItems[i].childNodes[3].nodeName == "sub")
{
subItemsText[s] = [];
subItemsLink[s] = [];
var subs = mainItems[i].getElementsByTagName('sub');
for (n=0; n<subs.length; n++)
{
subItemsText[s][n] = subs[n].childNodes[1].firstChild.data;
subItemsLink[s][n] = subs[n].childNodes[3].firstChild.data;
}
s++;
}
}
buildMenu();
}

function getMenuTree(){

var request = window.ActiveXObject ? new ActiveXObject("Microsoft.XMLHTTP") : new XMLHttpRequest();
request.onreadystatechange = function()
{
if (request.readyState == 4)
{
if (request.status == 200)
{
response = request.responseXML;
parseResponse();
}
else {alert('Error MenuTree.xml '+ request.statusText)}
}
}
var forceGET = "?n="+ parseInt(Math.random()*999999999);
request.open("GET", "MenuTree.xml"+forceGET, true);
request.send(null);
}

onload=getMenuTree;

</script>
<style type="text/css">

dt {background-color:#b0c4de;text-indent:5px}
dd {background-color:#87ceeb}
a {color:#00008b}

</style>
</head>
<body>

<div id='menuContainer' style='border:1px solid black;background-color:#afeeee;height:200px;width:150px;font-size:12pt;padding:5px;overflow:auto;font-family:arial;font-weight:bold;line-height:140%'>
</div>

</body>
</html>

View 6 Replies View Related

Malfunction With Pull-down Multi-level Menu

Jan 24, 2009

I've been asked to create a site for my younger sister and she's requested a horizontal pull-down menu using graphics for the links instead of simply text. This is my first time trying to code such a menu (topic not covered in class) and I'm having some difficulty getting it to work completely.

Right now it's partially working. The various sub menus do show up when clicking or rolling over the previous menu item. However all menu items past the one clicked jump down one line when expanding instead of simply showing the sub menu under the main line up. The rollover also has issues but mostly because I haven't finished coding the onmouseout part, so it doesn't go away. I'm trying to get the main pull down working before tackling that part. Below is the JavaScript function I'm trying to use as well as a part of the menu. I've already spent months trying to get this working and am not making much headway.

[Code]...

View 2 Replies View Related

Change A Single Level Menu To Multi?

Jul 26, 2010

I run an educational website with a CSS/JavaScript based menu that is right now only single level. I am trying to convert it over to multi level. I have tried a few other multi level menus but I have done a lot of customization in terms of appearance for this current menu, so none of the new ones looked right.

Here is the site: [url]
Here is the CSS: [url]
Here is the JavaScript: [url]

View 3 Replies View Related

Superfish: Automatically Expand 3rd-level Menu

Mar 19, 2009

I have a 3-level menu using JQuery-Superfish. I would like to hover over the top-level menu item and have BOTH the 2nd and 3rd-level menus open automatically.

View 1 Replies View Related

2 Level Horizontal Menu - Convert It To Onclick

Sep 16, 2009

I have a working code of 2 level horizontal tab menu....it is now onmouse over ,I want to convert it to onclick. I have taken from....

Code:
var mastertabvar=new Object()
mastertabvar.baseopacity=0
mastertabvar.browserdetect=""
function showsubmenu(masterid, id){
if (typeof highlighting!="undefined")
clearInterval(highlighting)
submenuobject=document.getElementById(id)
[Code]...

View 4 Replies View Related

JQuery :: SlideToggle Open One Of Two Hidden Sub-nav Bars When Either Of Two Different Menu Items Are Clicked Upon - Instead Of A Drop Down Menu

Oct 26, 2009

The purpose of the code is to slideToggle open one of two hidden sub-nav bars when either of two different menu items are clicked upon - instead of a drop down menu. What doesn't work is the hiding of the div that is not required, if it is already open. Viewing in firebug shows that the appropriate classes are being applied - I suspect the reason is that slideToggle has been somehow set and cannot be unset via another object - but perhaps that is not it at all?

$(document).ready(function() {
//add .toggle function to appropriate li element
$('#hozmenu li:nth-child(4)').toggle(function () {
//set 4th menu links colour to be green whilst div is shown
$('#hozmenu li:nth-child(4) a').css('color', '#95d890');
$('#toggle_nav_services').removeClass('toggle_show');
[Code]....

View 1 Replies View Related

Multi-Level Menu- Making The Lists Show?

May 26, 2011

I am really pressing on to finish this home page menu, and I'm trying to find out why this odd behavior is occurring. There is obviously some conflicting code in my CSS. You can see this odd behaving menu for yourself at productreview. The other thing I'm trying to learn how to do is how to get the 3rd and 4th level lists to appear on the parent item's hover.This is my JavaScript:

Code:
<script src="http://code.jquery.com/jquery-1.6.1.min.js" type="text/javascript"></script>
<script type="text/javascript">

[code]....

View 1 Replies View Related

Jquery :: Sub Menu Animation - Add A Nested Menu To The Drop Down

Dec 5, 2010

, I'd like to think this is fairly simple but unfortunately my knowldege of jquery is limited to using prebuilt scripts and changing a few variables to get what i need. I created a drop down menu with a slide down/up animation for submenus, which worked out just as I wanted. I ran into troubles though when trying to add a nested menu to the drop down, but with a slide animation going from left to right. I'm sure my explanation isn't very clear, so please take a look [URL] The nested submenu I am speaking of should only open when hovering occurs on the 'Item 01' link, but as you can see it also opens when hovering over the buyers link. Secondly, my attempt to slide from left to right on this ul is not working, it seems to be sliding down even though this was not defined in the code.

View 1 Replies View Related

Multi Level Menu - Other Will Close When Click On A Other Main Item

May 19, 2009

I want that when i click on a other main item that the other will close. Now it still keep open and then ill get a long menu list. How do i do it , i dont have js experience.

[Code]...

View 2 Replies View Related

Second Level Of Buttons (sub Menu) To Disappear Once The Cursor Is No Longer Hovering Over Them?

Jun 24, 2009

I would like the second level of buttons (submenu) to disappear once the cursor is no longer hovering over them - rather than appearing until another button in the top level is hovered over. modify the javascript below to do that?

[Code]....

View 3 Replies View Related







Copyrights 2005-15 www.BigResource.com, All rights reserved