- Posts: 14116
- Thank you received: 1639
menu keep being stuck open
-
ivan.milic
Support Staff -
- Offline
- Moderator
-
Less
More
11 years 11 months ago #37872
by ivan.milic
Replied by ivan.milic on topic menu keep being stuck open
Ok, i did not know what you mean by stuck-open. Open:
templates/milehigh/js/jquery.hjt.nav.js
this code:
replace with:
templates/milehigh/js/jquery.hjt.nav.js
this code:
Code:
jQuery('.nav li').hover(function(){
jQuery(this).find('ul:first').stop(true,true)[options.effect](options.speed);
},function(){
jQuery(this).css('position', 'relative')
.find('ul:first').stop(true,true)[options.effect](options.speed);
});
replace with:
Code:
jQuery('.nav li').hover(function(){
jQuery(this).find('ul:first:not(:visible)').stop(true,true)[options.effect](options.speed);
},function(){
if(jQuery(this).is(':visible'))
jQuery(this).css('position', 'relative')
.find('ul:first').stop(true,true)[options.effect](options.speed);
});
Please Log in to join the conversation.
11 years 10 months ago #38072
by maryswave
Replied by maryswave on topic menu keep being stuck open
That file only contains this code
Code:
(function(jQuery){
jQuery.fn.dropDownMenu = function(options) {
var defaults = {
speed: 300,
effect: 'fadeToggle'
};
var options = jQuery.extend(defaults, options);
return this.each(function() {
jQuery('.nav ul').hide();
jQuery('.nav li ul li').filter(':last-child').css('border-bottom', 'none');
jQuery('.nav li').hover(function(){
jQuery(this).find('ul:first').stop(true,true)[options.effect](options.speed);
},function(){
jQuery(this).css('position', 'relative')
.find('ul:first').stop(true,true)[options.effect](options.speed);
});
});
};
})(jQuery);
Please Log in to join the conversation.
-
ivan.milic
Support Staff -
- Offline
- Moderator
-
Less
More
- Posts: 14116
- Thank you received: 1639
11 years 10 months ago #38081
by ivan.milic
Replied by ivan.milic on topic menu keep being stuck open
Ok that's it:
(function(jQuery){
jQuery.fn.dropDownMenu = function(options) {
var defaults = {
speed: 300,
effect: 'fadeToggle'
};
var options = jQuery.extend(defaults, options);
return this.each(function() {
jQuery('.nav ul').hide();
jQuery('.nav li ul li').filter(':last-child').css('border-bottom', 'none');
jQuery('.nav li').hover(function(){
jQuery(this).find('ul:first').stop(true,true)[options.effect](options.speed);
},function(){
jQuery(this).css('position', 'relative')
.find('ul:first').stop(true,true)[options.effect](options.speed);
});
});
};
})(jQuery);
(function(jQuery){
jQuery.fn.dropDownMenu = function(options) {
var defaults = {
speed: 300,
effect: 'fadeToggle'
};
var options = jQuery.extend(defaults, options);
return this.each(function() {
jQuery('.nav ul').hide();
jQuery('.nav li ul li').filter(':last-child').css('border-bottom', 'none');
jQuery('.nav li').hover(function(){
jQuery(this).find('ul:first').stop(true,true)[options.effect](options.speed);
},function(){
jQuery(this).css('position', 'relative')
.find('ul:first').stop(true,true)[options.effect](options.speed);
});
});
};
})(jQuery);
Please Log in to join the conversation.
11 years 10 months ago #38159
by maryswave
Replied by maryswave on topic menu keep being stuck open
I guess what you are saying is there is no fix and I will have to use a different module. Would be nice to be able to use the menu system that comes with Sparky
Please Log in to join the conversation.
-
ivan.milic
Support Staff -
- Offline
- Moderator
-
Less
More
- Posts: 14116
- Thank you received: 1639
11 years 10 months ago #38171
by ivan.milic
Replied by ivan.milic on topic menu keep being stuck open
???
Just replace code
Just replace code
Please Log in to join the conversation.
11 years 10 months ago #38172
by maryswave
Replied by maryswave on topic menu keep being stuck open
with what??
the code I pasted in is the code already in the file
the additional code you pasted in is a duplicate of what I pasted in. I could not see a difference.
the code I pasted in is the code already in the file
the additional code you pasted in is a duplicate of what I pasted in. I could not see a difference.
Please Log in to join the conversation.
Time to create page: 0.189 seconds