Milonic menu and jquery Thickbox

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
cstavros19
Beginner
Beginner
Posts: 1
Joined: Tue Feb 05, 2008 8:18 pm

Milonic menu and jquery Thickbox

Post by cstavros19 »

I am using Jquery thickbox to display images and it is supposed to make all the background inactive however it does not make my milonic menu inactive. Has anybody encoutered this problem?

Thanks,

Charlie
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Re: Milonic menu and jquery Thickbox

Post by Ruth »

Hi Charlie,

I'm sorry but you are going to have to go to the support area and ask this at Milonic directly. I don't think anyone here has the knowledge about thickbox and stuff, at least I don't. If you have a professional license or above use this link, log in under the name used to purchase/register the menu and open a support ticket. They are pretty quick in responding.

http://milonic.com/support/

If you don't have a professional license try this link http://milonic.com/contact.php

Just post what is supposed to happen based on the thickbox and ask if this works or not with milonic, and/or how to make it work.

Ruth
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

I'm going to respond to this and explain how to get Thickbox to work with Milonic DHTML Menus, there have been quite a few people asking for this. This method also works with Lightbox and Lytebox etc.

Basically, these scripts add a veil or a type of curtain to your webpage and then display their window with the images inside them on top of this veil. The veil has a transparency so that your site can be seen through it but the focus is on the image inside the window, it's quite a nice effect. It's very much like how certain dialog boxes work in Windows Vista.

Anyway, the problem you have is that, by default, the menu's ZIndex has been set higher than the veil and will show on top of it. In oder to get the menu to display behind the veil, you need to change the menus default ZIndex property. This is set to 1000 by default.

I believe that JQuery Thickbox and Lightbox zindexes are around 100, so you should try changing the menus zindex to something like 90. This is done with the menu property zindex, heres how it should look:

Code: Select all

