El 26/03/2010 8:46, Octavian Rasnita escribió:
    And in a test action I have done:
    my $body;
    $body .= "HTTPS environment variable: $ENV{HTTPS}<br />\n";
    $body .= "HTTPS header: " . $c->req->header('HTTPS') . "<br />\n";
    $body .= "secure: " . $c->req->secure . "<br />\n";;
    $c->req->secure(1); #Force it to be true
    $body .= "secure: " . $c->req->secure . "<br />\n"; # Check if it is
    set correctly
    $body .= "uri_for_action: " . $c->uri_for_action('/user/login2') .
    "<br />\n";
    $c->res->body($body);

    And the result is:
    HTTPS environment variable: On
    HTTPS header: On
    secure: 0
    secure: 1
    uri_for_action: http://site.testsite.com:5555/en/user/login2

Try with

if (lc($c->req->headers()->{'x-https'}) eq 'on'){
     my $uri = $c->req->base();
     $uri->scheme("https");
     $c->req->base($uri);
}

Note: I set X-Https header on the apache with

RequestHeader set X-Https               "%{HTTPS}e"

works for me...

Jose Luis Martinez
[email protected]

_______________________________________________
List: [email protected]
Listinfo: http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst
Searchable archive: http://www.mail-archive.com/[email protected]/
Dev site: http://dev.catalyst.perl.org/

Reply via email to