From: Alex D. <al...@dr...> - 2004-11-21 09:34:55
|
Thanks. I'll try it first thing Monday morning. Which reminds me. I've been thinking about setting up a development environment on my iBook G3 (my Darwin came with Apache 1.3.29 and perl 5.6.0) Is there anything I should know about, prior to installing all the required modules and fighting with httpd.conf a lot? :) I'm especially worried about updating (or installing, i haven't checked it) libxml2 and libxsl2 (on RedHat it was easy, you just updated with rpm). Any other required modules that might have issues running on a Mac with MacOS 10.2.8? Thanks anyone for any advice. On Friday, November 19, 2004, at 07:39 PM, Boris Zentner wrote: > > Hi Alex, > > Am Freitag, 19. November 2004 15:40 schrieb Alex Deva: >> The env var seems to not be set all the time. This might be because >> I'm >> reaching the page via http redirect, and you never know (or do you?) >> >> Boris, the correctly spelled method is "header_in" and it works like >> so: >> >> my $referer = $apr->header_in('Referer'); >> > > This works only with apache1. > > apache2 and apache1 should support > my $href = $apr->headers_in; > > here is a example: > > Maybe you did not see the header, since the client must not send the > referer > header. > > #### Modelcode ###### > > # show all headers > > sub alex { > my $model = shift; > my $href = $model->apr->headers_in; > $model->output( > headers => [ map { +{ name => $_, value => $href->{$_} } } sort > keys > %$href > ] ); > } > > > ######### alex.tmpl ######### > <html> > <body> > <model_loop headers> > <model_var name> <model_var value><br> > </model_loop> > </body> > </html> > > > ####### output ( ignore ) ########### > > Accept */* > Accept-Encoding gzip, deflate;q=1.0, identity;q=0.5, *;q=0 > Accept-Language de-de, ja;q=0.77, en;q=0.92, nl-nl;q=0.88, nl;q=0.85, > ja-jp;q=0.81, de;q=0.96, fr;q=0.73, es;q=0.69, it-it;q=0.65, it;q=0.62, > sv-se;q=0.58, sv;q=0.54, no-no;q=0.50, no;q=0.46, da-dk;q=0.42, > da;q=0.38, > fi-fi;q=0.35, fi;q=0.31 > Connection keep-alive > Cookie pkit_session_id=fdb814523909709a3a697ee14fbcc1a0 > Host localhost:8529 > User-Agent Mozilla/5.0 (Macintosh; U; PPC Mac OS X; de-de) > AppleWebKit/125.5.5 > (KHTML, like Gecko) Safari/125.11 > >> (I've just found that out, I didn't know about it, thank you!) >> >> but... still no result. >> >> Thanks anyway. >> >> >> ----- Original Message ----- >> From: <sh...@ru...> >> To: "Alex Deva" <al...@dr...> >> Cc: "Boris Zentner" <bz...@2b...>; "PageKit Users" >> <pag...@li...> >> Sent: Friday, November 19, 2004 4:33 PM >> Subject: Re: [Pagekit-users] referral field in the http request >> >>> If you mean the HTTP referer information, you can get that out of the >>> runtime environment: >>> >>> $ENV{'HTTP_REFERER'} >>> >>> A google search randomly turned up this page, which has a useful >>> list and >> >> is >> >>> running under mod_perl: >>> >>> http://www.cis.ksu.edu/~aruljohn/cgi-bin/env.cgi >>> >>> If that page stops working try another search for "mod_perl >>> environment >>> variable list". >>> >>> Good luck! >>> >>> shimon. >>> >>> On Fri, Nov 19, 2004 at 04:09:05PM +0200, Alex Deva wrote: >>>> Hi, >>>> >>>> Can I access the 'referral' field, or indeed the HTTP request >>>> header at >> >> all? >> >>>> There seems to be no method for that (or at least one that would >>>> return >> >> a >> >>>> CGI object, or something) >>>> >>>> Thanks! >>>> >>>> >>>> >>>> ------------------------------------------------------- >>>> This SF.Net email is sponsored by: InterSystems CACHE >>>> FREE OODBMS DOWNLOAD - A multidimensional database that combines >>>> robust object and relational technologies, making it a perfect match >>>> for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8 >>>> _______________________________________________ >>>> Pagekit-users mailing list >>>> Pag...@li... >>>> https://lists.sourceforge.net/lists/listinfo/pagekit-users >>> >>> ------------------------------------------------------- >>> This SF.Net email is sponsored by: InterSystems CACHE >>> FREE OODBMS DOWNLOAD - A multidimensional database that combines >>> robust object and relational technologies, making it a perfect match >>> for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8 >>> _______________________________________________ >>> Pagekit-users mailing list >>> Pag...@li... >>> https://lists.sourceforge.net/lists/listinfo/pagekit-users >> >> ------------------------------------------------------- >> This SF.Net email is sponsored by: InterSystems CACHE >> FREE OODBMS DOWNLOAD - A multidimensional database that combines >> robust object and relational technologies, making it a perfect match >> for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8 >> _______________________________________________ >> Pagekit-users mailing list >> Pag...@li... >> https://lists.sourceforge.net/lists/listinfo/pagekit-users > > -- > Boris > > > ------------------------------------------------------- > This SF.Net email is sponsored by: InterSystems CACHE > FREE OODBMS DOWNLOAD - A multidimensional database that combines > robust object and relational technologies, making it a perfect match > for Java, C++,COM, XML, ODBC and JDBC. www.intersystems.com/match8 > _______________________________________________ > Pagekit-users mailing list > Pag...@li... > https://lists.sourceforge.net/lists/listinfo/pagekit-users |