hello,
I'm working with an older mod_perl system. I would like to bring up another virtual host using modified code. The package and routine names will be the same across the two virtual hosts. There are also some global variables floating around in the code (on both sites) as well.
Here's what I have in the http.conf:
RewriteRule ^/Something(.*) /path/to/the/main/code.pl
<Directory /path/to/the/main/>
SetHandler perl-script
PerlHandler Apache::Registry
Options ExecCGI
PerlRequire /path/to/the/main/startup.pl
in the startup.pl I have added:
$Apache::Registry::NameWithVirtualHost = 1;
It looks like not all of the requests are getting prefixed with the virtual
host name. I'm having a hard time debugging this but when I force an
error (stack trace) I see that some things are listed with the virtual
host:
Apache::ROOThost_2ename_2ecom::My::Package::_31_2e0::method::handler
yet others are not:
My::OtherPackage::MyMethod
I can take off all of the virtual hosts from the module names by turning this off:
$Apache::Registry::NameWithVirtualHost = 0;
Any help with this would be great.
thanks.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.