Jump to content

How do I add a customized Menu


nexiss

Recommended Posts

Hi all

I have been playing with a customized button thing for a while now and am stuck, I have the menu working see here: http://www.nexissair.co.uk/Buttons.htm'>http://www.nexissair.co.uk/Buttons.htm

How do I get that into my site here: http://www.nexissair.co.uk

keeping the functions of the core_nav? i.e. when not logged in the downloads and pilot area will not show up.

I'm struggeling abit now and any help would be great, I can get it to work as an htm file but as soon as I try and build it into the core_nav.tpl it all goes belly up.

Link to comment
Share on other sites

Ok I watched the tutoral as advised, while very helpful and gave me more idea of what I should be doing, I clearly did something wrong, I completley destroyed my site layout, fortunatly I was playing with my test site and not my live site.

The code for my working menu is:

<link rel="stylesheet" href="Buttons_files/cbcscbButtons.css" type="text/css" />

<ul id="ebul_cbButtons_3" class="ebul_cbButtons" style="display: none;">

<li><a title="">Forum</a></li>

<li><a title="">Links</a></li>

<li><a title="">Rules</a></li>

<li><a title="">Sign Up</a></li>

</ul>

<ul id="ebul_cbButtons_4" class="ebul_cbButtons" style="display: none;">

<li><a title="">Profile</a></li>

<li><a title="">Flight Bids</a></li>

<li><a title="">My Pireps</a></li>

<li><a title="">My Flights</a></li>

<li><a title="">Login</a></li>

</ul>

<ul id="ebul_cbButtons_5" class="ebul_cbButtons" style="display: none;">

<li><a title="">Roster</a></li>

<li><a title="">Fleet Info</a></li>

<li><a title="">Hubs Info</a></li>

</ul>

<ul id="ebul_cbButtons_6" class="ebul_cbButtons" style="display: none;">

<li><a title="">Schedule</a></li>

<li><a title="">Live Map</a></li>

</ul>

<ul id="ebul_cbButtons_7" class="ebul_cbButtons" style="display: none;">

<li><a title="">Flight Plans</a></li>

<li><a title="">Fleet</a></li>

<li><a title="">Hubs</a></li>

<li><a title="">Scenery</a></li>

</ul>

<table id="cbButtonsebul_table" width="0" cellpadding="0" cellspacing="0" border="0">

<tr>

  <td style="padding-right:1px" title="Home"><a href="<?php echo SITE_URL ?>/index.php/Frontpage"><img id="cbi_cbButtons_1" src="Buttons_files/ebbtcbButtons1_0.gif" name="ebbcbButtons_1" width="39" height="26" border="0" alt="Home" title="Home" /></a></td>

  <td style="padding-right:1px" title="Contact Us"><a href="<?php echo SITE_URL ?>/index.php/contact"><img id="cbi_cbButtons_2" src="Buttons_files/ebbtcbButtons2_0.gif" name="ebbcbButtons_2" width="65" height="26" border="0" alt="Contact Us" title="Contact Us" /></a></td>

  <td style="padding-right:1px" title=""><a><img id="cbi_cbButtons_3" src="Buttons_files/ebbtcbButtons3_0.gif" name="ebbcbButtons_3" width="63" height="26" border="0" alt="General" title="" /></a></td>

  <td style="padding-right:1px" title=""><a><img id="cbi_cbButtons_4" src="Buttons_files/ebbtcbButtons4_0.gif" name="ebbcbButtons_4" width="71" height="26" border="0" alt="Pilot Area" title="" /></a></td>

  <td style="padding-right:1px" title=""><a><img id="cbi_cbButtons_5" src="Buttons_files/ebbtcbButtons5_0.gif" name="ebbcbButtons_5" width="78" height="26" border="0" alt="Operations" title="" /></a></td>

  <td style="padding-right:1px" title=""><a><img id="cbi_cbButtons_6" src="Buttons_files/ebbtcbButtons6_0.gif" name="ebbcbButtons_6" width="56" height="26" border="0" alt="Flights" title="" /></a></td>

  <td style="padding-right:1px" title=""><a><img id="cbi_cbButtons_7" src="Buttons_files/ebbtcbButtons7_0.gif" name="ebbcbButtons_7" width="80" height="26" border="0" alt="Downloads" title="" /></a></td>

