View Full Version : HV Menu v5.5/Center problems in Firefox

10-14-2006, 01:09 PM
1) Script Title: HV Menu v5.5

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex1/hvmenu/index.htm

3) Describe problem:

I placed the menu in a table cell. the whole table is also placed in a table to center the whole site on the screen.


In IE everything works fine. But Firefox and Mozilla both let the menu be
placed 10 Pixels left outside the rest of the page.

anybody an idea?
It must be a problem of this center stuff because
without this table around everything works fine in all browsers.

Here is the part of the site:

<body bgcolor="#a9a9a9" leftmargin="0" topmargin="0" marginwidth="0" marginheight="0">

<script type='text/javascript'>

//HV Menu v5.411- by Ger Versluis (http://www.burmees.nl/)
//Submitted to Dynamic Drive (http://www.dynamicdrive.com)
//Visit http://www.dynamicdrive.com for this script and more

function Go(){return}

<script type='text/javascript' src='scripts/exmplmenu_var.js'></script>
<script type='text/javascript' src='scripts/menu_com.js'></script>
<noscript>Your browser does not support script</noscript>
<table width="100%" border="0" cellspacing="0" cellpadding="0" height="100%">
<td align="center" valign="middle">
<table cellpadding="0" cellspacing="0" border="0">

<td valign="top" width="165">

<img src="images/headnavi.gif" alt="" height="128" width="165" align="top"></td>
<td valign="top" width="596"><img src="images/portfolio.gif" alt="" height="128" width="596" border="0"></td>
<td width="165"><div id='MenuPos' style='position:relative; width:165; height:175;'></div></td>
<td bgcolor="#676060" align="center">
<iframe src="ipute.html" name="ipute" width="560" height="165" align="center" scrolling="no" marginheight="0" marginwidth="0" frameborder="0"></iframe>
</td> ......

Thanks for help

10-14-2006, 01:14 PM
Remove position:relative; from:

<div id='MenuPos' style='position:relative; width:165; height:175;'>

10-14-2006, 03:47 PM
Sorry doesn't work.
Same problem ...
This is my menu:

var NoOffFirstLineMenus=5; // Number of first level items
var LowBgColor='#F5D6F6'; // Background color when mouse is not over
var LowSubBgColor='#F5D6F6'; // Background color when mouse is not over on subs
var HighBgColor='#C8C9E6'; // Background color when mouse is over
var HighSubBgColor='#C8C9E6'; // Background color when mouse is over on subs
var FontLowColor='A85397'; // Font color when mouse is not over
var FontSubLowColor='A85397'; // Font color subs when mouse is not over
var FontHighColor='#3d3d5d'; // Font color when mouse is over
var FontSubHighColor='#3d3d5d'; // Font color subs when mouse is over
var BorderColor=''; // Border color
var BorderSubColor=''; // Border color for subs
var BorderWidth=0; // Border width
var BorderBtwnElmnts=2; // Border between elements 1 or 0
var FontFamily="verdana,arial,helvetica" // Font family menu items
var FontSize=12; // Font size menu items
var FontBold=0; // Bold menu items 1 or 0
var FontItalic=0; // Italic menu items 1 or 0
var MenuTextCentered='center'; // Item text position 'left', 'center' or 'right'
var MenuCentered='left'; // Menu horizontal position 'left', 'center' or 'right'
var MenuVerticalCentered='top'; // Menu vertical position 'top', 'middle','bottom' or static
var ChildOverlap=''; // horizontal overlap child/ parent
var ChildVerticalOverlap=''; // vertical overlap child/ parent
var StartTop=0; // Menu offset x coordinate
var StartLeft=0; // Menu offset y coordinate
var VerCorrect=0; // Multiple frames y correction
var HorCorrect=0; // Multiple frames x correction
var LeftPaddng=3; // Left padding
var TopPaddng=2; // Top padding
var FirstLineHorizontal=0; // SET TO 1 FOR HORIZONTAL MENU, 0 FOR VERTICAL
var MenuFramesVertical=1; // Frames in cols or rows 1 or 0
var DissapearDelay=500; // delay before menu folds in
var TakeOverBgColor=1; // Menu frame takes over background color subitem frame
var FirstLineFrame='navig'; // Frame where first level appears
var SecLineFrame='space'; // Frame where sub levels appear
var DocTargetFrame='space'; // Frame where target documents appear
var TargetLoc='MenuPos'; // span id for relative positioning
var HideTop=0; // Hide first level when loading new document 1 or 0
var MenuWrap=1; // enables/ disables menu wrap 1 or 0
var RightToLeft=0; // enables/ disables right to left unfold 1 or 0
var UnfoldsOnClick=0; // Level 1 unfolds onclick/ onmouseover
var WebMasterCheck=0; // menu tree checking on or off 1 or 0
var ShowArrow=1; // Uses arrow gifs when 1
var KeepHilite=1; // Keep selected path highligthed
var Arrws=['scripts/tri1.gif',5,10,'scripts/tridown1.gif',10,5,'scripts/trileft1.gif',5,10]; // Arrow source, width and height

function BeforeStart(){return}
function AfterBuild(){return}
function BeforeFirstOpen(){return}
function AfterCloseAll(){return}

I removed this also but anyway no effect.
The menu is still 10 px left

01-07-2008, 05:51 AM
Hi Bernd,

Are you able to center the whole thing on screen with this menu?
I use this menu, too. And want to center my site but no luck.
Anyone can help please!


02-11-2008, 06:32 PM
I'm having a similar (perhaps the same) problem with a website I'm working on.

In IE the page looks great. In Firefox and Safari the page is all messed up. The menu is about 5-10 pixels off center to the right. Any clues?

02-11-2008, 08:23 PM
I had a this problem last year.

I found this bit of information in the hv menu config file.

The different ways that browsers interpret the pageX and pageY offset makes this feature difficult. I got the best results by putting the div inside a table, give the div the same dimensions as the first level menu, put a transparent image inside the div with again the same dimensions as the first level menu

<div id='MenuPos' style='position:relative; width:102; height:102;'><img src='transparent.gif' width='102' height='102'></div>

This solved the problem for me in firefox.