View Single Post
  #1  
Old 03-31-2006, 10:52 AM
 
brettcta brettcta is offline
 

Newbie
  
Join Date: Mar 2006
Location: Chicago, IL
Posts: 5
 

Default Can I hide the active category/product name in location.tpl?

Hello. I've been looking around for a tip on this to no avail.

I'm finding the default format of location.tpl to be redundant. If the customer is in this category path:

Home/Media Types/Audio

then I want location.tpl to show only:

Home :: Media Types

because the active category, Audio, is already displayed immediately below location.tpl.

This is even more significant when looking at products, since I have a number of products with fairly long titles that can't really be abbreviated (book titles, etc). When they're displayed in location.tpl, the text of the longer titles wraps, which looks sloppy as well as redundant. For example, if the customer is viewing the product details at this path:

Home/Media Types/Books/"Manufacturing Consent - The Political Economy of the Mass Media - Herman & Chomsky"

then I want location.tpl to only display:

Home :: Media Types :: Books

as opposed to the entire path with product name.

At the very least, if its easier to just eliminate the :: (product name) portion from location.tpl, that's fine by me, as I can get along fine with having the active category showing. It's mainly the product in location.tpl that I want to get rid of. Unfortunately, after messing around with it for a while now, I still haven't figured out how to do it (hence this post).

If anyone has any advice on how to modify location.tpl to achieve this, or if there is already a mod to accomplish this that someone might forward me to, I'd greatly appreciate it. Thanks!!

And thanks to TelaFirma and balinor for two other mods that I've incorporated to make location.tpl a little more user friendly! Which reminds me, this is the code I currently am using for location.tpl, in case it helps:

Code:
{if $location} <FONT class="NavigationPath"> {strip} Home:: {section name=position loop=$location start=1} {if $location[position].1 ne "" }<A href="{$location[position].1}" class="NavigationPath">{/if} {$location[position].0} {if $location[position].1 ne "" }</A>{/if} {if not %position.last%}::{/if} {/section} {/strip} </FONT> {/if}
__________________
-----
X-Cart Gold 4.0.18
Reply With Quote