Hi guys, I wonder if someone can help?
First off, let me explain what I'm trying to do. I have a left hand sidebar with a menu, I want my members to be able to turn it off and on with a switch. I'm trying to do it with the collapse elements tag but with mixed sucess - well it works in IE6, but falls flat in Firefox and I dont know why.
Here's what I have so far...
you can see the little graphic in the navbar that turns the menu on...
...here it is in the "on" state, with the menu visible...
It seems to work OK with IE, it remembers which state it's supposed to be, through page refresh and so on. However it doesnt work properly in Firefox, which I cant figure out why because all the other collapsable elements work fine.
Here's what I've done:
I have two images in my "buttons folder"....
collapse_sidebar_collapsed.gif
collapse_sidebar.gif
Here's the code I have in my navbar....
Here's what I have in the sidebar table (which I've put in the forumhome and forumdisplay templates)....
I followed the tips in this thread and tried the variations suggested there, starting with the simplest and moving to the more complex code which calls $GLOBALS (thinking it is falling over because I have the collapse image in a "...bits" template).
As I said, it seems to work OK in IE (some minor wierdness when a page is loaded with the navbar, but doesnt have the collapsable element in the page content). But it doesnt work at all in Firefox.
Can anyone help?
Thanks.
First off, let me explain what I'm trying to do. I have a left hand sidebar with a menu, I want my members to be able to turn it off and on with a switch. I'm trying to do it with the collapse elements tag but with mixed sucess - well it works in IE6, but falls flat in Firefox and I dont know why.
Here's what I have so far...
you can see the little graphic in the navbar that turns the menu on...
...here it is in the "on" state, with the menu visible...
It seems to work OK with IE, it remembers which state it's supposed to be, through page refresh and so on. However it doesnt work properly in Firefox, which I cant figure out why because all the other collapsable elements work fine.
Here's what I've done:
I have two images in my "buttons folder"....
collapse_sidebar_collapsed.gif
collapse_sidebar.gif
Here's the code I have in my navbar....
PHP Code:
<td class="vbmenu_control"> <a href="" onclick="return toggle_collapse('sidebar')"><img id="collapseimg_sidebar" src="$stylevar[imgdir_button]/collapse_sidebar{$GLOBALS['vbcollapse']['collapseimg_sidebar']}.gif" border="0" /></a></td>
PHP Code:
<td style="width:150px" id="collapseobj_sidebar" style="{$GLOBALS['vbcollapse']['collapseobj_sidebar']}" valign="top">$sidebar</td>
As I said, it seems to work OK in IE (some minor wierdness when a page is loaded with the navbar, but doesnt have the collapsable element in the page content). But it doesnt work at all in Firefox.
Can anyone help?
Thanks.
Comment