Vertical menu dont show chlid page on hover

A place for discussion about skinning and design. Before posting questions here you should review the documentation about creating skins.

This thread is closed to new posts. You must sign in to post in the forums.
2/10/2012 6:15:32 AM
Gravatar
Total Posts 108
Community Expert

Vertical menu dont show chlid page on hover

Hi I have a vertical page menu in my page, the idea of this menu is to show all the root page always and in the onhover event show the child page.I create this menu using artisteer 3.1 and work find in the html but I cant find a way to make it work in mojo.

 

The relevant code from my layout.master file is

  <portal:SkinFolderScript ID="sfs1" runat="server" ScriptFileName="skinscript.js" AddToCombinedScript="true" />

 <portal:PageMenu ID="PageMenu1" runat="server" UseTreeView="true" IsSubMenu="false"
TreeViewShowExpandCollapse="false" UseArtisteer="true"   />

 

I try to set the AddToCombinedScript to false and use firebug to see the script but the script file never loaded

 

Any Ideas?

 

 

2/10/2012 6:47:58 AM
Gravatar
Total Posts 18439

Re: Vertical menu dont show chlid page on hover

Hi German,

That UseArtisteer setting is a legacy setting that should not be used anymore. At one time we used a special menu adapter for Artisteer but in recent versions our mojoMenu and mojoTreeView controls can render what is needed for Artisteer by configuration from theme.skin so that older control is no longer used and is not updated for the latest Artisteer.

In newer Artisteer skins we don't have that, we have PageMenu like this:

<portal:PageMenu ID="PageMenu1" runat="server" UseTreeView="true" IsSubMenu="true"
TreeViewShowExpandCollapse="false" />

and in theme.skin we have:

<portal:mojoTreeView runat="server" SkinID="PageMenu"
ContainerCssClass="art-box art-vmenublock"
ExtraMarkupMode="Artisteer"
RootUlCssClass="art-vmenu"
RenderLiCssClasses="true"
RenderAnchorCss="true"
LiCssClass=""
LiRootExpandableCssClass=""
LiRootNonExpandableCssClass=""
LiNonRootExpnadableCssClass=""
LiSelectedCssClass="active"
LiChildSelectedCssClass="active"
LiParentSelectedCssClass=""
AnchorCssClass=""
AnchorSelectedCssClass="active"
ExpandDepth="-1"
ShowExpandCollapse="false"
PopulateNodesFromClient="false"
SuppressCornerDivs="true"
/>

Hope that helps,

Joe

2/10/2012 6:55:38 AM
Gravatar
Total Posts 108
Community Expert

Re: Vertical menu dont show chlid page on hover

Hi Joe I'm using and updated theme skin but I was playing with different options from the portal:PageMenu like set the TreeViewShowExpandCollapse=true active the use artistter use DynamicDisplayLevels. But cant find witch option was related with the imposibility for my menu to run the the jquery needed for the hover function, this is the code related to the vertical menu in my skinscript.js

/* begin VMenu */
jQuery(function() {
if (!jQuery('html').hasClass('ie7')) return;
jQuery('ul.art-vmenu li:not(:first-child),ul.art-vmenu li li li:first-child,ul.art-vmenu>li>ul').each(function () { jQuery(this).append('<div class="art-vmenu-separator"> </div><div class="art-vmenu-separator-bg"> </div>'); });
});
jQuery(function() {
setOpenSubmenuWithHover({vMenuClass: "art-vmenu", activeClass: "active", hoveredClass: "hovered"});
});

