View Single Post
  #1  
Old 05-03-2010, 01:18 PM
  FTI's Avatar 
FTI FTI is offline
 

Senior Member
  
Join Date: Oct 2009
Location: Plovdiv, Bulgaria
Posts: 153
 

Default Highlight current page in speedbar

Hi there, currently I'm trying to highlight the speedbar link for the current page on which the user is. See the attached image to get my idea. So basicly when a user clicks on contacts in the speed bar, the contacts box link stays highlighted, which will make the menu more user-friendly. At first I thought this could be done with the active link property in CSS, but unfortunatelly it can't. So I've searched google and found out a way, but I'm not quite sure how to integrate this with X-Cart, so what we should do is assign id for the body of each page we have link to in the speed bar like this:

Code:
<body class=■home■>

And after that for each link we must add a custom class like this:

Code:
<ul> <li><a href=■home■ class=■home■>Home</a> <li><a href=■articles.html■ class=■articles■>Articles</a> <li><a href=■blog.html■ class=■blog■>Blog</a> ┘ etc┘ </ul>


And then we must add the custom classes in our CSS like this:


Code:
body.home a.home, body.articles a.articles, body.blog a.blog { background-color: green; }

That sounds reasonable when we are dealing with HTML, but how to do this with X-Cart and Smarty. I really need this one and it is a feature, that everybody will enjoy. Can someone point me out to the right files that we need to edit and tell me how to adapt the code to use with this great shopping cart system?
Attached Thumbnails
Click image for larger version

Name:	bump.jpg
Views:	256
Size:	41.1 KB
ID:	1931  
__________________
Version 4.2.3
X-Cart Gold

Version 4.3.1
X-Cart Gold
Reply With Quote