Skip to main content

Vertical navigation menu with sub menus dropping to the right of anchor

verticalmenu A flexible menu script that can enables drop down sub menus to the right of each menu link. Each drop down menu is simply implemented as plain HTML on the page, making them search engine friendly and simple to edit and deploy. Here are the highlights of this script:

  • Ability to style the currently selected anchor link using CSS, or for image anchors
  • Global settings to set the delay before each menu disappears onMouseout
  • Decides itself whether to enable shadows and a fade-in effect when the menu is revealed

Click here to see the demo


Steps to follow:

1. Login into your Blogger dashboard > Layouts > Edit HTML

2. Insert the following section code below into your template right after the section code: ]]></b:skin>
<link href='http://www./scripts/anylinkcssmenu.css' rel='stylesheet' type='text/css'/>

<script src='http://www./scripts/anylinkcssmenu.js' type='text/javascript'>
</script>

<script type='text/javascript'>
//anylinkcssmenu.init(&quot;menu_anchors_class&quot;) ////Pass in the CSS class of anchor links (that contain a sub menu)
anylinkcssmenu.init(&quot;anchorclass&quot;)
</script>

<style type='text/css'>
/*Credits: Dynamic Drive CSS Library */
/*URL: http://www.dynamicdrive.com/style/ */
.urbangreymenu{
width: 170px; /*width of menu*/
}

.urbangreymenu .headerbar{
font: bold 13px Verdana;
color: white;
background: #606060;
margin-bottom: 0; /*bottom spacing between header and rest of content*/
text-transform: uppercase;
text-indent: 10px;
padding: 7px 0 7px 0; /*31px is left indentation of header text*/
}

.urbangreymenu ul{
list-style-type: none;
margin: 0;
padding: 0;
margin-bottom: 0; /*bottom spacing between each UL and rest of content*/
}

.urbangreymenu ul li{
padding-bottom: 2px; /*bottom spacing between menu items*/
}

.urbangreymenu ul li a{
font: normal 12px Arial;
color: black;
position: relative;
background: #E9E9E9;
display: block;
padding: 5px 0;
line-height: 17px;
padding-left: 8px; /*link text is indented 8px*/
text-decoration: none;
}

.urbangreymenu ul li a:visited{
color: black;
}

.urbangreymenu ul li a:hover, .urbangreymenu ul li a.selectedanchor{ /*hover state CSS*/
color: white;
background: black;
}
</style>
Note: The above code references the external .js file "anylinkcssmenu.js” , "anylinkcssmenu.js”, which you need to download (right click, and select "Save As").

3. Navigate over to Layout > Page Elements to “Add a Gadget” and paste the following section code below into the box.
<div id="submenu3" class="anylinkcsscols">

<div class="column"> 
<b>title</b> 
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>
</div>

<div class="column">
    <b>title</b> 
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>
</div>

<div class="column">
    <b>title</b>

          <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>
</div>

</div><!--webbot bot="HTMLMarkup" endspan i-checksum="32594" -->
<p align="left"><b>Demo:(sub menus drop to the right of
anchor):</b></p>
<p align="left"><!--webbot bot="HTMLMarkup" startspan --><div class="urbangreymenu">

<h3 class="headerbar">Resources</h3>

          <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>
</div>

<div id="submenu2" style="width: 150px; background:#E9E9E9" class="anylinkcss"> 
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>

</div><!--webbot bot="HTMLMarkup" endspan i-checksum="55946" --></p>

<p align="left"><!--4th anchor link-->

<p><a data-image="news.gif" data-overimage="newsover.gif" href=http://.com class="anchorclass" rel="submenu4"><img style="border-width:0" src="news.gif"/></a></p>

<div id="submenu4" style="background: #FEEBAB" class="anylinkcsscols">

<div class="column"> 
    <b>title</b>
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>

</div>

<div class="column">

        <b>title</b>
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>

</div>

<div class="column">
    <b>title</b>
    <ul>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    <li><a href="http://.com">link</a></li>
    </ul>
</div>
</div>

Note: Replace to your links and navigation, CSS can also be modified to fit your template.

4. Save the HTML and view your template.

** Tutorial completed

Comments

Popular posts from this blog

How to add a calendar icon as date header

From this tutorial, you will be able to add your very own calendar icon to your blogger! If you’re going to show the date on every post, why not do it with a little style and make it a little more appealing to viewers? If you want your calendar icon to appear on every post, read Blogspot Vision’s post on how to do that by clicking here to go to the post. Let’s get started but first and foremost, make sure you back-up your existing template, just in case it doesn’t turn out as expected. Steps to follow:1. Login to your Blogger dashboard2. Go to Layout > Edit HTML (Click on “expand widgets” box)3. Search for the following section code: ]]></b:skin>
and add the following section code below right before it:.post .date {
    height: 50px;
    width: 45px;
    background: url(http://www.blogspotvision.com/bspotvision/itheme-calendar.gif) no-repeat;
    font: normal 22px Arial;
    color: #666666;
    text-align: center;
    …

CSS DIV boxes with drop shadows

This example shows how to add a drop shadow style to any container element using CSS. It does this by wrapping the desired content in a DIV with its background color set to a color of the desired color for the shadow. Another DIV is set for your content and is shifted slightly upwards and to the left to expose the shadow. The "master" DIV wraps it all up but is shifted to the right and downwards, returning the entire markup to it's original page position.

IE6 is not compatible with this example, but you can apply conditional HTML to hide the effect in that browser. In contrast, IE7 is compatible with this example for finally updating to proper CSS.

Note: If you will be using an image for your content, you should give ".shadowcontainer" an explicit height, reflecting that of the image's for fixed and set location when viewed.



CSS Code
<![if !IE 6]>
.shiftcontainer{
position: relative;
left: 5px; /*Number should match -left shadow depth below*/
top: 5px;…

How To Show The Post Date On Every Post

From this tutorial, you will be able to show the post date on every last one of your posts. As we all know, Blogger’s default templates only show a single date for every post that was posted that day. Some readers will find it convenient to have that quick glance at the date on each post, but some will not even notice. This tutorial is definitely handy if you plan to use a calendar icon as your post date, since the timestamp can be modified. As always, make sure you download your current existing template just in case it doesn’t turn out as expected.

Steps to follow:
1.Login to your Blogger dashboard.
2. Go to Layout > Edit HTML (click on “expand widgets” box)
3. Now search for the red line of code or similar code:Note: If you can’t seem to find the line in red, try the second section code in blue.<div class='post-feeds'>
<b:loop values='data:posts' var='post'>
<b:if cond='data:post.dateHeader'>
<h2 class='date-header'>
<da…