External css menu? - Page 2

User 187934 Photo


Senior Advisor
20,247 posts

Try this.
<?php
if(isset($_SESSION['id'])){
if($_SESSION['adminlevel']>5){
echo '<ul class="menu-menu sf-vertical">';
echo '<li><a href="http://myweb.com/memberlist.php">Member Directory</a></li>';
echo '<li><a href="http://myweb.com/members.php">Member private page</a></li>';
echo '<li><a href="http://myweb.com/info.pdf">Membership Information</a></li>';
echo '<li><a href="http://myweb.com/members.php?page=logout">Logout</a></li>';
echo '</ul>';
echo '<link rel="stylesheet" type="text\/css" href="css\/menu-menu.css" media="screen">';
echo '<link rel="stylesheet" type="text\/css" href="css\/superfish-vertical.css" media="screen">';
}
else { echo '<br>More options coming soon<br>';}
}
?>
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 2600198 Photo


Registered User
2 posts

Eric,

Thanks for your help. It worked. Just have to figure out why the column is irregular width as it re-sized for each link? The preview in Coffee cup shows it properly. I tried re-sizing it with coffecup menu designer so that the label would not word wrap and guess what.... the change fixed the vertical menu in the leftcolumn.inc but then changed the horizontal menu I have pinned in the Header.inc. I will drop the coffeecup folks a line.
see attached screen shot of menu.

Again, Thanks for your help.
Attachments:
User 187934 Photo


Senior Advisor
20,247 posts

If you share a link we might be able to help you out.;)
I can't hear what I'm looking at.
It's easy to overlook something you're not looking for.

This is a site I built for my work.(RSD)
http://esmansgreenhouse.com
This is a site I built for use in my job.(HTML Editor)
https://pestlogbook.com
This is my personal site used for testing and as an easy way to share photos.(RLM imported to RSD)
https://ericrohloff.com
User 289442 Photo


Registered User
161 posts

Johan, this is what I do with old-fashioned SSI :)

Site has approximately 80 pages and building in the main menu. Site is being rebuild from disaster last year. What is there and has link to w3c validates as html5. The bits of code I use for example follow, tho they have been truncated for brevity. Go to the site and you can retrieve the entire bit, but don't see why that would be necessary.

1. In the BODY section where I want the menue:

<!-- PULL DOWN MENU - BEGIN -->
<!--#include file="mainmenu.ssi" -->
<!-- END OF PULL DOWN MENU -->

2. The main Menu -- Truncated ---

mainmenu.ssi

<div class="mainmenu">

<ul>
<li class="li_nc"><a href="index.html" target="_self" >Home</a></li>
<li class="li_hc"><a href="asae.html" target="_self" >ASAE</a><ul class="ul_ch">
<li class="li_nc"><a href="asaesit.html" target="_self" >ASAE SIT Office</a></li>
<li class="li_hc"><a href="germany-dets1.html" target="_self" >Germany Dets Grp 1</a><ul class="ul_ch">
<li class="li_nc"><a href="bad-nieder-breisig.html" target="_self" >Bad Nieder Breisig</a></li>
<li class="li_nc"><a href="bahrdorf.html" target="_self" >Bahrdorf</a></li>
<li class="li_nc"><a href="bremerhaven.html" target="_self" >Bremerhaven</a></li>
<li class="li_nc"><a href="fritzlar.html" target="_self" >Fritzlar</a></li>
<li class="li_nc"><a href="giebelstadt.html" target="_self" >Giebelstadt</a></li>
<li class="li_nc"><a href="luebeck.html" target="_self" >Luebeck</a></li>
</ul></li>

-------------------Truncated --- About 80 Pages Total in Menu-----------------


<li class="li_nc"><a href="supply.html" target="_self" >Supply</a></li>
<li class="li_hc"><a href="gstbk.php" target="_self" >Guestbook</a><ul class="ul_ch">
<li class="li_nc"><a href="oldgb.html" target="_self" >Guestbook Archives</a></li>
<li class="li_nc"><a href="oldgb.html" target="_self" >News &amp; Reunions</a></li>
</ul></li>
<li class="li_nc"><a href="contact.html" target="_self" >Contact</a></li>
<li class="li_nc"><a href="search.html" target="_self" >Search</a></li>
</ul>


</div>

3. The Main Menu CSS file:

@charset "utf-8";
/* CSS Document */


body {

/* for pull-down menu to work in IE6*/
behavior:url("csshover2.htc");

}

/* pull-down mainmenu css */
.mainmenu{
float: left;
width: 100%;
padding: 0;
}
.mainmenu ul {
float: left;
width: 100%;
list-style: none;
line-height: 1;
color:#FFFFFF;
background: #032031;
padding: 0;
border: solid #032031;
border-width: 1px 0;
margin: 0 0 0 0;
}

---------------------Truncated ----------------------------------------------
.mainmenu ul ul a:hover,
.mainmenu li:hover li:hover a,.mainmenu li:hover li:hover a:visited ,
.mainmenu li:hover li:hover li:hover a,.mainmenu li:hover li:hover li:hover a:visited,
.mainmenu li:hover li:hover li:hover li:hover a,.mainmenu li:hover li:hover li:hover li:hover a:visited ,
.mainmenu li:hover li:hover li:hover li:hover li:hover a,.mainmenu li:hover li:hover li:hover li:hover li:hover a:visited,
.mainmenu li:hover li:hover li:hover li:hover li:hover li:hover a,.mainmenu li:hover li:hover li:hover li:hover li:hover li:hover a:visited{
color: #00FFFF;
}
.mainmenu li:hover li:hover li a,.mainmenu li:hover li:hover li a:visited ,
.mainmenu li:hover li:hover li:hover li a,.mainmenu li:hover li:hover li:hover li a:visited,
.mainmenu li:hover li:hover li:hover li:hover li a,.mainmenu li:hover li:hover li:hover li:hover li a:visited,
.mainmenu li:hover li:hover li:hover li:hover li:hover li a,.mainmenu li:hover li:hover li:hover li:hover li:hover li a:visited{
color: #000000;
}


/* end of mainmenu css */

4. htaccess file excerpt to allow SSI in html pages without shtml

AddHandler server-parsed .html

-----

Url for the site home page www.usasadf.net

All done with CC HTML Editor, except the menu was actually done with CSS Menu Generator and inserted in the html Editor project.

Hope this might add to your thinking about the problem you posted.

Tom

Have something to add? We’d love to hear it!
You must have an account to participate. Please Sign In Here, then join the conversation.