Practical mod_perl / HTML Book /



previous page: 6.3.3.4. A first solution
  
page up: HTML Version of the book
  
next page: 6.3.3.6. A third solution

6.3.3.5. A second solution


Another approach is to use a full path to the script, so the latter will be used as a key in %INC:

require "/home/httpd/perl/project/MyConfig.pm";

With this solution, we solve both problems but lose some portability. Every time a project moves in the filesystem, the path must be adjusted. This makes it impossible to use such code under version control in multiple-developer environments, since each developer might want to place the code in a different absolute directory.

 

Continue to:

  • prev: 6.3.3.4. A first solution
  • Table of Contents
  • next: 6.3.3.6. A third solution







TOP
previous page: 6.3.3.4. A first solution
  
page up: HTML Version of the book
  
next page: 6.3.3.6. A third solution


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