perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Samuel Gómez <samuelgomezcre...@gmail.com>
Subject Usage: APR::URI::parse(classname, p_sv, uri)
Date Mon, 19 Nov 2012 20:09:32 GMT
Hi,

In a mod_perl handler I am writing I wrote
my $parsed_uri = APR::URI->parse($r->pool, $uri);
as stated by
http://perl.apache.org/docs/2.0/api/APR/URI.html#C_parse_
but on execution it gave me this error:
"Usage: APR::URI::parse(classname, p_sv, uri)"

So I have three questions.

1. I think there is an error regarding the APR::URI->parse method either in
the mod_perl documentation, or in mod_perl itself.

2. If mod_perl is right, what is a classname? Please provide an example.

3. Actually I was using that line to get the hostname of the request. I
replaced it by
my $uri_hostname = $r->hostname;
and it is apparently working. I'm I doing it right?

Thank you!

Mime
View raw message