it's like that because I'm writing an HTML templating scheme. I'd use the s00p0r regex to resolve it:
$template =~ s {%% (.*?) %%}
{exists ($fillings->{$1})
? $fillings->{$1}
: ""
}gsex;
... but I need to be able to more gracefully handle errors than just putting a "" in.
f. | [reply] [d/l] |
| [reply] |
Well, basic it may be, however I've never done it. So what? Normally I work around it because I've known that "down the eval path usually lie monsters".. I mean, duh!
As for the templating, so what? Why does it bother you? I've used Mason and an early version of EmbPerl, and they both proved to be OK (Mason a bit more so), however both
were painful to setup and messy in the logs. I don't purport to be writing Sheer Geniosity(tm) here, but I have the time for writing a templating system in an environment
where it is likely that I will be the only one looking at the code. It's the third revision of a system, the second I wrote, and the first I maintained.
I appreciate the assistance I get here, even on the 'easy ones' but I can do without the smack.
ismail
| [reply] |