Perl-Sensitive Sunglasses | |
PerlMonks |
Re: Language or string templates?by Prior Nacre V (Hermit) |
on Oct 02, 2004 at 04:12 UTC ( [id://395822]=note: print w/replies, xml ) | Need Help?? |
Here's a fairly straightforward solution framework that may be suitable for your application. Create a text/language file with this format:
Then in your main code, slurp in the whole file and create a hash which can then be used when required.
Update: Sorry, I had two solutions in my head - I posted half of each. I've added two lines to the main code replacing: my %globals = ( @global_data );Apologies for any confusion. Regards, PN5
In Section
Seekers of Perl Wisdom
|
|