Re: Calling HTML pages

From: Date: Thu, 05 Jun 2003 07:02:09 +0000
Subject: Re: Calling HTML pages
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-150298@lists.php.net to get a copy of this message
on Wed, Jun 4, 2003, Daniel J. Rychlik wrote: >I was looking for a function that will take you to a html page. For instance. > >I have a function that checks for !empty values in $_POST; What I would >like to do is if the field is empty then > >go back to the form. I have a function > >function display_error ($err) { > > echo $err; # I need to redirect or automatically go to the previous >page. > >} > >Is their a PHP function already written that does this ? I am a PHP newbie but have just completed an application that uses something similar. This is how I did it: function display_error ($err) { include(./mypage.php); } and there is code to show the error message and changes some styles in mypage.php As I said, I'm a newbie so I'm not sure that this is the best solution but it works ok. Ian

« previous php.general (#150298) next »