Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] [N00B] [ANS] [REC] [DOC] [HTH] [YABBA] [DABBA] [DOO] [PTHFBST] mod_perl2 Apache2::::Connection get_remote_host
- Date: Thu, 09 Aug 2007 20:35:07 +0900
- From: dave@example.com
- Subject: Re: [tlug] [N00B] [ANS] [REC] [DOC] [HTH] [YABBA] [DABBA] [DOO] [PTHFBST] mod_perl2 Apache2::::Connection get_remote_host
- References: <46BAD28E.8060007@cnt.mxt.nes.nec.co.jp>
- User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.91 (gnu/linux)
Nguyen Vu Hung <vu-hung@example.com> writes: > I wanted to get the remote host with the code: > > use Apache2::Connection (); > use Apache2::RequestRec (); > my $c = $r->connection; > [Thu Aug 09 17:06:57 2007] [error] Global symbol "$r" requires explicit > package name > I don't know why because arcording to Apache2::Connection API page, my > code *should* work. Not really. What you've taken from that page is a brief synopsis of how that particular module is used - not a complete script example. It assumes you've already set up $r pointing to the Apache request object, perhaps using something like this: ... sub handler { my $r = shift; ... For mod_perl basics, this doc would be a good place to start: http://perl.apache.org/docs/2.0/user/intro/start_fast.html possibly followed by this one: http://perl.apache.org/docs/2.0/user/coding/coding.html I'd also recommend trying the mod_perl mailing list when you get stuck. People there are generally very helpful toward users of all levels. http://perl.apache.org/maillist/modperl.html HTH, //Dave
- References:
- [tlug] [N00B] mod_perl2 Apache2::::Connection get_remote_host
- From: Nguyen Vu Hung
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] [IME] :P Which IME does everyone use?
- Next by Date: Re: [tlug] Getting Started with Programming
- Previous by thread: [tlug] [N00B] mod_perl2 Apache2::::Connection get_remote_host
- Next by thread: [tlug] Re: [IME] :P Which IME does everyone use?
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links