X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Category Name Within Template (https://forum.x-cart.com/showthread.php?t=22151)

Makaveli 05-30-2006 07:47 AM

Category Name Within Template
 
Hello,

Does anybody know the code that I can place within a X-cart template that will display the appropriate category name?

I know some templates already have this code that will make the appropriate category name appear on the page, but I can't seem to find it.

I would like to add this code to other template pages as well.

Thanks in advance.

balinor 05-30-2006 07:49 AM

It depends on where....where would you like to add it?

Makaveli 05-30-2006 08:04 AM

Hi Balinor,

Thanks for the reply. My cart is customized so that each category has it's own template so that I can change the look of each template.

Basically I am making copies of the home.tpl, editing it and renaming the file. I would like to add the category names within these templates.

Thanks!

balinor 05-30-2006 08:19 AM

So you are looking for the code for the current/active category?

Makaveli 05-30-2006 09:12 AM

Yes, that's exactly what I am looking for.

balinor 05-30-2006 09:24 AM

Try:

{$current_category.category}

Makaveli 05-30-2006 09:31 AM

Sweet! It worked. Thanks a lot Balinor. I really appreciate your help!

furthermobile 06-02-2006 09:28 AM

Show main category?
 
I'd like to do something similar but slightly different. I need to show the main category that the product belongs to. I want to show this right next to the product name in the products.tpl template. Showing the current category wont really work since it would change in the subcategories. Any suggestions would be greatly appreciated. Thanks in advance.

x-cartpro v4.1.1 [unix]


All times are GMT -8. The time now is 10:46 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.