wrongful |
10-06-2004 11:52 AM |
Help with Ban List
I've created a page in my vBulletin that will show a list of banned users. This is created when a user is banned by inserting the information into a table in the db called tsh.
Anyhow, I am trying to display this information on the page through $bannedbit, but I just can't get it to display. I am sure it's a problem with my code, but I can't figure out what it is.
PHP Code:
<?php /*======================================================================*\ || #################################################################### || || # The Great Wrongful Distribution Ban List # || || # Version 1.0 for vBulletin 3.x.x by Thug Norris # || || # ---------------------------------------------------------------- # || || # Copyright ?2000-2004 Thug Norris. All Rights Reserved. # || || # This file may not be redistributed in whole or significant part. # || || #################################################################### || \*======================================================================*/ // ####################### SET PHP ENVIRONMENT ########################### error_reporting(E_ALL & ~E_NOTICE); $globaltemplates = array( 'shpage_main', 'shpage_banbit' ); // ######################### REQUIRE BACK-END ############################ require_once('./global.php'); // ######################### NO GUESTS ALLOWED!! ############################ if ($bbuserinfo['userid'] == 0) { print_no_permission(); } // ######################### SOME VARIABLES ############################ $pagetitle = "tsh"; // ######################### LETS GET STARTED ############################ // start navbar $navbits = array( "$phpfilename?$session[sessionurl]" => $pagetitle ); $navbits = construct_navbits($navbits); eval('$navbar = "' . fetch_template('navbar') . '";'); // get banned information $getbanned = $DB_site->query_first("SELECT " . TABLE_PREFIX . "userid, username, dateline, bannedpost, reason, sentbywhom, howlong FROM tsh ORDER BY banid DESC LIMIT 30"); while ( $banned = $DB_site->fetch_array( $getbanned ) ) { eval( '$bannedbit .= "' . fetch_template(shpage_banbit) . '";' ); } //print page eval('print_output("' . fetch_template('shpage_main') . '");'); ?>
Any help would be appreciated.
|