![]() |
|
laziness, impatience, and hubris | |
PerlMonks |
Re^3: calling perl subroutines in other filesby tachyon (Chancellor) |
on Sep 27, 2004 at 23:24 UTC ( #394398=note: print w/replies, xml ) | Need Help?? |
The typical construction of a perl widget is to put most/all your subroutines in one or more modules. These modules are your 'subroutine files'. You can save them anywhere. In your script you "use lib '/my/modules/are/here'" to tell Perl where to look for your modueles and then use whichever of your modules you want. Typically the subroutines in one module all relate to one sort of thing. For example DBI is a module for database accesss, Digest::MD5 gives you MD5 hashing..... There is plenty of info in the perl docs. See perlman:perlmod perlman:perlmodlib perlman:perlmodinstall perlman:perlnewmod cheers tachyon
In Section
Seekers of Perl Wisdom
|
|