|
|
Choosing A Webhost: |
TMPL_IF and TMPL_ELSE - how do I use this?: msg#00039lang.perl.modules.html-template
I've read the documentation sections on TMPL_IF and TMPL_ELSE. The part where I'm getting stuck is figuring out how to set up that "BOOL" value. I know if "BOOL" is true, then the section in TMPL_IF is run; if it's false, the section in TMPL_ELSE is run. This sounds like what I want to do (I think...).
I have my results generated and the web page looks nice. However, there are some rows that need to have a different bit of HTML in it (some rows/cells are to be "drillable" and some are not). Unfortunately, it's not just the "last" or "first", etc.; the rows are interspersed in no particular order, some are contiguous, some are stand-alone.
This is where I get stuck. I can tell where I am in Perl when I'm pushing the hash references to the @loop_data (which is subsequently pushed to the template for output), so I can set a variable to something at that time.
How do I set up a variable that the TMPL_IF and TMPL_ELSE can use to determine which section of the HTML loop to process?
I hope this made sense. When you're new, sometimes it's hard to know even how to ask a question! :-)
Thanks!
Lori Do you Yahoo!? Yahoo! Finance: Get your refund fast by filing online
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: Script under mod_perl occasionally gets garbage opening template, Sam Tregar |
|---|---|
| Next by Date: | Re: TMPL_IF and TMPL_ELSE - how do I use this?, P Kishor |
| Previous by Thread: | event calendar code, Kapoor, Nishikant |
| Next by Thread: | Re: TMPL_IF and TMPL_ELSE - how do I use this?, P Kishor |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |