1
Rocketfuel
Protector Module Mainfile Settings Problem
  • 2008/5/8 6:54

  • Rocketfuel

  • Just popping in

  • Posts: 16

  • Since: 2008/5/6 1


Hi All,
i have finally managed to install the protector moduel in admin after adding the following settings to the mainfile.php

// XOOPS Physical Path
// Physical path to your main XOOPS directory WITHOUT trailing slash
// Example: define('XOOPS_ROOT_PATH', '/home/myhost/public_html/trusted_folder');
define('XOOPS_TRUST_PATH', '/home/myhost/public_html/trusted_folder');

The problem im having is editing the the final part of the mainfile.php

define('XOOPS_GROUP_ADMIN', '1');
define('XOOPS_GROUP_USERS', '2');
define('XOOPS_GROUP_ANONYMOUS', '3');

foreach ( array('GLOBALS', '_SESSION', 'HTTP_SESSION_VARS', '_GET', 'HTTP_GET_VARS', '_POST', 'HTTP_POST_VARS', '_COOKIE', 'HTTP_COOKIE_VARS', '_REQUEST', '_SERVER', 'HTTP_SERVER_VARS', '_ENV', 'HTTP_ENV_VARS', '_FILES', 'HTTP_POST_FILES', 'xoopsDB', 'xoopsUser', 'xoopsUserId', 'xoopsUserGroups', 'xoopsUserIsAdmin', 'xoopsConfig', 'xoopsOption', 'xoopsModule', 'xoopsModuleConfig', 'xoopsRequestUri') as $bad_global ) {
if ( isset( $_REQUEST[$bad_global] ) ) {
header( 'Location: '.XOOPS_URL.'/' );
exit();
}
}
if (!isset($xoopsOption['nocommon']) && XOOPS_ROOT_PATH != '') {
include XOOPS_ROOT_PATH."/include/common.php";
}
}
?>


Would someone please be good enough to paste the exact code that i would need to put in this part of the mainfile?(Please!)

I have tried editing it several times by adding the following code but im not sure if i am leaving something out because i get constant errors if i add the following.
define('XOOPS_GROUP_ADMIN', '1');
define('XOOPS_GROUP_USERS', '2');
define('XOOPS_GROUP_ANONYMOUS', '3');

<span style="color: #ff0000;">include( XOOPS_TRUST_PATH . '/modules/protector/include/precheck.inc.php' ) ;</span>
if (!isset($xoopsOption['nocommon']) <span style="color: #0000ff;">&& XOOPS_ROOT_PATH != ''</span> ) {
include XOOPS_ROOT_PATH."/include/common.php";
}
<span style="color: #ff0000;">include( XOOPS_TRUST_PATH . '/modules/protector/include/postcheck.inc.php' ) ;</span>

If someone could help me with this i would be very greatful

Thanks

2
stefan88
Re: Protector Module Mainfile Settings Problem
  • 2008/5/8 7:18

  • stefan88

  • Community Support Member

  • Posts: 1086

  • Since: 2004/9/20


Hi,

don't paste the spans ...

Instead of
<span style="color: #ff0000;">include( XOOPS_TRUST_PATH '/modules/protector/include/precheck.inc.php' ) ;</span
if (!isset(
$xoopsOption['nocommon']) <span style="color: #0000ff;">&& XOOPS_ROOT_PATH != ''</span> ) { 
include 
XOOPS_ROOT_PATH."/include/common.php"

<
span style="color: #ff0000;">include( XOOPS_TRUST_PATH '/modules/protector/include/postcheck.inc.php' ) ;</span>


it should be:

include( XOOPS_TRUST_PATH '/modules/protector/include/precheck.inc.php' ) ;
 
if (!isset(
$xoopsOption['nocommon']) && XOOPS_ROOT_PATH != '' ) { 
include 
XOOPS_ROOT_PATH."/include/common.php"


include( 
XOOPS_TRUST_PATH '/modules/protector/include/postcheck.inc.php' ) ;
..

3
Rocketfuel
Re: Protector Module Mainfile Settings Problem
  • 2008/5/8 7:25

  • Rocketfuel

  • Just popping in

  • Posts: 16

  • Since: 2008/5/6 1


Awesome it works perfectly thank you so much!

Login

Who's Online

214 user(s) are online (45 user(s) are browsing Support Forums)


Members: 1


Guests: 213


Johndavid,

more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Feb 29
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits