For Programmers: Free Programming Magazines  


Home > Archive > PHP Smarty Templates > September 2004 > includes









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author includes
Pete M

2004-09-02, 4:01 pm

is there a more elegant way to code below..The variable companed is also
tpart of the file name

{if $report_type == 'general'}
{include file="reports.general.inc.html"}

{elseif $report_type == 'ppm'}
{include file="reports.ppm.inc.html"}

{elseif $report_type == 'finance'}
{include file="reports.finance.inc.html"}

{elseif $report_type == 'testing'}
{include file="reports.testing.inc.html"}
{/if}
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com