how limit max numbers/letters in account ?znote register

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

  1. CipsoftStinks

    CipsoftStinks Old Tibia Player

    Joined:
    Oct 1, 2016
    Messages:
    308
    Likes Received:
    22
    Best Answers:
    2
    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,740
    Likes Received:
    565
    Best Answers:
    7
    PHP:
    1. strlen($_POST['username']) > 100
     
  4. Znote

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

    Joined:
    Feb 14, 2008
    Messages:
    6,116
    Likes Received:
    904
    Best Answers:
    93
  5. StreamSide

    StreamSide Joseluis Gonzalez

    Joined:
    Aug 31, 2007
    Messages:
    2,740
    Likes Received:
    565
    Best Answers:
    7
  6. CipsoftStinks

    CipsoftStinks Old Tibia Player

    Joined:
    Oct 1, 2016
    Messages:
    308
    Likes Received:
    22
    Best Answers:
    2
    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 Old Tibia Player

    Joined:
    Oct 1, 2016
    Messages:
    308
    Likes Received:
    22
    Best Answers:
    2
    @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,116
    Likes Received:
    904
    Best Answers:
    93
    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...