(function($){$.fn.hoverIntent=function(f,g){var cfg={sensitivity:7,interval:100,timeout:0};cfg=$.extend(cfg,g?{over:f,out:g}:f);var cX,cY,pX,pY;var track=function(ev){cX=ev.pageX;cY=ev.pageY};var compare=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);if((Math.abs(pX-cX)+Math.abs(pY-cY))<cfg.sensitivity){$(ob).unbind("mousemove",track);ob.hoverIntent_s=1;return cfg.over.apply(ob,[ev])}else{pX=cX;pY=cY;ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}};var delay=function(ev,ob){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t);ob.hoverIntent_s=0;return cfg.out.apply(ob,[ev])};var handleHover=function(e){var ev=jQuery.extend({},e);var ob=this;if(ob.hoverIntent_t){ob.hoverIntent_t=clearTimeout(ob.hoverIntent_t)}if(e.type=="mouseenter"){pX=ev.pageX;pY=ev.pageY;$(ob).bind("mousemove",track);if(ob.hoverIntent_s!=1){ob.hoverIntent_t=setTimeout(function(){compare(ev,ob)},cfg.interval)}}else{$(ob).unbind("mousemove",track);if(ob.hoverIntent_s==1){ob.hoverIntent_t=setTimeout(function(){delay(ev,ob)},cfg.timeout)}}};return this.bind('mouseenter',handleHover).bind('mouseleave',handleHover)}})(jQuery);
function setOpenSubmenuWithHover(vMenuInfo) {
jQuery("ul." + vMenuInfo.vMenuClass + " li").each(function () {
var item = jQuery(this);
var simple = item.children("ul").length == 0;
if (!simple) {
item.children("a").hoverIntent({interval: 200, over: function() {
var link = jQuery(this);
hideVMenuSubmenus(link, vMenuInfo.activeClass);
showVMenuSubmenu(link, vMenuInfo.activeClass, vMenuInfo.hoveredClass, false);
}, out: function () { }});
}
item.children("a").bind("click", function(e) {
var link = jQuery(this);
hideVMenuSubmenus(link, vMenuInfo.activeClass);
showVMenuSubmenu(link, vMenuInfo.activeClass, vMenuInfo.hoveredClass, simple);
});
});
}
function showVMenuSubmenu(link, activeClass, hoveredClass, simple) {
if (simple) {
if (!link.hasClass(activeClass)) link.addClass(activeClass);
return;
}
if (!link.hasClass(activeClass)) {
link.siblings("ul").slideDown("fast", function() {
jQuery(this).siblings("a").removeClass(hoveredClass);
jQuery(this).addClass(activeClass).siblings("a").addClass(activeClass);
jQuery(this).css("display", "");
});
}
}
function hideVMenuSubmenus(link, activeClass) {
link.parent().siblings().children("ul." + activeClass).slideUp(function() {
jQuery(this).find("a, ul").removeClass(activeClass);
jQuery(this).removeClass(activeClass).siblings("a").removeClass(activeClass);
jQuery(this).css("display", "");
});
link.parent().siblings().children("a." + activeClass).removeClass(activeClass);
}

/* end VMenu */

and this is the theme skin

 

<portal:mojoTreeView runat="server" SkinID="PageMenu"
ContainerCssClass="art-box art-vmenublock"
ExtraMarkupMode="Artisteer"
RootUlCssClass="art-vmenu"
RenderLiCssClasses="true"
RenderAnchorCss="true"
LiCssClass=""
LiRootExpandableCssClass=""
LiRootNonExpandableCssClass=""
LiNonRootExpnadableCssClass=""
LiSelectedCssClass="active"
LiChildSelectedCssClass="active"
LiParentSelectedCssClass=""
AnchorCssClass=""
AnchorSelectedCssClass="active"
ExpandDepth="-1"
ShowExpandCollapse="false"
PopulateNodesFromClient="false"
SuppressCornerDivs="true"
/>

 

 

 

 

2/13/2012 10:11:55 AM
Gravatar
Total Posts 1196
Proud member of the mojoPortal team

Help support mojoPortal!
Add-on modules

Re: Vertical menu dont show chlid page on hover

Hi German, have you tried the artisteer31-hovermenu skin? I think that one works the way you want. The root pages are shown across the top, and when you select one of those and get to a page with vertical submenu, hovering over one of those will expand the pages below it. Perhaps by investigating that you will be able to find what you need.

Jamie

2/14/2012 4:03:04 AM
Gravatar
Total Posts 108
Community Expert

Re: Vertical menu dont show chlid page on hover

Hi Jaime thanks for the tip I didnt see that skin befor, the error was that I was using the Visual Studio Engine Server so the path for loading some scripts was wrong, now I'm using the IIS and every thing seems right

You must sign in to post in the forums. This thread is closed to new posts.