Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks
Author Message
t_henson
Regular
Regular


Joined: Feb 02, 2007
Posts: 65
Location: Cincinnati, Ohio

PostPosted: Fri Aug 31, 2007 12:42 pm Reply with quote

i was wondering if anyone knows if the NSN Center Blocks mod is compatible with the newest version of RN?
 
View user's profile Send private message
t_henson
PostPosted: Sat Sep 01, 2007 12:12 pm Reply with quote

well i went ahead and tried to install it, but i encountered some problems. the edits for the core files aren't exactly right.

here is what it says to edit in footer.php:
Code:
# 

#-----[ FIND ]------------------------------------------
#
    if ($home == 1) {
   blocks(Down);
    }

#
#-----[ REPLACE WITH ]------------------------------------------
#
    if ($home == 1) {
   blocks(Down);
        include("includes/cblocks3.php"); // if you want this on all pages, place it above if ($home == 1) {
    } else {
        include("includes/cblocks4.php"); // if you want this on all pages, place it above if ($home == 1) {
    }


but here is how it is written in RN:
Code:
   if(defined('HOME_FILE')) {

      blocks('Down');
   }


is there a way to make this work?
 
t_henson
PostPosted: Sat Sep 01, 2007 12:15 pm Reply with quote

here is what it says to edit in header.php:

Code:
# 

#-----[ FIND ]------------------------------------------
#
if ($home == 1) {
    message_box();
    blocks(Center);
}

#
#-----[ REPLACE WITH ]------------------------------------------
#
if($home == 1) {
    message_box();
    blocks(Center);
    include("includes/cblocks1.php"); // if you want this on all pages, place it above if ($home == 1) {
} else {
    include("includes/cblocks2.php"); // if you want this on all pages, place it above if ($home == 1) {
}


but here is how it is written in RN:
Code:
if(defined('HOME_FILE')) {

    message_box();
    blocks('Center');
}
 
Gremmie
Former Moderator in Good Standing


Joined: Apr 06, 2006
Posts: 2415
Location: Iowa, USA

PostPosted: Sat Sep 01, 2007 1:31 pm Reply with quote

Where it suggests replacing $home == 1, just keep the new RN way of defined('HOME_FILE')

_________________
Only registered users can see links on this board! Get registered or login! - An Event Calendar for PHP-Nuke
Only registered users can see links on this board! Get registered or login! - A Google Maps Nuke Module 
View user's profile Send private message
Gremmie
PostPosted: Sat Sep 01, 2007 1:32 pm Reply with quote

Code:


#
#-----[ FIND ]------------------------------------------
#
    if (defined('HOME_FILE')) {
   blocks(Down);
    }

#
#-----[ REPLACE WITH ]------------------------------------------
#
    if (defined('HOME_FILE')) {
   blocks(Down);
        include("includes/cblocks3.php"); // if you want this on all pages, place it above if ($home == 1) {
    } else {
        include("includes/cblocks4.php"); // if you want this on all pages, place it above if ($home == 1) {
    }
 
t_henson
PostPosted: Sat Sep 01, 2007 7:30 pm Reply with quote

okay, thanks. so my problem must be here

in mainfile.php it says to do this:

Code:
# 

#-----[ FIND ]------------------------------------------
#
?>

#
#-----[ BEFORE, ADD ]------------------------------------------
#
if (defined('FORUM_ADMIN')) {
    include_once("../../../includes/nsncb_func.php");
} elseif (defined('INSIDE_MOD')) {
    include_once("../../includes/nsncb_func.php");
} else {
    include_once("includes/nsncb_func.php");
}


after i added this the first time, it worked fine. i went into admin panel, clicked row1 configuration, picked my first blocked and clicked saved settings. now when i click row1 configuration, it takes me to Only registered users can see links on this board! Get registered or login! so i went back in and set my first block in row2, and now i cant even access anywhere on my site except my home nuke page, unless i go back to using the unmodified mainfile.php
 
t_henson
PostPosted: Sun Sep 02, 2007 9:08 pm Reply with quote

<bump> anyone?
 
t_henson
PostPosted: Mon Sep 03, 2007 5:17 pm Reply with quote

a bit of an update...

i found this in the RN mainfile.php
Code:
if(defined('FORUM_ADMIN')) define('INCLUDE_PATH', '../../../');

elseif(defined('INSIDE_MOD')) define('INCLUDE_PATH', '../../');
else define('INCLUDE_PATH', './');


so i just added this to it
Code:
if (defined('FORUM_ADMIN')) {

    define('INCLUDE_PATH', '../../../');
    include_once("../../../includes/nsncb_func.php");
} elseif (defined('INSIDE_MOD')) {
    define('INCLUDE_PATH', '../../');
    include_once("../../includes/nsncb_func.php");
} else {
    define('INCLUDE_PATH', './');
    include_once("includes/nsncb_func.php");
}


i also got it to work, but only with certain blocks. the only blocks that wouldn't keep sending me to my homepage are the nukesentinel blocks, html newsletter block, and two nukeclassifieds blocks. all the others redirect to my main domain homepage. any thoughts?
 
Gremmie
PostPosted: Mon Sep 03, 2007 6:26 pm Reply with quote

I don't use that mod, sorry. Can you contact the mod author?
 
montego
Site Admin


Joined: Aug 29, 2004
Posts: 9455
Location: Arizona

PostPosted: Tue Sep 04, 2007 6:59 am Reply with quote

t_henson, actually, I would not place your include there. Put the following in AFTER that IF statement:

include_once(INCLUDE_PATH.'includes/nsncb_func.php');

Yours may still work, but the above one line is how the INCLUDE_PATH constant was intended to be used.

_________________
Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Visit poster's website
t_henson
PostPosted: Wed Sep 12, 2007 4:46 pm Reply with quote

thanks, montego. i tried your idea as well, but with no luck. i also noticed i couldn't access the forum administration either so i had to uninstall for now.

i think the problem is that this mod was intended to be used on PHP-Nuke 7.1 - 7.7 plus Patched 2.9+ be installed, and i am using RavenNuke v2.10.01.

i have tried to contact the mod author by going to the nsn site and filling out the contact form. that was well over a week ago and i have not heard anything back yet.

it would be really nice to get this to work, concluding i made blocks intending on using this mod.
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> Blocks

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©