offset in V5

Having problems with DHTML Menu? There is usually somebody here who knows the answer.
Post Reply
topachou
Advanced
Advanced
Posts: 24
Joined: Wed Aug 06, 2003 10:18 pm

offset in V5

Post by topachou »

I'm using the v5.

I have my main menu set to : screenposition = "center; middle".

In order to position my menu, I'd like to have :
- horizontal offset = -200px
- vertical offset = -100px.

How can I do that ?

Thanks
topachou
Advanced
Advanced
Posts: 24
Joined: Wed Aug 06, 2003 10:18 pm

Post by topachou »

Pleaaaase, guys !

It's really important, and I've just past 3 hours looking for a trick.

I'm a bit desesperate here. No offset with V5 ?

Come on ! It's not possible :))
User avatar
fredlongworthhighschool
Mega Advanced
Mega Advanced
Posts: 362
Joined: Fri Jun 27, 2003 11:34 am
Location: Manchester, England.
Contact:

Post by fredlongworthhighschool »

This is my code that leaves the menu in the middle......

Code: Select all

with(milonic=new menuname("mainmenu2")){_c=1
top = 10;							// was 10
//left = 300;							// was 10
//itemwidth=90							// was 60
//menuwidth="29%";						// was 99%
borderwidth = 1;						// was 1
screenposition = "center;middle";
alignment="center";
style = mainStyle;
alwaysvisible = 1;
orientation="horizontal"
If I remove the // from left=300 I can then adjust the position.

I hope this is what you mean.

Andy
Andy Davis
Web Designer & Smartboard Manager

Fred Longworth High School, Manchester, England.
topachou
Advanced
Advanced
Posts: 24
Joined: Wed Aug 06, 2003 10:18 pm

Post by topachou »

When you remove the // of :
//top=10
//left=10

The menu is not middle centered anymore.
It is no relative positionning but fixed positionning.

It will take the (0,0) coordinate and place the menu at (10,10).

That's not want I want to do. I need to offset (ex: lefOffset=-100, topOffset=-100) my menu from the : middle, center of the screen, so that I can place it relatively.

Thanks for your reply, but I just try it again, and it's not working for me.

I used the "horinzontal.htm" given with the V5.
Try it, you'll see !
User avatar
Maz
Milonic God
Milonic God
Posts: 1717
Joined: Fri Jun 06, 2003 11:39 pm
Location: San Francisco
Contact:

Post by Maz »

Just a guess... have you tried position="relative";
User avatar
Andy
Milonic
Milonic
Posts: 3308
Joined: Sun May 19, 2002 8:23 pm
Location: Menu Developer
Contact:

Post by Andy »

Offsets need to be enclosed in quotes with a syntax of

Code: Select all

left="offset=-100"
Offsets are also only used in conjunction with screenposition.

Cheers
Andy.
topachou
Advanced
Advanced
Posts: 24
Joined: Wed Aug 06, 2003 10:18 pm

Post by topachou »

Oh my God ! 8O

Thank you ANDY, it's working. :D
User avatar
fredlongworthhighschool
Mega Advanced
Mega Advanced
Posts: 362
Joined: Fri Jun 27, 2003 11:34 am
Location: Manchester, England.
Contact:

Post by fredlongworthhighschool »

Another satisfied customer!
Andy Davis
Web Designer & Smartboard Manager

Fred Longworth High School, Manchester, England.
topachou
Advanced
Advanced
Posts: 24
Joined: Wed Aug 06, 2003 10:18 pm

Post by topachou »

Indeed !
Post Reply