Results 11 to 12 of 12
-
25th Mar 2012, 07:52 AM #11OPMember
-
25th Mar 2012, 04:03 PM #12Respected Member
Try this
Code:<html> <head> <style type="text/css"> .item { width:900px; padding:0; margin:0; list-style-type:none; } a { display:block; width:60; line-height:25px; /*24px*/ border-bottom:1px none #808080; font-family:'arial narrow',sans-serif; color:#00F; text-align:center; text-decoration:none; background:#CCC; border-radius: 5px; -webkit-border-radius: 5px; -moz-border-radius: 5px; margin-bottom:0em; padding: 0px; } a.item { float:left; /* For horizontal left to right display. */ width:145px; /* For maintaining equal */ margin-right: 5px; /* space between two boxes. */ } a.selected{ background:orange; color:white; } </style> </head> <body> <a href="/" class="item">Home</a> <a href="/myaccount" class="item">My Account</a> <a href="/editaccount" class="item">Edit Account</a> <a href="/logout" class="item">Logout</a> <script> var anchorArr=document.getElementsByTagName("a"); var prevA=""; for(var i=0;i<anchorArr.length;i++) { anchorArr[i].onclick = function(){ if(prevA!="" && prevA!=this) { prevA.className="item"; } this.className="item selected"; prevA=this; } } </script> </body> </html>
Sponsored Links
Thread Information
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Similar Threads
-
Highlight searched text plugin
By r00ts in forum WordpressReplies: 2Last Post: 9th Apr 2012, 07:10 PM -
[Hiring] Simple PHP Job
By Apathetic in forum Completed TransactionsReplies: 0Last Post: 14th Sep 2011, 02:08 AM -
[Hiring] $10 simple job :D
By viruz99 in forum Completed TransactionsReplies: 8Last Post: 28th Nov 2010, 07:22 AM -
Something Simple
By w00ty in forum Graphics AreaReplies: 0Last Post: 14th Jul 2010, 07:58 AM -
Its seems so simple ...
By S?nic in forum IP.BoardReplies: 8Last Post: 20th Sep 2009, 12:42 AM
themaManager - edit and manage...
Version 4.04 released. Open older version (or...