Salut a tous
Je viens d'installer un script pour mon projet de site,mais un pb apparait a l'accés de mon admin:
Parse error: syntax error, unexpected '}' in /home.10.3/annuairext/www/france-libertins/admin/index.php on line 34
Voici le code:
1 <?
2 /*
3 (C) AEwebworks Software Development Ltd., 2002-2003
4 IMPORTANT: This is a commercial software product and any kind of using it must agree
5 to the AEwebworks Software Development Ltd. license agreement. It can be found at
6 http://www.aewebworks.com/license.htm
7 This notice may not be removed from the source code.
8 */
9
10 require_once( "../inc/header.inc.php" );
11 require_once( "{$dir['inc']}db.inc.php" );
12 require_once( "{$dir['inc']}admin.inc.php" );
13 require_once( "{$dir['inc']}profiles.inc.php" );
14 require_once( "{$dir['inc']}design.inc.php" );
15 require_once( "{$dir['inc']}admin_design.inc.php" );
16 require_once( "{$dir['inc']}utils.inc.php" );
17
18 if ( $_POST['ID'] )
19 {
20 $admin_id = process_db_input( $_POST['ID'] );
21 $admin_pass = process_db_input( $_POST['Password'] );
22 $result = db_res( "SELECT * FROM `Admins` WHERE `Name` = '$admin_id'
23 AND `Password`= '$admin_pass'" );
24 if ( mysql_num_rows( $result ) != 1 )
25 login_form( '<center><b><font color="#ff0000">Login Failed! Try again</font></b></center>', 1 );
26 } else {
27 setcookie ("adminID", $_POST[ID], 0, "/" );setcookie ("adminPassword", crypt( $_POST[Password], 'secret_string' ), 0, "/" );
28
29 ?>
30 Welcome back, <b><? echo $admin_id; ?></b>. Logging you in...
31 <script language="Javascript">location.href='<? echo $_SERVER[PHP_SELF]; ?>';</script>
32 <?
33 exit;
34 }
35 }
36 if ( !$_COOKIE['adminID'] || !$_COOKIE['adminPassword'] )
37 {
38 // this is dynamic page - send headers to do not cache this page
39 send_headers_page_changed();
40 login_form( "", 1 );
41 }
42
43 $logged['admin'] = member_auth( 1 );
44
45 $free_mode = getParam("free_mode" ) == "on" ? 1 : 0;
Merci a vous