Last change
on this file since 264 was
231,
checked in by z0rglub, 21 years ago
|
define( CONSTANT, 'value' ) becomes define( "CONSTANT", 'value')
|
-
Property svn:eol-style set to
native
-
Property svn:keywords set to
Author Date Id Revision
|
File size:
1.7 KB
|
Rev | Line | |
---|
[2] | 1 | <?php |
---|
[57] | 2 | /*************************************************************************** |
---|
| 3 | * index.php * |
---|
| 4 | * ------------------- * |
---|
| 5 | * application : PhpWebGallery 1.3 <http://phpwebgallery.net> * |
---|
| 6 | * author : Pierrick LE GALL <pierrick@z0rglub.com> * |
---|
| 7 | * * |
---|
| 8 | * $Id: index.php 231 2003-11-03 22:39:53Z z0rglub $ |
---|
| 9 | * * |
---|
[191] | 10 | *************************************************************************** |
---|
| 11 | |
---|
| 12 | /*************************************************************************** |
---|
| 13 | * * |
---|
| 14 | * This program is free software; you can redistribute it and/or modify * |
---|
| 15 | * it under the terms of the GNU General Public License as published by * |
---|
| 16 | * the Free Software Foundation; * |
---|
| 17 | * * |
---|
[57] | 18 | ***************************************************************************/ |
---|
| 19 | |
---|
[231] | 20 | define( "PREFIX_INCLUDE", '' ); |
---|
[2] | 21 | include_once( './include/functions.inc.php' ); |
---|
| 22 | database_connection(); |
---|
[21] | 23 | // retrieving configuration informations |
---|
| 24 | $query = 'SELECT access'; |
---|
| 25 | $query.= ' FROM '.PREFIX_TABLE.'config;'; |
---|
[2] | 26 | $row = mysql_fetch_array( mysql_query( $query ) ); |
---|
[191] | 27 | if ( $row['access'] == 'restricted' ) |
---|
| 28 | { |
---|
| 29 | if ( isset( $_COOKIE['id'] ) ) $url = 'category'; |
---|
| 30 | else $url = 'identification'; |
---|
| 31 | } |
---|
| 32 | else $url = 'category'; |
---|
[2] | 33 | // redirection |
---|
| 34 | $url.= '.php'; |
---|
| 35 | header( 'Request-URI: '.$url ); |
---|
| 36 | header( 'Content-Location: '.$url ); |
---|
| 37 | header( 'Location: '.$url ); |
---|
| 38 | exit(); |
---|
| 39 | ?> |
---|
Note: See
TracBrowser
for help on using the repository browser.