This is even shorter:

if ($requirement == $iscorrect) {
  $url="./html/default.html";
} else {
  $url="./html/login.html";
}
print "Location: $url\n\n";

- Jan-Willem

On Wed, 10 Oct 2001, Grierson, Garry (UK07) wrote:

> You can try something like this :
>
> if ($requirement == $iscorrect){ # Send to default page
>       print <<HTML_SCRIPT1;
>               <HTML>
>               <HEAD>
>                       <meta http-equiv="REFRESH" content="0;
> URL=../html/default.html"> # Or whatever the URL you want is
>                       <meta http-equiv="Content-Type" content="text/html";
> charset=iso-8859-1">
>               </HEAD>
>               <BODY link=@#0000A6@ vlink="#0000A6" alink="0000A6">
>               </BODY>
>                       </HTML>>
>       HTML_SCRIPT1
> }
> else { # Send to the login page
>       print <<HTML_SCRIPT2;
>               <HTML>
>               <HEAD>
>                       <meta http-equiv="REFRESH" content="0;
> URL=../html/login.html"> # Or whatever the URL you want is
>                       <meta http-equiv="Content-Type" content="text/html";
> charset=iso-8859-1">
>               </HEAD>
>               <BODY link=@#0000A6@ vlink="#0000A6" alink="0000A6">
>               </BODY>
>                       </HTML>>
>       HTML_SCRIPT2
> }
>
> I hope this helps.
> > -----Original Message-----
> > From:       James Kelty [SMTP:[EMAIL PROTECTED]]
> > Sent:       Monday, October 08, 2001 10:18 PM
> > To: [EMAIL PROTECTED]
> > Subject:    Sending someone to a new location...
> >
> > I would like to be able to send someone automatically to another page when
> > requirements in a for are filled out correctly. Other that presenting a
> > link
> > I can figure out how to do this.
> >
> > Example:
> >
> > Someone correctly fills out a user/pass form and is sent to the default
> > page,
> > otherwise they are sent to the login page again.... without having to give
> > them a link to back to the login screen...or to the default page.
> >
> > -James
> >
> >
> > --
> > James Kelty
> > Sr. Unix Systems Administrator
> > The Ashland Agency
> > 541.488.5248
> > [EMAIL PROTECTED]
> >
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to