fix [ 1249114 ] unclosed <li> elements in auth modules

This commit is contained in:
Martin Kamerbeek 2005-08-12 13:22:54 +00:00
parent fea1002aca
commit 52670adb9f
9 changed files with 30 additions and 28 deletions

View file

@ -64,7 +64,7 @@ sub _isDuplicateUsername {
return 0 if($self->userId ne "1" && $session{user}{username} eq $username);
my ($otherUser) = WebGUI::SQL->quickArray("select count(*) from users where username=".quote($username));
return 0 if !$otherUser;
$self->error('<li>'.WebGUI::International::get(77).' "'.$username.'too", "'.$username.'2", '.'"'.$username.'_'.WebGUI::DateTime::epochToHuman(time(),"%y").'"');
$self->error('<li>'.WebGUI::International::get(77).' "'.$username.'too", "'.$username.'2", '.'"'.$username.'_'.WebGUI::DateTime::epochToHuman(time(),"%y").'"'.'</li>');
return 1;
}
@ -84,13 +84,13 @@ sub _isValidUsername {
return 1 if($self->userId ne "1" && $session{user}{username} eq $username);
if ($username =~ /^\s/ || $username =~ /\s$/) {
$error .= '<li>'.WebGUI::International::get(724);
$error .= '<li>'.WebGUI::International::get(724).'</li>';
}
if ($username eq "") {
$error .= '<li>'.WebGUI::International::get(725);
$error .= '<li>'.WebGUI::International::get(725).'</li>';
}
unless ($username =~ /^[A-Za-z0-9\-\_\.\,\@]+$/) {
$error .= '<li>'.WebGUI::International::get(747);
$error .= '<li>'.WebGUI::International::get(747).'</li>';
}
$self->error($error);
return $error eq "";

View file

@ -59,15 +59,15 @@ sub _isValidLDAPUser {
$ldap = Net::LDAP->new($uri->host, (port=>$uri->port)) or $error .= WebGUI::International::get(2,'AuthLDAP');
$auth = $ldap->bind(dn=>$connectDN, password=>$session{form}{'authLDAP_identifier'});
if ($auth->code == 48 || $auth->code == 49) {
$error .= '<li>'.WebGUI::International::get(68);
$error .= '<li>'.WebGUI::International::get(68).'</li>';
WebGUI::ErrorHandler::warn("Invalid LDAP information for registration of LDAP ID: ".$session{form}{'authLDAP_ldapId'});
} elsif ($auth->code > 0) {
$error .= '<li>LDAP error "'.$ldapStatusCode{$auth->code}.'" occured. '.WebGUI::International::get(69);
$error .= '<li>LDAP error "'.$ldapStatusCode{$auth->code}.'" occured. '.WebGUI::International::get(69).'</li>';
WebGUI::ErrorHandler::error("LDAP error: ".$ldapStatusCode{$auth->code});
}
$ldap->unbind;
} else {
$error .= '<li>'.WebGUI::International::get(68);
$error .= '<li>'.WebGUI::International::get(68).'</li>';
WebGUI::ErrorHandler::warn("Invalid LDAP information for registration of LDAP ID: ".$session{form}{'authLDAP_ldapId'});
}
} else {
@ -275,7 +275,7 @@ sub createAccountSave {
#If Email address is not unique, a warning is displayed
if($warning ne "" && !$session{form}{confirm}){
$session{form}{confirm} = 1;
return $self->createAccount('<li>'.WebGUI::International::get(1078));
return $self->createAccount('<li>'.WebGUI::International::get(1078).'</li>');
}
my $properties;

View file

@ -44,14 +44,14 @@ sub _isValidPassword {
my $error = "";
if ($password ne $confirm) {
$error .= '<li>'.WebGUI::International::get(3,'AuthWebGUI');
$error .= '<li>'.WebGUI::International::get(3,'AuthWebGUI').'</li>';
}
if ($password eq "") {
$error .= '<li>'.WebGUI::International::get(4,'AuthWebGUI');
$error .= '<li>'.WebGUI::International::get(4,'AuthWebGUI').'</li>';
}
if ($self->getSetting("passwordLength") && length($password) < $self->getSetting("passwordLength")){
$error .= '<li>'.WebGUI::International::get(7,'AuthWebGUI')." ".$self->getSetting("passwordLength");
$error .= '<li>'.WebGUI::International::get(7,'AuthWebGUI')." ".$self->getSetting("passwordLength").'</li>';
}
$self->error($error);
@ -209,7 +209,7 @@ sub createAccountSave {
#If Email address is not unique, a warning is displayed
if($warning ne "" && !$session{form}{confirm}){
$session{form}{confirm} = 1;
return $self->createAccount('<li>'.WebGUI::International::get(1078));
return $self->createAccount('<li>'.WebGUI::International::get(1078).'</li>');
}
my $properties;
@ -546,8 +546,8 @@ sub recoverPasswordFinish {
}
$sth->finish();
return $self->displayLogin('<ul><li>'.WebGUI::International::get(75).'</ul>') if($flag);
return $self->recoverPassword('<ul><li>'.WebGUI::International::get(76).'</ul>');
return $self->displayLogin('<ul><li>'.WebGUI::International::get(75).'</li></ul>') if($flag);
return $self->recoverPassword('<ul><li>'.WebGUI::International::get(76).'</li></ul>');
}
#-------------------------------------------------------------------
@ -583,8 +583,8 @@ sub resetExpiredPasswordSave {
$session{form}{username} = $u->username;
$error .= $self->error if(!$self->authenticate($session{form}{oldPassword}));
$error .= '<li>'.WebGUI::International::get(5,'AuthWebGUI') if($session{form}{identifier} eq "password");
$error .= '<li>'.WebGUI::International::get(12,'AuthWebGUI') if ($session{form}{oldPassword} eq $session{form}{identifier});
$error .= '<li>'.WebGUI::International::get(5,'AuthWebGUI').'</li>' if($session{form}{identifier} eq "password");
$error .= '<li>'.WebGUI::International::get(12,'AuthWebGUI').'</li>' if ($session{form}{oldPassword} eq $session{form}{identifier});
$error .= $self->error if(!$self->_isValidPassword($session{form}{identifier},$session{form}{identifierConfirm}));
return $self->resetExpiredPassword("<h1>".WebGUI::International::get(70)."</h1>".$error) if($error ne "");
@ -597,7 +597,7 @@ sub resetExpiredPasswordSave {
$msg = $self->login;
if($msg eq ""){
$msg = "<li>".WebGUI::International::get(17,'AuthWebGUI');
$msg = "<li>".WebGUI::International::get(17,'AuthWebGUI').'</li>';
}
return $self->displayLogin($msg);
}
@ -628,7 +628,7 @@ sub updateAccount {
my $username = $session{form}{'authWebGUI.username'};
my $password = $session{form}{'authWebGUI.identifier'};
my $passConfirm = $session{form}{'authWebGUI.identifierConfirm'};
my $display = '<li>'.WebGUI::International::get(81).'<p>';
my $display = '<li>'.WebGUI::International::get(81).'</li>';
my $error = "";
if($self->userId eq '1'){

View file

@ -116,9 +116,9 @@ sub validateProfileData {
while (%field = $a->hash) {
$data{$field{fieldName}} = WebGUI::Macro::negate(WebGUI::FormProcessor::process($field{fieldName},$field{dataType}, $field{dataDefault}));
if ($field{required} && $data{$field{fieldName}} eq "") {
$error .= '<li>'.(eval $field{fieldLabel}).' '.WebGUI::International::get(451);
$error .= '<li>'.(eval $field{fieldLabel}).' '.WebGUI::International::get(451).'</li>';
}elsif($field{fieldName} eq "email" && isDuplicateEmail($data{$field{fieldName}})){
$warning .= '<li>'.WebGUI::International::get(1072);
$warning .= '<li>'.WebGUI::International::get(1072).'</li>';
}
}
$a->finish;

View file

@ -78,9 +78,9 @@ sub menuWrapper {
$output .= $_[0];
$output .= '</td><td width="30%" class="tableMenu" valign="top">';
foreach $key (keys %{$_[1]}) {
$output .= '<li><a href="'.$key.'">'.$_[1]->{$key}.'</a>';
$output .= '<li><a href="'.$key.'">'.$_[1]->{$key}.'</a></li>';
}
$output .= '<li><a href="'.WebGUI::URL::page().'">'.WebGUI::International::get(493).'</a>';
$output .= '<li><a href="'.WebGUI::URL::page().'">'.WebGUI::International::get(493).'</a></li>';
$output .= '</td></tr></table>';
return $output;
}

View file

@ -380,7 +380,7 @@ sub www_editUserSave {
@groups = $session{cgi}->param("groupsToDelete");
$u->deleteFromGroups(\@groups);
} else {
$error = '<ul><li>'.WebGUI::International::get(77).' '.$session{form}{username}.'Too or '.$session{form}{username}.'02</ul>';
$error = '<ul><li>'.WebGUI::International::get(77).' '.$session{form}{username}.'Too or '.$session{form}{username}.'02</li></ul>';
}
if ($isSecondary) {
return _submenu(WebGUI::International::get(978));

View file

@ -501,6 +501,7 @@ each asset under the tab &quot;Meta&quot; in the asset properties.</p>
Metadata in combination with passive profiling produces AOI (Areas of
Interest) information. You can retrieve the value of a metadata property
with the &#94;AOIRank(); and &#AOIHits(); macros.</p>
</li>
<li><p><b>Show content based upon criteria<br>
</b>The Wobject Proxy allows you to select content based upon criteria like:<blockquote>
contenttype = sport AND source != newspaper</blockquote>

View file

@ -1163,10 +1163,10 @@ is set to "response".
'what next question description' => {
message => q|After defining the question, you may supply an answer:
<ul>
<li>Multiple Choice</il>
<li>Text</il>
<li>Frequency</il>
<li>Opinion</il>
<li>Multiple Choice</li>
<li>Text</li>
<li>Frequency</li>
<li>Opinion</li>
<li>Or you may return to the survey</li>
</ul>
</p>|,