in reply to Using eval to create 'plugins'
Well, I'm not going to say that this a Good Idea, but if you go with this sort of architecture, you ought to look into using do rather than eval.
Note, with do, lexicals can't be seen by the included code so you need to do something like:
use CGI; use vars qw/ $cgi /; $cgi = new CGI; do 'junior-webmaster-code.pl';
Hmm. With perl 5.6, I think you could use our here (can anyone confirm or deny? Thanks.)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Using eval to create 'plugins'
by Dominus (Parson) on Jan 09, 2001 at 19:05 UTC |