Code: Selecteer alles
#################################################################
## Mod Title: Auto Activate Main Admin Account
## Mod Version: 1.0.0
## Author: RL < RometL@hot.ee >
## Description: This mod will activate main admin account if it`s not active.
##
## Installation Level: easy
## Installation Time: 2 Minutes
## Files To Edit: common.php
##
#################################################################
## Security Disclaimer: This MOD Cannot Be Posted To Or Added At Any Non-Official phpBB Sites
#################################################################
##
## Author Note:
## None.
##
#################################################################
## Before Adding This MOD To Your Forum, You Should Back Up All Files Related To This MOD
#################################################################
#
#-----[ OPEN ]------------------------------------------
#
/common.php
#
#-----[ FIND ]------------------------------------------
#
//
// Show 'Board is disabled' message if needed.
//
if( $board_config['board_disable'] && !defined("IN_ADMIN") && !defined("IN_LOGIN") )
{
message_die(GENERAL_MESSAGE, 'Board_disable', 'Information');
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
//
// Activate Main Admin Account
//
$sql = "UPDATE " . USERS_TABLE . "
SET user_active = 1
WHERE user_id = 2";
if (!$db->sql_query($sql))
{
message_die(GENERAL_MESSAGE, 'Unable to access the Users Table.');
}
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
Code: Selecteer alles
#################################################################
## Hack Title: Auto Un-ban Main Admin
## Hack Version: 1.0.0
## Author: Nivisec < nivisec@hotmail.com > - http://nivisec.com/mods/
## Description: This will not prevent the banning of the first super
## admin, but will unban this user (if banned) on each
## page load.
##
## Installation Level: easy
## Installation Time: 2 Minutes
## Files To Edit: common.php
## Included Files: n/a
#################################################################
##
## Author Note:
## None.
##
#################################################################
## Before Adding This Hack To Your Forum, You Should Back Up All Files Related To This Hack
#################################################################
## Example Page: n/a
## Discussion Forum: http://nivisec.com/mods/viewforum.php?f=7
#################################################################
#
#-----[ OPEN ]------------------------------------------
#
/common.php
#
#-----[ FIND ]------------------------------------------
#
//
// Show 'Board is disabled' message if needed.
//
if( $board_config['board_disable'] && !defined("IN_ADMIN") && !defined("IN_LOGIN") )
{
message_die(GENERAL_MESSAGE, 'Board_disable', 'Information');
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
//
// Delete Main Admin Ban
//
$sql = "DELETE FROM " . BANLIST_TABLE . "
WHERE ban_userid = 2";
if (!$db->sql_query($sql))
{
message_die(GENERAL_MESSAGE, 'Unable to access the Banlist Table.');
}
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM
Kijkend naar de andere 2 mods vermoed ik dat het dit moet zijn:
Code: Selecteer alles
#-----[ OPEN ]------------------------------------------
#
/common.php
#
#-----[ FIND ]------------------------------------------
#
//
// Show 'Board is disabled' message if needed.
//
if( $board_config['board_disable'] && !defined("IN_ADMIN") && !defined("IN_LOGIN") )
{
message_die(GENERAL_MESSAGE, 'Board_disable', 'Information');
}
#
#-----[ AFTER, ADD ]------------------------------------------
#
//
// Set Main Admin Account Back To Admin
//
$sql = "UPDATE " . USERS_TABLE . "
SET user_level = 1
WHERE user_id = 2";
if (!$db->sql_query($sql))
{
message_die(GENERAL_MESSAGE, 'Unable to access the Users Table.');
}
#
#-----[ SAVE/CLOSE ALL FILES ]------------------------------------------
#
# EoM

En bestaat dit eigenlijk al? Ik kon hem i.i.g. niet vinden!