Jump to content

Old Novus

Members
  • Posts

    14
  • Joined

  • Last visited

    Never

Profile Information

  • Gender
    Not Telling

Old Novus's Achievements

Newbie

Newbie (1/5)

0

Reputation

  1. Parse error: syntax error, unexpected '{' in C:\www\webroot\process.php on line 41 thats the nwe error...and its on the code line where preg is...on that line.
  2. if (!eregi_match("/^\([0-9A-Za-z])+$/", $username)) { echo '<script language="Javascript">alert ("Bad characters in username")</script>'; include("index.html"); exit(); This isnt working...we need it to ONLY allow a-z and 0-9 and nothing else...
  3. another bump...still not working....guys please look at the full script and youll be able to better see what were trying to accomplish. this is hard i guess.
  4. if (!eregi("([0-9A-Za-z])", $username)) { this is still letting the script run...but it isnt blocking the wierd letters like this à++}áÜ...is there anyway to tweak that line to make it so there is ONLY a-z and 0 - 9 allowed, with no spaces or symbols?
  5. validate($_POST['username'], $_POST['email']); Username is trying to be created in the form.....but we want those restrictions of only allowing a-z 0-9 etc. Thanks for helping us
  6. the username definition? The reason why we have to have it so it only accepts a-z and 0-9 is because the game server that this php file is writing to doesnt accept spaces or underscores or +à?ÿè all those characters...it only accepts a-z and 0 - 9...and if anything else is in there, then it deletes that letter and bam it will overwrite an account...big security issue...that is why it must only accept a-z and 0-9 :/ very frustrating lol.
  7. it keeps saying bad characters in username even if i just put in characters a - z ...for example i put in "hi" as the username and it tells me bad characters... anyone help please? only a-z and 0 - 9 allowed. With no spaces or any marks or wierd letters like this ౬
  8. its saying bad characters everytime now...
  9. ok so that one will only allow a - z A - Z and 0 - 9 and nothing else like this: _ ' \ ][ àd·£ right?
  10. can you kinda explain what that one does? heheh so i replace my line of :if (!eregi("[A-Z0-9]", $username)){ echo '<script language="Javascript">alert ("Bad characters in username")</script>'; include("index.html"); exit(); With this: if (!preg_match("/^\w+$/", $username)) { echo ''Bad characters..." } then people will only be able to use letters a-z and 0-9?
  11. Hi everyone, I'm new to the community and plan to be a long time active member! I have a question though with this php script we've got. It's for a game out there and it's the account creator. We need a way to limit the accounts being made to letters a-z and number 0-9. The problem is people are using these ìÿ letters and its making the accounts buggy. Here is my code: Thanks guys. if you have any questions please don't hesitate to ask. Here is the array that is allowed for the account characters...but it doesnt seem to be working :if (!eregi("[A-Z0-9]", $username)){ echo '<script language="Javascript">alert ("Bad characters in username")</script>'; include("index.html"); exit(); We need strictly a-z or 0-9 only or else it bugs out accounts and could get other people's accounts over written. Any help is appreciated.
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.