Cataloger use $page_alias as alias parameter

Have a question or a suggestion about a 3rd party addon module or plugin?
Let us know here.
Post Reply
kneep
Forum Members
Forum Members
Posts: 20
Joined: Mon Jul 28, 2008 7:45 am
Location: Netherlands

Cataloger use $page_alias as alias parameter

Post by kneep »

Hi there, I'm using the Cataloger module (0.11.3) in combination with CMS MS 1.11.4 and want to use the variable $page_alias from the CMS as the alias parameter for the Cataloger module. This is the code i'm using in a template:

Code: Select all

{Cataloger action='random' sub_template='previews_klein' count='6' alias='/'}
But instead of alias='/' i want to use alias='$page_alias', but i have tried several options ({eval var=$page_alias}) but none of them worked.

Does anyone have a solution for this problem? thanks in advance!
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1931
Joined: Mon Jan 29, 2007 4:47 pm

Re: Cataloger use $page_alias as alias parameter

Post by Jo Morg »

Did you try:

Code: Select all

{Cataloger action='random' sub_template='previews_klein' count='6' alias=$page_alias}
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
kneep
Forum Members
Forum Members
Posts: 20
Joined: Mon Jul 28, 2008 7:45 am
Location: Netherlands

Re: Cataloger use $page_alias as alias parameter

Post by kneep »

Thanks for the reply, i solved it in another way by using the sub templates.

Do you have any idea if it is possible to add an input text field to the images tab for adding alt-text to each image different?
Hope someone has an idea for that!
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1931
Joined: Mon Jan 29, 2007 4:47 pm

Re: Cataloger use $page_alias as alias parameter

Post by Jo Morg »

If you take a close look at the sub-templates you will find something like:

Code: Select all

<a href="javascript:repl('{$image_url_array[ind]}')"><img src="{$image_thumb_url_array[ind]}" title="{$title}" alt="{$title}" /></a>
If {$title} is not what you are after you can create a custom field and use it instead of {$title}.Or add ind on alt like this

Code: Select all

<a href="javascript:repl('{$image_url_array[ind]}')"><img src="{$image_thumb_url_array[ind]}" title="{$title}" alt="{$title}_{$smarty.section.ind.index}" /></a>
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1931
Joined: Mon Jan 29, 2007 4:47 pm

Re: Cataloger use $page_alias as alias parameter

Post by Jo Morg »

I corrected my original reply as the code wasn't correct. It should be ok now...
"There are 10 types of people in this world, those who understand binary... and those who don't."
* by the way: English is NOT my native language (sorry for any mistakes...).
Code of Condut | CMSMS Docs | Help Support CMSMS
My developer Page on the Forge
GeekMoot 2015 in Ghent, Belgium: I was there!
GeekMoot 2016 in Leicester, UK: I was there!
DevMoot 2023 in Cynwyd, Wales: I was there!
Post Reply

Return to “Modules/Add-Ons”