Why is the below code not working and no response is received? Please help!
I want to check the Name.
<?php
echo '<form name="form">';
echo '<input type="text" name="Name" >';
echo '<input type="button" class="save" value="save" onClick="Check()" />';
echo '</form>';
$_POST["Name"] = $Name;
echo '<SCRIPT type="text/javascript">';
echo 'function Check(){';
echo 'if( strlen($Name) < 8) {';
echo 'alert("error name");';
echo '}else {';
echo 'form.submit();';
echo '}';
echo '}';
echo '</SCRIPT>';
?>