Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: ModPerl: ASP

A mod_perl content handler and ASP $Session

 

 

ModPerl asp RSS feed   Index | Next | Previous | View Threaded


Philip_Pereira at e-s-p

Feb 15, 2005, 3:51 AM

Post #1 of 5 (2229 views)
Permalink
A mod_perl content handler and ASP $Session

Hey all,

I am trying to write a mod_perl custom handler for a directory, but need
it to access the Apache::ASP $Session hash pointer - is this possible?

Thanks

Phil.
********************************************************************************Disclaimer: The information contained in this message is for the intended addressee only and may contain confidential and/or privileged information. If you are not the intended addressee, please delete this message and notify the sender; do not copy or distribute this message or disclose its contents to anyone. Any views or opinions expressed in this message are those of the author and do not necessarily represent those of Euro Systems Projects Limited or of any of its associated companies. No reliance may be placed on this message without written confirmation from an authorised representative of the company.


hz at hzlabs

Feb 15, 2005, 5:29 AM

Post #2 of 5 (2078 views)
Permalink
Re: A mod_perl content handler and ASP $Session [In reply to]

Hi Phillip,

> I am trying to write a mod_perl custom handler for a directory, but need
> it to access the Apache::ASP $Session hash pointer - is this possible?

in the handler, you can create an ASP object
and the corresponding Session sub object like

..
$r->dir_config('RequestBinaryRead', 'Off');
my $ASP = Apache::ASP::new('Apache::ASP', $r, $r->filename);
$r->dir_config('RequestBinaryRead', 'On');

my $session = $ASP->Session;
..

[$r = Apache::RequestRec]

I hope, that is what you need..

Helmut


---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe [at] perl
For additional commands, e-mail: asp-help [at] perl


hz at hzlabs

Feb 15, 2005, 6:42 AM

Post #3 of 5 (2067 views)
Permalink
Re: A mod_perl content handler and ASP $Session [In reply to]

Hi Phil,
>
> Your reply sounds perfect! Can you confirm that this will retrieve the
> $Session hash pointer currently being used by the user?

yes the current session, because $r contains the "session information"
(cookie)

> Essentially, I do
> not want to create a new $Session, rather retrieve information from the
> one currently in use.
>

but of course, if the session has expired meanwhile, you will create a new
one,
but to check this you can test for the existence
of a session key after the session "retrievement", that you create before..
(was that clear?)


Helmut


---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe [at] perl
For additional commands, e-mail: asp-help [at] perl


Philip_Pereira at e-s-p

Feb 15, 2005, 7:11 AM

Post #4 of 5 (2051 views)
Permalink
Re: A mod_perl content handler and ASP $Session [In reply to]

Helmut,

Your reply sounds perfect! Can you confirm that this will retrieve the
$Session hash pointer currently being used by the user? Essentially, I do
not want to create a new $Session, rather retrieve information from the
one currently in use.

I hope I have made myself clear - and sorry if I mislead you.

Phil.





Helmut Zeilinger <hz [at] hzlabs>
15/02/2005 13:29

To
Philip_Pereira [at] e-s-p, asp [at] perl
cc

Subject
Re: A mod_perl content handler and ASP $Session






Hi Phillip,

> I am trying to write a mod_perl custom handler for a directory, but need
> it to access the Apache::ASP $Session hash pointer - is this possible?

in the handler, you can create an ASP object
and the corresponding Session sub object like

..
$r->dir_config('RequestBinaryRead', 'Off');
my $ASP = Apache::ASP::new('Apache::ASP', $r, $r->filename);
$r->dir_config('RequestBinaryRead', 'On');

my $session = $ASP->Session;
..

[$r = Apache::RequestRec]

I hope, that is what you need..

Helmut
********************************************************************************Disclaimer: The information contained in this message is for the intended addressee only and may contain confidential and/or privileged information. If you are not the intended addressee, please delete this message and notify the sender; do not copy or distribute this message or disclose its contents to anyone. Any views or opinions expressed in this message are those of the author and do not necessarily represent those of Euro Systems Projects Limited or of any of its associated companies. No reliance may be placed on this message without written confirmation from an authorised representative of the company.


Philip_Pereira at e-s-p

Feb 15, 2005, 7:22 AM

Post #5 of 5 (2023 views)
Permalink
Re: A mod_perl content handler and ASP $Session [In reply to]

Helmut,

That is BRILLIANT!!!!!!

Thanks a lot!

Phil.




Helmut Zeilinger <hz [at] hzlabs>
15/02/2005 14:42

To
Philip_Pereira [at] e-s-p
cc
asp [at] perl
Subject
Re: A mod_perl content handler and ASP $Session






Hi Phil,
>
> Your reply sounds perfect! Can you confirm that this will retrieve the
> $Session hash pointer currently being used by the user?

yes the current session, because $r contains the "session information"
(cookie)

> Essentially, I do
> not want to create a new $Session, rather retrieve information from the
> one currently in use.
>

but of course, if the session has expired meanwhile, you will create a new
one,
but to check this you can test for the existence
of a session key after the session "retrievement", that you create
before..
(was that clear?)


Helmut


---------------------------------------------------------------------
To unsubscribe, e-mail: asp-unsubscribe [at] perl
For additional commands, e-mail: asp-help [at] perl
********************************************************************************Disclaimer: The information contained in this message is for the intended addressee only and may contain confidential and/or privileged information. If you are not the intended addressee, please delete this message and notify the sender; do not copy or distribute this message or disclose its contents to anyone. Any views or opinions expressed in this message are those of the author and do not necessarily represent those of Euro Systems Projects Limited or of any of its associated companies. No reliance may be placed on this message without written confirmation from an authorised representative of the company.

ModPerl asp RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.