[ Index ] |
|
Code source de PHP NUKE 7.9 |
1 <?php 2 3 # $Author: chatserv $ 4 # $Date: 2004/10/05 18:04:51 $ 5 /************************************************************************/ 6 /* PHP-NUKE: Web Portal System */ 7 /* =========================== */ 8 /* */ 9 /* Link to the phpBB2 forum admin menu */ 10 /* */ 11 /* Copyright (c) 2002 by Tom Nitzschner (tom@toms-home.com) */ 12 /* http://bbtonuke.sourceforge.net */ 13 /* http://www.toms-home.com */ 14 /* */ 15 /* As always, make a backup before messing with anything. All code */ 16 /* release by me is considered sample code only. It may be fully */ 17 /* functual, but you use it at your own risk, if you break it, */ 18 /* you get to fix it too. No waranty is given or implied. */ 19 /* */ 20 /* This program is free software. You can redistribute it and/or modify */ 21 /* it under the terms of the GNU General Public License as published by */ 22 /* the Free Software Foundation; either version 2 of the License. */ 23 /* */ 24 /************************************************************************/ 25 /* Additional security & Abstraction layer conversion */ 26 /* 2003 chatserv */ 27 /* http://www.nukefixes.com -- http://www.nukeresources.com */ 28 /************************************************************************/ 29 /* Forum admin files for PHP-Nuke 7.5 by chatserv */ 30 /************************************************************************/ 31 32 if ( !defined('ADMIN_FILE') ) 33 { 34 die("Illegal File Access"); 35 } 36 37 global $prefix, $db; 38 $aid = substr("$aid", 0,25); 39 $row = $db->sql_fetchrow($db->sql_query("SELECT title, admins FROM ".$prefix."_modules WHERE title='Forums'")); 40 $row2 = $db->sql_fetchrow($db->sql_query("SELECT name, radminsuper FROM ".$prefix."_authors WHERE aid='$aid'")); 41 $admins = explode(",", $row['admins']); 42 $auth_user = 0; 43 for ($i=0; $i < sizeof($admins); $i++) { 44 if ($row2['name'] == "$admins[$i]" AND $row['admins'] != "") { 45 $auth_user = 1; 46 } 47 } 48 49 if ($row2['radminsuper'] == 1 || $auth_user == 1) { 50 51 switch($op) { 52 53 case "forums": 54 Header("Location: modules/Forums/admin/index.php"); 55 } 56 57 58 } else { 59 echo "Access Denied"; 60 } 61 # $Log: forums.php,v $ 62 # Revision 1.1 2004/10/05 18:04:51 chatserv 63 # Initial CVS Addition 64 # 65 66 ?>
titre
Description
Corps
titre
Description
Corps
titre
Description
Corps
titre
Corps
Généré le : Sun Apr 1 11:11:59 2007 | par Balluche grâce à PHPXref 0.7 |