POST fields are now hidden (#80)

This commit is contained in:
Clément Oudot 2010-06-01 09:59:37 +00:00
parent 6c1dc91ff0
commit bb9c7435cc
2 changed files with 32 additions and 3 deletions

View File

@ -108,6 +108,7 @@ use constant {
PM_SAML_IDPCHOOSEN => 9, PM_SAML_IDPCHOOSEN => 9,
PM_REMEMBERCHOICE => 10, PM_REMEMBERCHOICE => 10,
PM_SAML_SPLOGOUT => 11, PM_SAML_SPLOGOUT => 11,
PM_REDIRECTION => 12,
}; };
# EXPORTER PARAMETERS # EXPORTER PARAMETERS
@ -126,6 +127,7 @@ our @EXPORT = qw( PE_IMG_NOK PE_IMG_OK PE_INFO PE_REDIRECT PE_DONE PE_OK
PM_USER PM_DATE PM_IP PM_SESSIONS_DELETED PM_OTHER_SESSIONS PM_USER PM_DATE PM_IP PM_SESSIONS_DELETED PM_OTHER_SESSIONS
PM_REMOVE_OTHER_SESSIONS PM_PP_GRACE PM_PP_EXP_WARNING PM_REMOVE_OTHER_SESSIONS PM_PP_GRACE PM_PP_EXP_WARNING
PM_SAML_IDPSELECT PM_SAML_IDPCHOOSEN PM_REMEMBERCHOICE PM_SAML_SPLOGOUT PM_SAML_IDPSELECT PM_SAML_IDPCHOOSEN PM_REMEMBERCHOICE PM_SAML_SPLOGOUT
PM_REDIRECTION
); );
our %EXPORT_TAGS = ( 'all' => [ @EXPORT, 'import' ], ); our %EXPORT_TAGS = ( 'all' => [ @EXPORT, 'import' ], );
@ -1597,9 +1599,33 @@ sub autoPost {
# Return error if no URL # Return error if no URL
return PE_ERROR unless $self->{postUrl}; return PE_ERROR unless $self->{postUrl};
# Simple CSS
my $css = "
body {
background: #ddd;
color: #fff;
}
h1 {
size: 10pt;
text-align: center;
letter-spacing: 5px;
margin-top: 100px;
}
form {
display: none;
}
";
# Print page # Print page
print $self->header(); print $self->header();
print $self->start_html(); print $self->start_html( -style => { -code => $css } );
print $self->h1(
&Lemonldap::NG::Portal::_i18n::msg( PM_REDIRECTION,
$ENV{HTTP_ACCEPT_LANGUAGE}
)
);
print $self->start_form( -action => $url ); print $self->start_form( -action => $url );
$self->lmLog( "POST form action: $url", 'debug' ); $self->lmLog( "POST form action: $url", 'debug' );

View File

@ -294,6 +294,7 @@ sub error_ro {
# * PM_SAML_IDPCHOOSEN 9 # * PM_SAML_IDPCHOOSEN 9
# * PM_REMEMBERCHOICE 10 # * PM_REMEMBERCHOICE 10
# * PM_SAML_SPLOGOUT 11 # * PM_SAML_SPLOGOUT 11
# * PM_REDIRECTION 12
sub msg_en { sub msg_en {
use utf8; use utf8;
@ -309,7 +310,8 @@ sub msg_en {
'Select your Identity Provider', 'Select your Identity Provider',
'Redirection to your Identity Provider', 'Redirection to your Identity Provider',
'Remember my choice', 'Remember my choice',
'Logout from service providers...' 'Logout from service providers...',
'Redirection in progress...',
]; ];
} }
@ -327,7 +329,8 @@ sub msg_fr {
'Choisissez votre fournisseur d\'identité', 'Choisissez votre fournisseur d\'identité',
'Redirection vers votre fournisseur d\'identité', 'Redirection vers votre fournisseur d\'identité',
'Se souvenir de mon choix', 'Se souvenir de mon choix',
'Déconnexion des services...' 'Déconnexion des services...',
'Redirection en cours...',
]; ];
} }