Here is the full coding:-
<?php
if ( ! defined( 'IPB_bridge' ) )
{
print "<h1>Incorrect access</h1>You cannot access this file directly.";
exit();
}
class IPB_bridge_admin
{
public function __construct()
{
require_once(ABSPATH . "wp-content/plugins/IPB_WP_bridge/WP_files/wpDebug.php");
$this->wpDebug = new wpDebug;
}
/**
* Will decided which settings page to load up and deal with. If setting page as have had the form
* submitted then lets check and update the WP options database. If not then lets just display the main form.
*
* @access public
* @return void
*/
public function IPB_admin_configuration()
{
if($_POST['IPB_bridge_hidden'] != true)
{
add_options_page("IPB 3.X.X Bridge", "IPB 3.X.X Bridge", 1, "IPB3.X.XBridge", array("IPB_bridge_admin", "IPB_bridge_config"));
}else
{
add_options_page("IPB 3.X.X Bridge", "IPB 3.X.X Bridge", 1, "IPB3.X.XBridge", array("IPB_bridge_admin", "IPB_bridge_update"));
}
}
/**
* This function will check to see if the required information i.e. Forums Directory as been completed and
* checks the path route. If everything is ok then we will add the updated info to WP options database.
*
* @access public
* @return void
*/
public function IPB_bridge_update()
{
$debug = $_POST['IPB_core_debug'];
$level = $_POST['IPB_debug_level'];
$request = "";
$IPB_directory = $_POST['IPB_bridge_forum_directory'];
if(trim($IPB_directory) != "")
{
$IPB_directory = IPB_bridge_functions::forum_directory_check($IPB_directory, true, false);
}
if($debug == true)
{
if($level == 1)
{
$this->wpDebug->request_debug("BOTH");
}
wpDebug::add_debug("File Test 2", true, $post);
}
if($IPB_directory == "")
{
$IPB_bridge_forum_directory = $_POST['IPB_bridge_forum_directory'];
$error = "There was a problem with the IPB forum directory, please recheck and try agian.";
require_once(ABSPATH . "wp-content/plugins/IPB_WP_bridge/wp_admin/admin_bridge_config.php");
}else
{
update_option('IPB_bridge_forum_directory', $IPB_directory);
update_option('IPB_bridge_complete', true);
require_once(ABSPATH . "wp-content/plugins/IPB_WP_bridge/wp_admin/admin_bridge_updated.php");
}
}
/**
* Loads up the basic setting page for the IPB Wordpress Bridge.
*
* @access public
* @return void
*/
function IPB_bridge_config()
{
$IPB_bridge_forum_directory = get_option('IPB_bridge_forum_directory');
if(preg_match("/\\\\/", $IPB_bridge_forum_directory))
{
$IPB_bridge_forum_directory = str_replace("\\\\", "\\", $IPB_bridge_forum_directory);
}
require_once(ABSPATH . "wp-content/plugins/IPB_WP_bridge/wp_admin/admin_bridge_config.php");
}
}
?>
I do know what you mean, it gotten my stump why it is working correctly for.
cap