context_title
context_text
Topic Summary - Displaying 6 post(s). Click here to show all |
Posted by: Rucola Posted on: Mar 1st, 2018 at 8:23pm
|
fixed
|
Posted by: Dandello Posted on: Mar 1st, 2018 at 7:41pm
|
Since I'm back from my errands I can upload the fixes to your server in a bit. Edited: And it should be okay now. I also did a backup before making any changes in case something went bad.
|
Posted by: Rucola Posted on: Mar 1st, 2018 at 6:28pm
|
and can attach the modified file? -or me the lines do not match the bracket should be on another line and between the code and the unit of lines?
|
Posted by: Dandello Posted on: Mar 1st, 2018 at 4:17pm
|
Okay - SourceForge is down so I can't upload anything to the SVN right now. Plus I have some appointments this AM and won't be back for a while. BUT: In Sources/UserSelect.pm replace the entire sub routine 'checkuser_avail' with sub checkuser_avail {
load_language('Register');
no warnings qw(uninitialized);
my $taken = 'false';
my $namecheck = $matchcase ? $INFO{'user'} : lc $INFO{'user'};
my $realnamecheck =
$matchcase eq 'checked' ? $INFO{'display'} : lc $INFO{'display'};
my ( $type, $reservecheck, $avail );
if ( $INFO{'type'} eq 'email' ) {
$INFO{'email'} =~ s/\A\s+|\s+\z//gxsm;
$type = $register_txt{'112'};
if (
lc $INFO{'email'} eq
lc member_index( 'check_exist', $INFO{'email'}, 2 ) )
{
$taken = 'true';
}
}
elsif ( $INFO{'type'} eq 'display' ) {
$INFO{'display'} =~ s/\A\s+|\s+\z//gxsm;
$type = $register_txt{'111'};
if (
(
lc $INFO{'display'} eq
lc member_index( 'check_exist', $INFO{'display'}, 1 )
)
&& ( lc $INFO{'display'} ne lc ${ $uid . $username }{'realname'} )
)
{
$taken = 'true';
}
if ($matchname) {
foreach my $reserved (@reserve) {
chomp $reserved;
$reservecheck = $matchcase ? $reserved : lc $reserved;
if ($matchword) {
if ( $realnamecheck eq $reservecheck ) {
$taken = 'reg';
last;
}
}
else {
if ( $realnamecheck =~ /$reservecheck/xsm ) {
$taken = 'reg';
last;
}
}
}
}
}
elsif ( $INFO{'type'} eq 'user' ) {
$INFO{'user'} =~ s/\A\s+|\s+\z//gxsm;
$INFO{'user'} =~ s/\s/_/gxsm;
$type = $register_txt{'110'};
if (
lc $INFO{'user'} eq
lc member_index( 'check_exist', $INFO{'user'}, 0 ) )
{
$taken = 'true';
}
if ($matchuser) {
foreach my $reserved (@reserve) {
chomp $reserved;
$reservecheck = $matchcase ? $reserved : lc $reserved;
if ($matchword) {
if ( $namecheck eq $reservecheck ) {
$taken = 'reg';
last;
}
}
else {
if ( $namecheck =~ /$reservecheck/xsm ) {
$taken = 'reg';
last;
}
}
}
}
}
if ( $taken eq 'false' ) {
$avail =
qq~<img src="$imgdir/check.png"> <span style="color:#00dd00">$type$register_txt{'114'}</span>~;
}
elsif ( $taken eq 'true' ) {
$avail =
qq~<img src="$imgdir/cross.png"> <span style="color:#dd0000">$type$register_txt{'113'}</span>~;
}
else {
$avail =
qq~<img src="$imgdir/cross.png"> <span style="color:#dd0000">$type$register_txt{'115'}</span>~;
}
print
"Content-type: text/plain;charset=$yymycharset;\n\n$INFO{'type'}|$avail"
or croak "$croak{'print'} avail";
CORE::exit; # This is here only to avoid server error log entries!
return;
}
There were several lines that needed to be added/changed.
|
Posted by: Dandello Posted on: Mar 1st, 2018 at 3:23pm
|
Okay, just tested this and you're right - the test isn't working right. (Good catch)
|
Posted by: Rucola Posted on: Mar 1st, 2018 at 2:17pm
|
the problem with checking new nicknames for the existence-user was able to register one nickname for 2 different logins
|