with(milonic=new menuname("Main Menu")){
alwaysvisible=1;
orientation="horizontal";
style=menuStyle;
zindex=90;
aI("text=Home;url=index.htm;");
I Hope this helps explain to everybody searching for an answer to this problem
iBringSolutions
Advanced
Advanced
Posts: 12
Joined: Thu Nov 27, 2008 7:01 pm

Re: Milonic menu and jquery Thickbox

Post by iBringSolutions »

Much appreciated you posting this 'fix'. It worked brilliantly for me.

Thanks!

PJ
wuscheck
Advanced
Advanced
Posts: 16
Joined: Tue Aug 26, 2003 8:07 am

Re: Milonic menu and jquery Thickbox

Post by wuscheck »

I placed zindex=9 because lightbox got an z-index 100, 90 and 10 but it won't work.

Code: Select all

$mmStyle->zindex=9;
Where I have to place the zindex when I use the php version of milonic? :oops:
User avatar
Ruth
 Team
 Team
Posts: 8763
Joined: Thu May 15, 2003 5:02 am
Location: Yucaipa, CA
Contact:

Re: Milonic menu and jquery Thickbox

Post by Ruth »

Hi,

The zindex goes in the menu, not the style. For example:

Code: Select all

with(milonic=new menuname("Main Menu")){
style=menuStyle;
alwaysvisible="true";
orientation="horizontal";
position="relative";
itemwidth="120";
itemheight="29";
align="center";
zindex=9;
Ruth
wuscheck
Advanced
Advanced
Posts: 16
Joined: Tue Aug 26, 2003 8:07 am

Re: Milonic menu and jquery Thickbox

Post by wuscheck »

Hi Ruth,

I pasted it into the wrong code... now it works fine. Thank you for your support.
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Hi

Built quite a few sites with Milonic but first one requiring a Greybox popup

I am using Greybox (http://orangoo.com/labs/GreyBox/) - latest Milonic menu. (Version 5.830 - Built: Monday May 10 2010)

Greybox has
#GB_overlay {
background-color: #000;
position: absolute;
margin: auto;
top: 0;
left: 0;
z-index: 100;
}

I have set z-index in menu =9

style=menuStyle;
alwaysvisible=1;
orientation="horizontal";
overfilter="";
position="relative";
zindex="9";



A normal href link = <a href=thegallery.php class="topmenu" rel="gb_page_center[835, 700]"> (works fine)

So i put

aI("text=gallery;url=thegallery.php;rel=gb_page_center[835, 700]");


However it does not produce the overlay. It is acting as if it cannot find rel="gb_page_center[835, 700]"

See

http://www.thedivinitycode.org/home.php


Any ideas anyone? Thanks.

Cheers
Chris
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

I have now added the rel property to the latest version of the menu.

If you download version 5.831 and update milonic_src.js and mmenudom.js you should see it working.

Please note that you will have to build the menu before calling the Grey Box code and you will probably need to build all menus so you will need to add buildAllMenus=true; to the top of your menu_data.js file
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Hi Andy

Downloaded 5.831 and overwrote milonic_src.js and mmenudom.js

Thanks for that but I still get the same result at
http://www.thedivinitycode.org/home.php

Added extra line at top of menu_data.js
buildAllMenus=true;
fixMozillaZIndex=true;

Cheers
Chris
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

It looks like you are calling the menu after you have added the gallery code.

The gallery code scans through the links looking for the keyword rel - because the menu is added after the gallery script the rel in the menu is being ignore.

To get this to work you MUST build the menu first, then run the gallery script. This will ensure that the link is found.
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Andy - thanks but I am not sure how to achieve that?

I moved the following from before the <head> and put it after menu_data.js but it made no difference.

<script type="text/javascript">
var GB_ROOT_DIR = "http://www.thedivinitycode.org/greybox/";
</script>
<script type="text/javascript" src="greybox/AJS.js"></script>
<script type="text/javascript" src="greybox/AJS_fx.js"></script>
<script type="text/javascript" src="greybox/gb_scripts.js"></script>

Cheers
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

Hi,

I think we need to forget the "rel=" idea it's just not going to work with dynamic links.

It looks like you can use methods, according to this: http://orangoo.com/labs/greybox/advance_usage.html

Can you please show me a page with the menu removed so that I can see how to use the GB Methods.
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Here is without the menu - top gallery menu item.

Using GB system - works fine

http://www.thedivinitycode.org/home2.php

<a href=thegallery.php class="topmenu" onclick="return GB_showCenter('Gallery', this.href,700,835)">gallery</a>

===========================

Using GB system (with Milonic - not working yet)

http://www.thedivinitycode.org/home.php

aI("text=gallery;url=thegallery.php;onclick=return GB_showCenter('Gallery', this.href,700,835)");
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

on this page: http://www.thedivinitycode.org/home.php

try changing: aI("text=gallery;url=thegallery.php;onclick=return GB_showCenter('Gallery', this.href,700,835)");

to : aI("text=gallery;url=thegallery.php;clickfunction=return GB_showCenter('Gallery', this.href,700,835)");
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Thanks but ...sigh...

http://www.thedivinitycode.org/home.php

aI("text=gallery;url=thegallery.php;clickfunction=return GB_showCenter('Gallery', this.href,700,835)");

Maybe I need to try an alternative to this Andy.
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

I think we are now getting closer:

try this instead: aI("text=gallery;url=thegallery.php;clickfunction=GB_showCenter('Gallery', 'thegallery.php',700,835)");
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

It brings up the grey bg for a second then loses it and reverts to a standard page.

http://www.thedivinitycode.org/home.php
Humble Web designer
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Re: Milonic menu and jquery Thickbox

Post by Andy »

Ok, almost there then.

Try this one: aI("text=gallery;url=thegallery.php;clickfunction=GB_showCenter('Gallery', 'thegallery.php',700,835);custom=retFalse;");
chrisinoz
Advanced
Advanced
Posts: 26
Joined: Sat Mar 12, 2005 8:11 am
Location: Adelaide, South Australia

Re: Milonic menu and jquery Thickbox

Post by chrisinoz »

Absolutely closer - we now popup where we should :>

we now just have a referencing url prob

http://www.thedivinitycode.org/home.php
Humble Web designer
Post Reply