McRae Posted October 10, 2017 Share Posted October 10, 2017 Hi, I'm working on the category.tpl file of my theme, and i try to get the ID of the current category to feed a parameter of my hook, which shouldn't be very hard... http://domain.com/fr/content/category/3-category-name but i can't understand through which object/array or function i can get it since $cms and $category are not available. Any help ? Thanks {extends file=$layout} {block name='content'} <section id="main"> {block name='page_header_container'} <header class="page-header"> {block name='page_header'} <h1>Blog</h1> {/block} </header> {/block} {block name='page_content_container'} <section id="content" class="page-content"> {block name='page_content'} {hook h='akblog' id_cat=2} {/block} </section> {/block} {block name='page_footer_container'} <footer class="page-footer"> {block name='page_footer'} <!-- Footer content --> {/block} </footer> {/block} </section> {/block} Link to comment Share on other sites More sharing options...
McRae Posted October 12, 2017 Author Share Posted October 12, 2017 J'ai résolu mon problème et je partage l'info pour ceux qui seraient intéressés : Il suffit d'utiliser la récupération du paramètre de l'URL via {$smarty.get.id_cms_category} Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now