Smarty Forum Index Smarty
WARNING: All discussion is moving to https://reddit.com/r/smarty, please go there! This forum will be closing soon.

Search found 3 matches
Smarty Forum Index
Author Message
  Topic: break and continue for looping functions
Kim Steinhaug

Replies: 11
Views: 168022

PostForum: Smarty 3   Posted: Mon Apr 26, 2010 11:20 am   Subject: break and continue for looping functions
This works prefectly. Just note that when copying the above snippets there are some spaces inserted which you must remove manually.

To sum it up:
In your libs/plugins folder create 2 new files:
...
  Topic: smary assign question
Kim Steinhaug

Replies: 4
Views: 6146

PostForum: General   Posted: Mon Apr 26, 2010 11:19 am   Subject: smary assign question
Whai I usually do is when pulling the data from MySQL I iterate through the result set and build an array. Then I assign the array for smarty.

From smarty I can then use smartys internal foreach me ...
  Topic: Hey guys beginner question
Kim Steinhaug

Replies: 6
Views: 8164

PostForum: General   Posted: Mon Apr 26, 2010 11:17 am   Subject: Hey guys beginner question
Directly in the template, you could do this:

{assign var='test' value='1'}
{if $test}
{else}
{/if}

Regards,
Kim Steinhaug
 
Page 1 of 1
All times are GMT
Jump to:  


Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP