[KLUG Members] PHP Redirect.

J. Edward Durrett members@kalamazoolinux.org
Wed, 26 Mar 2003 09:47:42 -0500


Although this does not check credentials, here is a simple example that 
might help:

<?php

/**
  * index.php
  *
  * Copyright (c) 1999-2002 The SquirrelMail Project Team
  * Licensed under the GNU GPL. For full terms see the file COPYING.
  *
  * This file simply takes any attempt to view source files and sends 
those
  * people to the login screen. At this point no attempt is made to see 
if
  * the person is logged or not.
  *
  * $Id: index.php,v 1.2 2001/12/23 07:42:38 thomppj Exp $
  */

header("Location:../index.php");

/* pretty impressive huh? */

?>

On Wednesday, March 26, 2003, at 09:18 AM, Richard Vincent wrote:

> Hello All,
>
> Does anyone know of an easy way to do a page redirect using PHP. For
> example:
>
> 	if($row) //User Credentials are valid
> 	{
> 		<Magic Page Redirect to welcome.php>
> 	}
> 	else
> 	{
> 		<Magic Page Redirect back to login.php>
> 	}
>
> Many Thanx
> Richard Vincent
> 	
> _______________________________________________
> Members mailing list
> Members@kalamazoolinux.org
> 
>
>
Jason Edward Durrett
Vice President of Operations
B. Shackman Company, Inc.
269.484.1000