Re: Problem with PerlTransHandler

2011-01-05 Thread Torsten Förtsch
On Wednesday, January 05, 2011 01:09:22 CrAsH-DMX wrote: > If comment my $params = $r->method eq "POST" ? $r->content:$r->args; all > works fine. My mp1 experience is quite a few years old. But I think what you are trying to achieve is not feasible, at least if your handler does not read the mess

Problem with PerlTransHandler

2011-01-04 Thread CrAsH-DMX
uest, apply some process and store again in $r->content or $ r->args to follow their way. To achieve this, I'm trying to write a PerlTransHandler: package Test::test_filter; use strict; use Apache::Constants qw(:common); sub handler { my $r = shift; my $params = $r->method e

Re: PerlTransHandler Redirect (2.0)

2009-03-25 Thread David Stewart
ty of mod_rewrite in a mod_perl 2 PerlTransHandler? I'm writing a PerlTransHandler to overcome some limitation of mod_rewrite and want to redirect requests to canonical URLs in some cases (e.g. replicate the functionality of the [R,L] flags in mod_rewrite). What's the best way to d

Re: PerlTransHandler Redirect (2.0)

2009-03-25 Thread Adam Prime
David Stewart wrote: How do you replicate the redirect functionality of mod_rewrite in a mod_perl 2 PerlTransHandler? I'm writing a PerlTransHandler to overcome some limitation of mod_rewrite and want to redirect requests to canonical URLs in some cases (e.g. replicate the functionali

PerlTransHandler Redirect (2.0)

2009-03-25 Thread David Stewart
How do you replicate the redirect functionality of mod_rewrite in a mod_perl 2 PerlTransHandler? I'm writing a PerlTransHandler to overcome some limitation of mod_rewrite and want to redirect requests to canonical URLs in some cases (e.g. replicate the functionality of the [R,L] fla

Re: DirectoryIndex vs. PerlTransHandler

2007-06-17 Thread Marc M. Adkins
Turns out the solution to my problem was quite simple. I replaced: DataSources Environment with: DataSources Environment and all of my problems resolved. I am no longer using any PerlTransHandler or PerlFixupHandler (as described in other emails), just DirectoryIndex

Re: DirectoryIndex vs. PerlTransHandler

2007-06-13 Thread Marc M. Adkins
ppen I don't get any configuration data item. I have constructed a PerlTransHandler which can be attached to the VirtualHost. In it I do what DirectoryIndex would do, I check for a trailing slash and append index.page. When I do this the subsequent response handler has appropriate configuration dat

Re: DirectoryIndex vs. PerlTransHandler

2007-06-13 Thread Geoffrey Young
in the case where DirectoryIndex makes > this happen I don't get any configuration data item. > > I have constructed a PerlTransHandler which can be attached to the > VirtualHost. In it I do what DirectoryIndex would do, I check for a > trailing slash and append index.page.

DirectoryIndex vs. PerlTransHandler

2007-06-12 Thread Marc M. Adkins
toryIndex makes this happen I don't get any configuration data item. I have constructed a PerlTransHandler which can be attached to the VirtualHost. In it I do what DirectoryIndex would do, I check for a trailing slash and append index.page. When I do this the subsequent response handler has

Re: can PerlTransHandler deal with this?

2006-05-11 Thread Fayland Lam
Frank Maas wrote: I think i'm using the wrong handler, but is there any handler can handle this problem? As far as I can remember mod_rewrite kicks in after a PerlTransHandler. This should enable you to use a TransHandler to rewrite the URI based on the database contents, eg:

RE: can PerlTransHandler deal with this?

2006-05-11 Thread Frank Maas
> I think i'm using the wrong handler, but is there any handler can handle > this problem? As far as I can remember mod_rewrite kicks in after a PerlTransHandler. This should enable you to use a TransHandler to rewrite the URI based on the database contents, eg: http://o.exampl

