(SOLVED) Smarty plugin not being seen

The place to talk about things that are related to CMS Made simple, but don't fit anywhere else.
Post Reply
Andrew Prior
Forum Members
Forum Members
Posts: 247
Joined: Sun Oct 28, 2007 4:14 am

(SOLVED) Smarty plugin not being seen

Post by Andrew Prior »

I have upgraded from Bartolome to San Christobel.

I have a reverse menu template which has these lines

Code: Select all

{* foreach from=$nodelist item=node *}
{foreach from=$nodelist|@reverse_array item=node}
The first line is the original simple template line, and my modification is to refer to the file modifier.reverse_array.php in the libs/smarty/plugins directory.

This came from a post by Nullig many moons ago.

Code: Select all

 http://forum.cmsmadesimple.org/viewtopic.php?t=22370
I now get the following error

Code: Select all

 Syntax error in template "module_db_tpl:MenuManager;simple_reverse"  on line 12 "{foreach from=$nodelist|@reverse_array item=node}" unknown modifier "reverse_array"


The file is definitely in the same place, so I am guessing there is some smarty 3 issue happening here. How should I reference the reverse_array modifier?

(If I use the original template all is fine, but of course my reverse menus don't happen.)
Last edited by Andrew Prior on Thu Oct 23, 2014 6:36 am, edited 1 time in total.
User avatar
Jo Morg
Dev Team Member
Dev Team Member
Posts: 1974
Joined: Mon Jan 29, 2007 4:47 pm

Re: Smarty plugin not being seen

Post by Jo Morg »

Andrew Prior wrote:The file is definitely in the same place, so I am guessing there is some smarty 3 issue happening here.
Yes, the Smarty plugins folder was moved, for some reason, to lib\smarty\libs\plugins.
You'll have to move the file there. Alternatively you can move it to the CMSMS own plugins folder: it should work iirc, and will avoid further problems with Smarty changing its folder structure again.
HTH
"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!
Andrew Prior
Forum Members
Forum Members
Posts: 247
Joined: Sun Oct 28, 2007 4:14 am

Re: Smarty plugin not being seen

Post by Andrew Prior »

Awesome Jo. The plugins folder for CMsMadeSimple works. Thankyou
Post Reply

Return to “The Lounge”