Hi Guys i am having a very peculiar problem i have written a small code so that it is possible to sign up to the website i am creating with a few restrictions to each field however from what i see the code seems ok but each time i try to use the php code with html code the browser is always printing part of the code like this:
"11){ echo 'Username needs at least 6 and maximum 11 characters'; } else if (strpos($Username, '@') != 0) { echo ' Username cant be your email'; } ?>"
<?php
$Username = 'aasd';
if (strlen($Username) < 6 || strlen($Username) > 11){
echo 'Username needs at least 6 and maximum 11 characters';
}
else if (strpos($Username, '@') != 0) {
echo ' Username cant be your email';
}
?>
From what i can see the code is correct but i can't seem to find the reason as to why this is happening am i missing something in the PHP code? do i have some condition or operator that is not set in the right way?
Thank you first hand to all those who reply