Re: can PerlTransHandler deal with this?

2006-05-11 Thread John ORourke
like PerlTransHandler +MyApache2::RewriteO Are you trying to redirect the client to http://o1.example.com/1.jpg ? If so you'll have to return a Location: header and a 301 response, eg: $r->err_headers_out('Location'=>'http://o1.example.com/1.jpg'); return Apache2

can PerlTransHandler deal with this?

2006-05-11 Thread Fayland Lam
.gif ... yes, o1,o2,o3 are different servers. I'd like to config the o.example.com like PerlTransHandler +MyApache2::RewriteO but it seems that PerlTransHandler can only rewrite the url of http://o.example.com/1.jpg to http://o.example.com/something is there a way to http://o1.example.com/

Re: PerlTransHandler

2006-04-25 Thread Frank Wiles
On Tue, 25 Apr 2006 13:56:12 -0400 (EDT) Jim Schueler <[EMAIL PROTECTED]> wrote: > What happened to PerlTransHandler in mod_perl-1.29? > > Jim Schueler > Motor City Interactive It didn't go anywhere. By chance are you using a recently installed version where y

PerlTransHandler

2006-04-25 Thread Jim Schueler
What happened to PerlTransHandler in mod_perl-1.29? Jim Schueler Motor City Interactive

Re: MP2 PerlTransHandler and VirtualHosts

2006-02-16 Thread Frank Maas
; > > > So what happens is that if my PerlTransHandler for virtual host > > foo returns declined the My::Foo handler will still run and if > > that one also returns DECLINED then will the apache's default handler > > ah yeah, that's the way it&#x

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-16 Thread Geoffrey Young
Peter, Attila wrote: > I did return DECLINED since I've read the documentation > and it was clear to me that I had to return DECLINED, > however, the handlers seemed to get stacked. > > So what happens is that if my PerlTransHandler for virtual host > foo returns decli

RE: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-16 Thread Peter, Attila
I did return DECLINED since I've read the documentation and it was clear to me that I had to return DECLINED, however, the handlers seemed to get stacked. So what happens is that if my PerlTransHandler for virtual host foo returns declined the My::Foo handler will still run and if that one

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Fred Moyer
PerlTransHandler Apache2::Const::OK I didn't take the time to read the entire thread, but based on the suggestion of using default-handler I figured the goal was something like this PerlTransHandler My::Foo # unset the above trans handler if that's the case then you want

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Geoffrey Young
>> Very odd. Anyone know if 'default-handler' isn't in MP2? > > > I can't say that it isn't, but maybe this will work: > > PerlTransHandler Apache2::Const::OK I didn't take the time to read the entire thread, but based on the suggest

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Fred Moyer
Very odd. Anyone know if 'default-handler' isn't in MP2? I can't say that it isn't, but maybe this will work: PerlTransHandler Apache2::Const::OK Scratch that response, it will keep the TransHandler from running which is not what you want. Use DECLINED per Geoff's response.

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread John ORourke
Wouldn't PerlTransHandler Apache2::Const::DECLINED be better in this case, so it will fall through to the default handler? Fred Moyer wrote: Very odd. Anyone know if 'default-handler' isn't in MP2? I can't say that it isn't, but maybe this will work: P

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Fred Moyer
Frank Wiles wrote: On Wed, 15 Feb 2006 12:46:37 +0100 "Peter, Attila" <[EMAIL PROTECTED]> wrote: -Original Message- From: Peter, Attila Sent: Mittwoch, 15. Februar 2006 12:46 To: 'Frank Wiles' Subject: RE: MP2 PerlTransHandler and VirtualHosts Frank

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Geoffrey Young
for any random phase. it's also an httpd thing, not a mod_perl thing :) to use default translation it would be something like PerlTransHandler My::Handler::That::Returns::DECLINED HTH --Geoff

