in reply to Re: Stupid newbie question - perl/cgi
in thread perl/cgi question: script works from unix command line, but not web page

This is a stunning amount of work just to help out a newbie.

Thanks! Of course I still don't understand half of what you have in here (grin). This is cool though, most of the examples I've found on the web so far are either too simple to be very useful, or insufficiently explained/commented and I can't tell what they are supposed to do.

What does this (use IO::File) do? It looks like you are instantiating an object, but I can't find a reference for the 'use' command. I've been using this language reference.

Any suggestions for a better online reference?

  • Comment on Re: Re: Stupid newbie question - perl/cgi

Replies are listed 'Best First'.
Re: Re: Re: Stupid newbie question - perl/cgi
by Zaxo (Archbishop) on Apr 03, 2002 at 04:25 UTC

    The perlfunc section of docs in your development environment is probably most convenient. In ActiveState those are distributed in a winhelp format and accessable through the AS start menu. On unix just type 'perldoc -f use'. use is like #include in C, but with specific behavior at compile time, and with regard to multiple inclusion.

    1. perldoc perlfunc
    2. perldoc perlsyn
    3. perldoc perlop
    4. perldoc IO::File

    After Compline,
    Zaxo

Re: Re: Re: Stupid newbie question - perl/cgi
by mla (Beadle) on Apr 03, 2002 at 04:26 UTC
    The reference you're using is for Perl 4, so it's obsolete. Take a look at www.perldoc.org.

    I'd suggest you install Perl locally if you haven't already. It comes with a wealth of documentation that is very easy to use. For example, if you want to find out what use does you can simply run perldoc -f use.

    The use IO::File just loads the IO::File module. And then, yes, I'm instantiating it. I just wanted to show you that there's an OO interface available for file operations. And again, if you have Perl installed, you should be able to just type perldoc IO::File to read about it.