Menu
Hello. I want a user to be able to submit only a non-empty form. What is the best way of doing that? Allowed technologies: php, javascript.
[code]
<form action=”submit.php” method=”post”>
message: <input class=s1 type=”text” name=”message” style=”width:50%” value=”<?php if($_SESSION[“i”]>1){echo ”;}else{echo ‘write a new message here..’;} ?>” onfocus=”this.value=”” />
<input class=s1 type=submit value=send>
</form>
Could you please help me? Thank you.