Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PHP

smarty switch case

{* 
	There is no switch in Smarty 
	Use if-statement, plugin or php instead
*}

{if $case1_as_condition}
   Case 1
{elseif $case2_as_condition}
   Case 2, etc
{else}
   Default
{/if}
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #smarty #switch #case
ADD COMMENT
Topic
Name
6+7 =