There's more than one way to do things | |
PerlMonks |
Re: defaultpage of websiteby wolfi (Scribe) |
on Mar 16, 2004 at 06:05 UTC ( [id://336941]=note: print w/replies, xml ) | Need Help?? |
i confess, i've never used LWP... but i do work around webdev and i can't figure out, what you're trying to do. lemme explain... unless of course, you're trying to hack it (in which case, i won't be answering that Q). B) regarding default pages - this is done in configuration files on the server. The administrator can put whatever they wish as the default. And if the site is dynamically generated (via a script - like perl), uses frames, redirection, etc... as anonymous monk above me said, it's quite possible the visitor may not know. (And if you're trying to get into someone's config file, ya might wanna have an attorney on retainer.) you could always glance at the html's source code... that might give an indication - but that isn't guaranteed, since the server can redirect someone at its whim. You can ask for page X and the server might decide to give you page Y. It's the server's choice - it's THEIR files. C) To try to get this back to perl, however... Assuming you're not nefarious and are running a server yourself - trying to get info from your visitors, there's a very easy way to do this -> Just use environmental variables.
i'm not gonna list all the possible @ENV out there, but any html/cgi book should have'em listed. (We'll plug the CGI Programming with Perl by O'Reilly) Do note, however, that these variables are dependent upon the visitor's platform (browser, etc) and its configuration. One can't rely on this info completely, but it isn't bad for broad-based statisical info.
In Section
Seekers of Perl Wisdom
|
|