开发者

CGI/Perl "use" function

开发者 https://www.devze.com 2023-03-24 22:35 出处:网络
use API; use Database; use Routines; use Encode qw/encode decode/; use CGI; use CGI::Carp; use File::Basename;
use API;
use Database;
use Routines;
use Encode qw/encode decode/;
use CGI;
use CGI::Carp;
use File::Basename;
  1. how can i know where those module come from?
  2. what kind of doc sh开发者_如何学Goould i download to see implementation of those function inside these modules?

Thank you in advance, guys. lol


You can use perldoc -m to see the package's content:

$ perldoc -m CGI
package CGI;
require 5.004;
use Carp 'croak';
...

Or the -l switch to see where the package is:

$ perldoc -l CGI
/System/Library/Perl/5.10.0/CGI.pm

You can also find all the source at CPAN. Just looking at a single file in isolation generally isn't that fruitful, you'll want to look at all the files in the distribution as a coherent whole.

You'll probably want to familiarize yourself with the other things that perldoc can do:

http://perldoc.perl.org/perldoc.html

0

精彩评论

暂无评论...
验证码 换一张
取 消