Herzlichen Dank
DL
http://www.phpbbhacks.com/download/1184
Code: Alles auswählen
#-----[ INSERT WITHIN ROOT ]------------------------------------------
#
# wHEREVER YOU WOULD LIKE THE AD TO APPEAR INSIDE PHPBB ROOT INSERT
# -IF YOU WANT GROUP #1 USE " {AMAZON_1} "
# -IF YOU WANT GROUP #2 USE " {AMAZON_2} "
# -IF YOU WANT GROUP #3 USE " {AMAZON_3} "
# DO NOT USE THE QUOTES
#
#-----[ INSERT OUTSIDE ROOT ]------------------------------------------
#
# IF YOU WANT TO PLACE THE ITEMS OUTSIDE OF YOUR ROOT FOLDER USE THE
# FOLLOWING BLOCKS OF CODE, PLACE THEM EXACTLY WHERE YOU WOULD LIKE
# THE PRODUCT TO APPEAR.
#
#
#-----[ EDIT, ON ALL OUTSIDE CODE BLOCKS ]-----------------------------
#
$MYSQL_SERVER = 'localhost'; // Host point, normally 'localhost'
$MYSQL_USER = 'user'; // The database user name.
$MYSQL_PASS = 'pass'; // The database password.
$MYSQL_DBNAME = 'dbname'; // The database name.
#
#-----[ GROUP #1 ]------------------------------------------
#
<?
#
# BEGIN AMAZON 1
#
$MYSQL_SERVER = 'localhost';
$MYSQL_USER = 'user';
$MYSQL_PASS = 'pass';
$MYSQL_DBNAME = 'dbname';
$dbconnection = @mysql_connect($MYSQL_SERVER, $MYSQL_USER, $MYSQL_PASS) or die("Unable to connect to the mysql server<br>". mysql_error());
$db = @mysql_select_db($MYSQL_DBNAME, $dbconnection) or die("Couldn't select database.<br>" . mysql_error());
################################################################################
# Choose a random banner from the database
$sql = "SELECT * FROM phpbb_amazon1 ORDER BY RAND();";
# Run the above Query
$result = mysql_query($sql);
# End of querying
################################################################################
# Give the variables the data if the SQL query worked
if ($result){
$row = mysql_fetch_array($result);
$code = $row["amazon1_code"];}
# If it failed, give it defaults
else{
$code = ("Data Unavailable");}
# End of variable setting
################################################################################
# Give the variable the code
$amazon1 = "$code";
# End of variable setting!
################################################################################
#
# END AMAZON #1
#
# This line prints the banner
print "$amazon1";
?>
#
#-----[ GROUP #2 ]------------------------------------------
#
<?
#
# BEGIN AMAZON #2
#
$MYSQL_SERVER = 'localhost';
$MYSQL_USER = 'user';
$MYSQL_PASS = 'pass';
$MYSQL_DBNAME = 'dbname';
$dbconnection = @mysql_connect($MYSQL_SERVER, $MYSQL_USER, $MYSQL_PASS) or die("Unable to connect to the mysql server<br>". mysql_error());
$db = @mysql_select_db($MYSQL_DBNAME, $dbconnection) or die("Couldn't select database.<br>" . mysql_error());
################################################################################
# Choose a random banner from the database
$sql = "SELECT * FROM phpbb_amazon2 ORDER BY RAND();";
# Run the above Query
$result = mysql_query($sql);
# End of querying
################################################################################
# Give the variables the data if the SQL query worked
if ($result){
$row = mysql_fetch_array($result);
$code2 = $row["amazon2_code"];}
# If it failed, give it defaults
else{
$code2 = ("Data Unavailable");}
# End of variable setting
################################################################################
# Give the variable the code
$amazon2 = "$code2";
# End of variable setting!
################################################################################
#
# END AMAZON #2
#
# This line prints the banner
print "$amazon2";
?>
#
#-----[ GROUP #3 ]------------------------------------------
#
<?
#
# BEGIN AMAZON #3
#
$MYSQL_SERVER = 'localhost';
$MYSQL_USER = 'user';
$MYSQL_PASS = 'pass';
$MYSQL_DBNAME = 'dbname';
$dbconnection = @mysql_connect($MYSQL_SERVER, $MYSQL_USER, $MYSQL_PASS) or die("Unable to connect to the mysql server<br>". mysql_error());
$db = @mysql_select_db($MYSQL_DBNAME, $dbconnection) or die("Couldn't select database.<br>" . mysql_error());
################################################################################
# Choose a random banner from the database
$sql = "SELECT * FROM phpbb_amazon2 ORDER BY RAND();";
# Run the above Query
$result = mysql_query($sql);
# End of querying
################################################################################
# Give the variables the data if the SQL query worked
if ($result){
$row = mysql_fetch_array($result);
$code3 = $row["amazon3_code"];}
# If it failed, give it defaults
else{
$code3 = ("Data Unavailable");}
# End of variable setting
################################################################################
# Give the variable the code
$amazon2 = "$code3";
# End of variable setting!
################################################################################
#
# END AMAZON #3
#
# This line prints the banner
print "$amazon3";
?>
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
EoM