</tr>

</table>

<script type="text/javascript" src="Buttons_files/cbjscbButtons.js"></script>

I still have no idea of how to get this into the core.nav.tpl without messing up the site layout

any advise or code snippets would be great

Link to comment
Share on other sites

  • Administrators

Try using absolute paths to the CSS and files, ie:

<link rel="stylesheet" href="<?php echo SITE_URL?>/Buttons_files/cbcscbButtons.css" type="text/css" />
<script type="text/javascript" src="<?php echo SITE_URL?>/Buttons_files/cbjscbButtons.js"></script>

Link to comment
Share on other sites

ok no panic I'm slowly working it out, it had something to do with the java script, for some reason it wouldn't work with href="<?php echo SITE_URL?>/Buttons_files/cbcscbButtons.gif I had to use absolute paths for the alternate images, and I didn't have the full table code either, so that was  what was messing up the page (open ended table I guess). I just need to work out the login logout and register button side of things depending on if I am logged in or not.

Thanks for your help so far on this.

Link to comment
Share on other sites

mmmm I have a logout button issue, even when I'm logged out it still shows up, sure I have missed some thing but can't spot it it, could someone take a look for me please? Many thanks.

<?php echo $MODULE_NAV_INC;?>

<?php

if(Auth::LoggedIn())

{

if(Auth::UserInGroup('Administrators'))

{

echo '<td style="padding-right:1px" title=""><a href="'.SITE_URL.'/admin/"><img id="cbi_cbButtons_10" src="<?php echo SITE_URL ?>/lib/skins/nexiss/Buttons_files/ebbtcbButtons10_0.gif" name="ebbcbButtons_10" width="76" height="26" border="0" alt="Administrator" title="" /></a></td>';

}

?>

<td style="padding-right:1px" title="Logout"><a href="<?php echo SITE_URL ?>/index.php/login/logout"><img id="cbi_cbButtons_8" src="<?php echo SITE_URL ?>/lib/skins/nexiss/Buttons_files/ebbtcbButtons8_0.gif" name="ebbcbButtons_8" width="45" height="26" border="0" alt="Logout" title="" /></td>

<?php

}

?>

</tr>

</table>

<script type="text/javascript" src="<?php echo SITE_URL ?>/lib/skins/nexiss/Buttons_files/cbjscbButtons.js"></script>

Link to comment
Share on other sites

You could try not even using the core_nav template. Just open your header.tpl file and put in the nav with the java and all the fancy stuff including the php auth and whatnot. It would still work like it was calling from that template but you may have a little more control over what is working and what is not, worth a shot.

Link to comment
Share on other sites

  • 1 month later...

You could try not even using the core_nav template. Just open your header.tpl file and put in the nav with the java and all the fancy stuff including the php auth and whatnot. It would still work like it was calling from that template but you may have a little more control over what is working and what is not, worth a shot.

Hi I'm having the same problem as Nexiss. I am trying the approach mentioned in the quotes and the result I get is this: http://www.flymelita.com/

The menu should appear like this: http://www.flymelita.com/lib/skins/Melita/smoothmenu.htm

As you can see. When put on its own, the menu looks and functions perfectly. However, when I try to implement it in either the core_nav or header files, the results are less pleasing. So far, I achieved the best result by editing the header.tpl. When I tried modifying the core_nav, awful things went on! I did watch the tutorial but I didn't find it much helpful. And it seems that all that is missing is just a working javascript.

Again, I do have the javascript coded and implemented but it seems to be failing to work when put into either files. Any help?

Link to comment
Share on other sites

Ok, I got it running. Just had to refer the javascript's location. However, there's just one detail missing: The dropdowns. Now they are listed in the code but when I view the site, they just don't show up. So I just get the "Titles" but no drop downs show up

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...