This site has been archived and you can no longer log in or post new messages. For up-to-date community resources please visit ezplatform.com

eZ Community » Forums » Suggestions » eZSESSID in...
expandshrink

eZSESSID in ezhttptool::sendHTTPRequest()

eZSESSID in ezhttptool::sendHTTPRequest()

Sunday 04 November 2007 4:12:19 pm - 1 reply

Is it possible to support eZSESSID in ezhttptool::sendHTTPRequest?

Can we add another parameter to sendHTTPRequest() as the following?

function sendHTTPRequest($uri,$port,$postParameters, $userAgent, $passthrough, $ezsessionid)

And change the request header as the following?

...
"Cookie : eZSESSID=$ezsessionid".
...

In this way, we can do internal forward with authenticated session on server side.

Or maybe we can add an array parameter named "$cookies" to allow the user to supply additional cookies when invoking sendHTTPRequest() as the following?

function sendHTTPRequest($uri,$port,$postParameters, $userAgent, $passthrough, $cookies)

Please advise.

Modified on Sunday 04 November 2007 4:31:46 pm by Michael Lee

Sunday 04 November 2007 9:55:13 pm

Hi

This is a hack, but if you can add custom HTTP headers using the <i>$userAgent</i> parameter. Example:

$userAgent = 'eZ Publish ' . "\r\n" .
                   'Cookie: ' . $mySessionVar;
eZHTTPTool::sendHTTPRequest( 'http://ez.no', 80, false, $userAgent );

Best regards
Kåre

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from