|
Posted by Erwin Moller on 06/06/07 15:45
zoilus wrote:
> Trying to write html form program that calls php prog. If php prog has
> problem with what was entered would like to return from php to html
> program.
>
> Is this possible and if so, how?
>
> TIA
Hi,
Plain html pages are not refered to as programs, just html files.
Unless the Javascript in them is worth calling a program. ;-)
What you need is something like this:
<?php
// just an example, we expect a formelement named firstname
// If not set, redirect to error.html
if (!isset($_POST["firstname"])){
// refuse
header("Location: http://www.example.com/error.html");
exit;
}
// do your normal processing here.
?>
Regards,
Erwin Moller
Navigation:
[Reply to this message]
|