Page Index Toggle Pages: 1 ReplyAdd Poll Send Topic
Normal Topic the problem with checking new nicknames... (Read 219 times)
 
Paste Member Name in Quick Reply Box Rucola
Senior Member
Bug Finder
****
Offline



Posts: 286
Location: Country Children Song
Joined: Aug 9th, 2017
Gender: Male
Mood: Adventurous
Zodiac sign: Taurus
Re: the problem with checking new nicknames...
Reply #5 - Mar 1st, 2018 at 8:23pm
Mark & QuoteQuote  

fixed Smiley
  
Back to top
 
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2121
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: the problem with checking new nicknames...
Reply #4 - Mar 1st, 2018 at 7:41pm
Mark & QuoteQuote  
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.
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Rucola
Senior Member
****
Offline



Posts: 286
Location: Country Children Song
Joined: Aug 9th, 2017
Gender: Male
Mood: Adventurous
Zodiac sign: Taurus
Re: the problem with checking new nicknames...
Reply #3 - Mar 1st, 2018 at 6:28pm
Mark & QuoteQuote  
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?
  
Back to top
 
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2121
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: the problem with checking new nicknames...
Reply #2 - Mar 1st, 2018 at 4:17pm
Mark & QuoteQuote  
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

Code (Perl)
Select All
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">&nbsp;&nbsp;<span style="color:#00dd00">$type$register_txt{'114'}</span>~;
     }
     elsif ( $taken eq 'true' ) {
         $avail =
 qq~<img src="$imgdir/cross.png">&nbsp;&nbsp;<span style="color:#dd0000">$type$register_txt{'113'}</span>~;
     }
     else {
         $avail =
 qq~<img src="$imgdir/cross.png">&nbsp;&nbsp;<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.
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Dandello
Forum Administrator
YaBB Modder
*****
Offline


I love YaBB 2.7!

Posts: 2121
Location: The Land of YaBB
Joined: Feb 12th, 2014
Gender: Female
Mood: Annoyed
Zodiac sign: Virgo
Re: the problem with checking new nicknames...
Reply #1 - Mar 1st, 2018 at 3:23pm
Mark & QuoteQuote  
Okay, just tested this and you're right - the test isn't working right. (Good catch)
  

Perfection is not possible. Excellence, however, is excellent.
Back to top
WWW  
IP Logged
 
Paste Member Name in Quick Reply Box Rucola
Senior Member
****
Offline



Posts: 286
Location: Country Children Song
Joined: Aug 9th, 2017
Gender: Male
Mood: Adventurous
Zodiac sign: Taurus
the problem with checking new nicknames...
Mar 1st, 2018 at 2:17pm
Mark & QuoteQuote  

the problem with checking new nicknames for the existence-user was able to register one nickname for 2 different logins
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
ReplyAdd Poll Send Topic
Bookmarks: del.icio.us Digg Facebook Google Google+ LinkedIn reddit StumbleUpon Twitter Yahoo
the problem with checking new nicknames...

Please type the characters exactly as they appear in the image,
without the first 2 and last 2 characters.
The characters must be typed in the same order,
and they are case-sensitive.
Open Preview Preview

You can resize the textbox by dragging the right or bottom border.
Off Topic Comment Insert Spoiler
Insert Hyperlink Insert FTP Link Insert Image Insert E-mail Insert Media Insert Table Insert Table Row Insert Table Column Insert Horizontal Rule Insert Teletype Insert Code Insert Quote Edited Superscript Subscript Insert List /me - my name Insert Marquee Insert Timestamp No Parse
Bold Italicized Underline Insert Strikethrough Highlight
                       
Change Text Color
Insert Preformatted Text Left Align Centered Right Align
resize_wb
resize_hb







Max 5000 characters. Remaining characters:
Text size: %
More Smilies
View All Smilies
Collapse additional features Collapse/Expand additional features Smiley Wink Cheesy Grin Angry Sad Shocked Cool Huh Roll Eyes Tongue Embarrassed Lips Sealed Undecided Kiss Cry