Practical mod_perl / HTML Book /



previous page: 6.3. Namespace Issues
  
page up: HTML Version of the book
  
next page: 6.3.2. The %INC Hash

6.3.1. The @INC Array


Perl's @INC array is like the PATH environment variable for the shell program. Whereas PATH contains a list of directories to search for executable programs, @INC contains a list of directories from which Perl modules and libraries can be loaded.

When you use( ), require( ), or do( ) a filename or a module, Perl gets a list of directories from the @INC variable and searches them for the file it was requested to load. If the file that you want to load is not located in one of the listed directories, you must tell Perl where to find the file. You can either provide a path relative to one of the directories in @INC or provide the absolute path to the file.

 

Continue to:

  • prev: 6.3. Namespace Issues
  • Table of Contents
  • next: 6.3.2. The %INC Hash







TOP
previous page: 6.3. Namespace Issues
  
page up: HTML Version of the book
  
next page: 6.3.2. The %INC Hash


Menu

  • HTML Book
  • PDF Book
  • Download Code
  • Table of Contents
  • Errata
  • mod_perl2 User's Guide
  • Sitemap

Search


Add to Google




Creative Commons License


Written by
Eric Cholet (Logilune) and
Stas Bekman (StasoSphere & Free Books).


[ Privacy Policy | Terms of Use | About Us | Search ]

© 2007 StasoSphere.com