how limit max numbers/letters in account ?znote register

Discussion in 'Support' started by CipsoftStinks, Jan 11, 2017.

  1. CipsoftStinks

    CipsoftStinks Nekro

    Joined:
    Oct 1, 2016
    Messages:
    107
    Likes Received:
    4
    Best Answers:
    1
    Hello otland

    Well at the title says

    is possible to limit the max letters numbers that Znote ACC allow
    when you registrer your account?

    regards
    i used search also looked in files
    and i did not found nothing
     
  2. Best Answer:
    Post #7 by Znote, Jan 11, 2017
  3. StreamSide

    StreamSide Joseluis Gonzalez

    Joined:
    Aug 31, 2007
    Messages:
    2,573
    Likes Received:
    506
    Best Answers:
    1
    PHP:
    1. strlen($_POST['username']) > 100
     
  4. Znote

    Znote <?php echo $title; ?> Staff Member Global Moderator Premium User

    Joined:
    Feb 14, 2008
    Messages:
    6,043
    Likes Received:
    849
    Best Answers:
    81
  5. StreamSide

    StreamSide Joseluis Gonzalez

    Joined:
    Aug 31, 2007
    Messages:
    2,573
    Likes Received:
    506
    Best Answers:
    1
  6. CipsoftStinks

    CipsoftStinks Nekro

    Joined:
    Oct 1, 2016
    Messages:
    107
    Likes Received:
    4
    Best Answers:
    1
    thanks to you both guys i know that
    but there is a way r is not possible? limit for example the account numer max limit numbers/letters to 8?
    i need it i use tibia 7.72 and the client doesn't support more than 8 letters/numbers in account name
    and people never reads they say "he i can't log in its bugged"..
    help
     
  7. CipsoftStinks

    CipsoftStinks Nekro

    Joined:
    Oct 1, 2016
    Messages:
    107
    Likes Received:
    4
    Best Answers:
    1
    @StreamSide where is that line located can you tell me please?
     
  8. Znote

    Znote <?php echo $title; ?> Staff Member Global Moderator Premium User

    Joined:
    Feb 14, 2008
    Messages:
    6,043
    Likes Received:
    849
    Best Answers:
    81
    Best Answer
    To only allow 8 digit number as username:
    PHP:
    1.  
    2. if ((int)$_POST['username'] < 10000000 || (int)$_POST['username'] > 99999999) {
    3.     $errors[] = 'Your account name must be an 8 digit long number.';
    4. }
    5.  
     

Share This Page

Loading...