Page 1 of 1

User Defined Tags Help

Posted: Tue Mar 30, 2010 3:20 am
by sublime5o
I have a simple php tag that i cant get to work that i wanted to use as a user defined tag...  Here is the php



When i put this as a user defined tag as

= $image_rotation;

It wont let me add it because of the starting =

Any suggestions...

Re: User Defined Tags Help

Posted: Tue Mar 30, 2010 3:24 am
by JeremyBASS
= is not vaild php.. that is why... I bet you need assign.. in the template.. {assign var=foo value=$image_rotation}{$foo} , you'd want to read the smarty man too.. goole smarty php...  Also <?php is not allowed in there ... you only need the code... HTH -J

Re: User Defined Tags Help

Posted: Tue Mar 30, 2010 3:35 am
by sublime5o
Thanks for your help.  It makes sense.  Ive tried what you said but still nothing....

I will get to reading up on Smarty but its pretty extensive.  Can you look at my code and see what im doing wrong?  I will post what i have now..


       
{literal}

$(document).ready(function() {
$('#image_rotate').innerfade({
speed: 'slow',
timeout: 4000,
type: 'sequence',
containerheight: '220px'
});
});

{/literal}
         
{assign var=foo value=$image_rotation}{$foo}