Re: FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Frank Wiles
On Wed, 15 Feb 2006 12:46:37 +0100 "Peter, Attila" <[EMAIL PROTECTED]> wrote: > -Original Message- > From: Peter, Attila > Sent: Mittwoch, 15. Februar 2006 12:46 > To: 'Frank Wiles' > Subject: RE: MP2 PerlTransHandler and VirtualHosts > > F

FW: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Peter, Attila
-Original Message- From: Peter, Attila Sent: Mittwoch, 15. Februar 2006 12:46 To: 'Frank Wiles' Subject: RE: MP2 PerlTransHandler and VirtualHosts Frank, I tried earlier default-handler with no luck. I got failed to resolve handler `default-handler' in the error lo

RE: MP2 PerlTransHandler and VirtualHosts

2006-02-15 Thread Peter, Attila
Title: MP2 PerlTransHandler and VirtualHosts PerlPostConfigRequire is exactly a require. Note that I specified MyApp/DeviceProxy.pm instead of MyApp::DeviceProxy. The argument of PerlPostConfigRequire must be a filename. That can be an absolut one or just relative to your ServerRoot or @INC

Re: MP2 PerlTransHandler and VirtualHosts

2006-02-14 Thread Foo Ji-Haw
Title: MP2 PerlTransHandler and VirtualHosts I'd like to ask a question in tangent to yours: What happens you load a package via PerlPostConfigRequire? I usually 'require' a script, but if it is possible to execute a package instead, that may be better. - O

Re: MP2 PerlTransHandler and VirtualHosts

2006-02-14 Thread Frank Wiles
On Tue, 14 Feb 2006 23:16:12 +0100 "Peter, Attila" <[EMAIL PROTECTED]> wrote: > Is there any method to restore Apache's default PerlTransHandler > (or in general any other handler) in VirtualServer container after > a PerlTransHandler was set up in the main server co

MP2 PerlTransHandler and VirtualHosts

2006-02-14 Thread Peter, Attila
Title: MP2 PerlTransHandler and VirtualHosts List, Is there any method to restore Apache's default PerlTransHandler (or in general any other handler) in VirtualServer container after a PerlTransHandler was set up in the main server config? Consider the following: PerlLoadM

Rewriting URI in PerlTransHandler depending on keywords in the BODY part

2006-01-21 Thread Bruno Moret
Hello I would like to use mod_perl and PerlTransHandler as a proxy mechanism to route SOAP messages depending on a value located at the very beginning of the XML content. No need to parse the XML content, a simple text search would work just fine. Could some of you help me to define the

Re: Help with PerlTransHandler

2005-05-22 Thread Torsten Foertsch
On Monday 23 May 2005 00:28, Johnny Shz wrote: >     >         JkUriSet worker ajp13:localhost:8009 >     I think, you need a SetHandler inside the . Then mod_rewrite should work as well. Torsten pgpyWHh4aT6xN.pgp Description: PGP signature

Help with PerlTransHandler

2005-05-22 Thread Johnny Shz
ied to use mod_rewrite, the mapping took effect, but then apache tried to find the file: "/bar/servlet/test" rather than applying the to send to mod_jk.   I thought a mod_perl's PerlTransHandler will solve this problem, with a simple:   package Urlmap;use strict;use Apache2::Cons

Re: PerlTransHandler question

2005-03-10 Thread John Doe
large images. What I would like to do is set up an > image cluster, to allow mod_perl to basically only execute code within > the page, release and let another server worry about serving up images. > What I have done so far is altered my PerlTransHandler with the code > below >

Re: PerlTransHandler question

2005-03-09 Thread Perrin Harkins
shawn wrote: I am aware that I could just change the links to the pdfs but that is allot of code changes and may cause problems with the image upload code etc. Or you could use a proxy server. Another reason why I would like the mod_perl server to be the front end is because it has ssl enabled and

RE: PerlTransHandler question

2005-03-09 Thread David J Radunz
nything other than just .htm files :) > Another reason why I would like the mod_perl server to be the front end > is because it has ssl enabled and there will be problems with the cert > across different server. > > > Any thoughts? > > > Shawn > > > > ---

RE: PerlTransHandler question

2005-03-09 Thread shawn
enabled and there will be problems with the cert across different server. Any thoughts? Shawn -Original Message- From: Tony Clayton [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 08, 2005 8:15 PM To: modperl@perl.apache.org Subject: Re: PerlTransHandler question Quoting shawn <[EM

Re: PerlTransHandler question

2005-03-09 Thread Tony Clayton
Quoting shawn <[EMAIL PROTECTED]>: So far this working on my development environment, but what I am really wondering about is if this will actually take the load off mod_perl? (it's a little hard for me to tell without significant traffic) Will the mod_perl server execute the page and release the

Re: PerlTransHandler question

2005-03-08 Thread Perrin Harkins
shawn wrote: What I would like to do is set up an image cluster, to allow mod_perl to basically only execute code within the page, release and let another server worry about serving up images. There is extensive documentation on this here: http://perl.apache.org/docs/1.0/guide/strategy.html Your

RE: PerlTransHandler question

2005-03-08 Thread Shawn
: PerlTransHandler question On Tue, 8 Mar 2005 17:19:29 -0700, shawn <[EMAIL PROTECTED]> wrote: > Hi, I have been having a few problems with dial-up users downloading large > pictures from my mod_perl enabled webserver, also I see spikes in cpu usage > which also suggests to me that the server is

PerlTransHandler question

2005-03-08 Thread shawn
cluster, to allow mod_perl to basically only execute code within the page, release and let another server worry about serving up images. What I have done so far is altered my PerlTransHandler with the code below       if($host ne 'dev.webserver.com' && $host ne &#x

Re: mp2: PerlTransHandler/proxying with question mark in URL

2004-10-30 Thread Stas Bekman
Eric Lenio wrote: In my apache config file I'm using a PerlTransHandler call to do URL rewriting. Basically I want to map all URL's beginning with http://testhost.lenio.net to internally to go to: http://localhost:8080 This works perfectly except when I introduce a URL with a que

mp2: PerlTransHandler/proxying with question mark in URL

2004-10-30 Thread Eric Lenio
In my apache config file I'm using a PerlTransHandler call to do URL rewriting. Basically I want to map all URL's beginning with http://testhost.lenio.net to internally to go to: http://localhost:8080 This works perfectly except when I introduce a URL with a question mark

Re: PerlTransHandler, Location

2004-09-08 Thread Stas Bekman
Geoffrey Young wrote: eps com estem wrote: You were right, my firsts tests indicate that things are going well (i have to work more on it) with internal_redirect(). Simply i did not know the existence of these wonderful functions (methods). might I suggest, then, some of the mod_perl books listed

Re: PerlTransHandler, Location

2004-09-08 Thread Geoffrey Young
eps com estem wrote: > You were right, my firsts tests indicate that things are going well (i have to work > more > on it) with internal_redirect(). Simply i did not know the existence of these > wonderful > functions (methods). might I suggest, then, some of the mod_perl books listed on the p

Re: Re: PerlTransHandler, Location

2004-09-08 Thread eps com estem
help and this solution. Thanks a lot :D >eps com estem wrote: >> Hi. >> I want to redirect to some uri one page. This can be accomplished easily in >> PerlTransHandler with $r-> uri($new_uri); >> My problem is that this uri needs to be parsed again with the same mod

Re: PerlTransHandler, Location

2004-09-08 Thread Geoffrey Young
eps com estem wrote: > Hi. > I want to redirect to some uri one page. This can be accomplished easily in > PerlTransHandler with $r-> uri($new_uri); > My problem is that this uri needs to be parsed again with the same module > responsible of > that. This is, i have a web p

PerlTransHandler, Location

2004-09-08 Thread eps com estem
Hi. I want to redirect to some uri one page. This can be accomplished easily in PerlTransHandler with $r-> uri($new_uri); My problem is that this uri needs to be parsed again with the same module responsible of that. This is, i have a web page parse by module X that has to redirect to anot

Re: cookie info during perltranshandler

2004-07-26 Thread Stas Bekman
john z wrote: is it possible to access cookie and other request state info during perltranshandler phase. also, how do i find what methods and objects are available for transhandler. i tried to use lookupmethod and did not come up with a list. (i did search faq and docs but did not spot much) I

cookie info during perltranshandler

2004-07-26 Thread john z
is it possible to access cookie and other request state info during perltranshandler phase. also, how do i find what methods and objects are available for transhandler. i tried to use lookupmethod and did not come up with a list. (i did search faq and docs but did not spot much) --- Outgoing

Re: Cannot fetch cookie in PerlTranshandler?

2004-06-25 Thread Au Yeong Wing Yau
do > redirection, so I implemented one using PerlTranshandler. When I tested > it on a Linux box for prototyping, the following works well: > > sub handler > { > ... > my $q = new CGI; > my $id = $q->cookie(-name=>"myCookie"); > ... >

Cannot fetch cookie in PerlTranshandler?

2004-06-24 Thread Au Yeong Wing Yau
I need a customized session/cookie management system that can do redirection, so I implemented one using PerlTranshandler. When I tested it on a Linux box for prototyping, the following works well: sub handler { ... my $q = new CGI; my $id = $q->cookie(-name=>&qu

Re: PerlTransHandler and 302 'Object Moved' response from web server

2004-05-05 Thread Perrin Harkins
On Wed, 2004-05-05 at 06:12, [EMAIL PROTECTED] wrote: > On some pages, the website sends a 302 'Object Moved' response and instead > of returning the 302 response to the web browser, Apache/my handler tries to > GET the new Location by itself, without setting the website's cookie. So, > the website

PerlTransHandler and 302 'Object Moved' response from web server

2004-05-05 Thread mathieu . millet
Hi everyone, I have searched through the archive but I haven't a solution to my problem. I'm using a PerlTransHandler module to reverse proxy a website. The website itself sets a cookie for tracking its 'own' session and my module handles it without trouble (well

PerlTransHandler for session id?

2004-02-15 Thread Chris Ochs
about writing a PerlTransHandler that manages the sessions and takes care of it automatically. My only concern was that the only way I see to add a query string to the url is by using a redirect, and I'm not really sure how much of an overhead that adds in terms of how much extra time it take

Re: PerlTransHandler, PerlHanlder and document_root

2003-10-19 Thread Geoffrey Young
simran wrote: Further to my previous email (as below), i have noticed that if i set the document_root to something that does not exist (eg. "/blahblah") - then in the PerlCleanupHandler, the document root (before reset) is set to "/blahblah" - if i had set it to something that existed, then was i

RE: PerlTransHandler, PerlHanlder and document_root

2003-10-19 Thread simran
Further to my previous email (as below), i have noticed that if i set the document_root to something that does not exist (eg. "/blahblah") - then in the PerlCleanupHandler, the document root (before reset) is set to "/blahblah" - if i had set it to something that existed, then was i set it to is n

RE: PerlTransHandler, PerlHanlder and document_root

2003-10-19 Thread simran
Thanks Frank, On Fri, 2003-10-17 at 22:12, Frank Maas wrote: > >> Can it be that a subrequest (issued (by chance?) to the same child) > >> is messing things up? You might try adding a warn to the > >> CleanupHandler. > > > > I guess it could be... what should i be logging for in the > > CleanupH

RE: PerlTransHandler, PerlHanlder and document_root

2003-10-17 Thread Frank Maas
> Hi Frank, [...] >> Can it be that a subrequest (issued (by chance?) to the same child) >> is messing things up? You might try adding a warn to the >> CleanupHandler. > > I guess it could be... what should i be logging for in the > CleanupHandler? (aka, what should i print to see if its a subrequ

RE: PerlTransHandler, PerlHanlder and document_root

2003-10-17 Thread simran
Hi Frank, On Fri, 2003-10-17 at 18:21, Frank Maas wrote: > Simran, > > Just trying: > > GH> however, any changes made to $r->document_root > GH> would persist for the entire life of the child, not just the life of > GH> the current request. for that reason, you were expected to always > GH> res

RE: PerlTransHandler, PerlHanlder and document_root

2003-10-17 Thread Frank Maas
Simran, Just trying: GH> however, any changes made to $r->document_root GH> would persist for the entire life of the child, not just the life of GH> the current request. for that reason, you were expected to always GH> restore the value of $r->document_root to its original state. GH> GH> see re

Re: PerlTransHandler, PerlHanlder and document_root

2003-10-16 Thread simran
On Fri, 2003-10-17 at 13:07, Geoffrey Young wrote: > simran wrote: > > Hi All, > > > > I have a PerlTransHandler where i am doing something to the effect of: > > > > my $request = instance Apache::Request(shift); > > $request->document_ro

Re: PerlTransHandler, PerlHanlder and document_root

2003-10-16 Thread Geoffrey Young
simran wrote: Hi All, I have a PerlTransHandler where i am doing something to the effect of: my $request = instance Apache::Request(shift); $request->document_root("/home/testuser/www"); $request->pnotes("test_key" => "test_value"); wa

PerlTransHandler, PerlHanlder and document_root

2003-10-16 Thread simran
Hi All, I have a PerlTransHandler where i am doing something to the effect of: my $request = instance Apache::Request(shift); $request->document_root("/home/testuser/www"); $request->pnotes("test_key" => "test_value"); warn "Set d

Re: PerlTransHandler "failed to resolve"

2003-10-06 Thread Stas Bekman
gerard uolaquetalestem wrote: Hi again I'm just trying to translate URI with a modperl2 module, and i've got it in windows os. Then i wanted to install to my linux os but life is not as easy as this. I have problems with that module, and i've tried the following things: First of all i comment mos

Re: PerlTransHandler "failed to resolve"

2003-10-05 Thread Geoffrey Young
And then i put the PerlTransHandler +module in the VirtualHost section Then i get an INTERNAL ERROR SERVER, with the sentence "failed to resolve handler modulename" in error.log that typically means that the module couldn't be found. try putting it in /usr/local/apache2/ or /us

PerlTransHandler question addition

2003-10-05 Thread gerard uolaquetalestem
The entire module works fine (as i see now) if i put the PerlTransHandler directive outside the VirtualHost, and goes badly if i put inside the VirtualHost section. What can i do if i want this module to act only at certain VirtualHost??? - Un nuevo buscador más rápido, eficaz y sencillo

PerlTransHandler "failed to resolve"

2003-10-05 Thread gerard uolaquetalestem
le, actually it is only: package modulename; use Apache::RequestRec(); use Apache::Const -compile => qw(DECLINED); sub handler { return DECLINED; } 1; And then i put the PerlTransHandler +module in the VirtualHost section Then i get an INTERNAL ERROR SERVER, with the sentence

RE: perltranshandler stage?

2003-09-28 Thread Frank Maas
m the server. Left click means that it is rendered and shown in the browser, right click means that it is saved as is. > I need different action during my perltranshandler stage depending > does the user left click or right click. Perhaps you could do something with Javascript and specif

perltranshandler stage?

2003-09-28 Thread Scott Alexander
Hi, Is it possible to know has a user just clicked on a link or right clicked and selected "Save link target as" ? I've looked at $r->as_string for NN, IE etc. I need different action during my perltranshandler stage depending does the user left click or right click. Scott