Space in user registration username
Posted: Mon Nov 28, 2011 12:41 pm
Hi
I've almost got the Register and Login tut working.
When registering, if I enter a username but no pass, when the page comes back, the username reappears in the form field, but it has a space entered before it.
Here's the code:
Thanks
ps - I just noticed that if you repeat the above process, spaces just keep getting added
Shaun
I've almost got the Register and Login tut working.
When registering, if I enter a username but no pass, when the page comes back, the username reappears in the form field, but it has a space entered before it.
Here's the code:
<input type="text" name="username" id="username" value=" <?php if(isset($_POST['username']))echo htmlentities($_POST['username']);?>" />Has anyone else had the same thing?
Thanks
ps - I just noticed that if you repeat the above process, spaces just keep getting added
Shaun