Using a form, I am attempting to force users to resubmit a username with all spaces
I used the ltrim command
$trimwalen=ltrim($username, " ");
if ($trimwalen===NULL || $trimwalen="" || $trimwalen=" ") {$ch = 1;}
If $ch is 1, then the form repeats for the user, prompting them to use another username.
It doesn't work. The users can still submit a username with all spaces.
Any advice appreciated.