Jump to content

How to add category title and description on the category page ? (category.tpl)


Recommended Posts

Hello everyone,

I created a website last year using PrestaShop 1.5.6.1 and TimeShop theme.

I have a question and I hope someone could help me.

How can I display the category title and description under the category image on the category page ?

For example, you can see this page alive :http://www.tamel.fr/7-sites-internet I would like to display the category title and description under the image, or above on this page. Is it possible ? If not, is it possible to display it on the right column ? It cans be very good too.

 

I think that I have to modify the themes/timeshop/category.tpl file and I don't know how to call the category title and description data.

	<!-- Category image -->
		{if $category->id_image}
		<div class="align_center">
			<img src="{$link->getCatImageLink($category->link_rewrite, $category->id_image, 'category')}" alt="{$category->name|escape:'htmlall':'UTF-8'}" title="{$category->name|escape:'htmlall':'UTF-8'}" id="categoryImage"/>
		</div>
		{/if}
		

I think it's there. I read the documentation on the web, but as a non-developer, I didn't find what I need : How to call the category title and description on the category.tpl file ?

 

Thanks a lot for your help

Link to comment
Share on other sites

hello mehdi09

in your category.tpl file just add

<span class="category-descctiption-name">
            {strip}
                {$category->name|escape:'html':'UTF-8'}
                {$category->description}
            {/strip}
</span>

just below the category image. you will able to see the name and description about that category.

  • Like 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...