Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> phpnuke 6.9
Author Message
Raven
Site Admin/Owner



Joined: Aug 27, 2002
Posts: 17088

PostPosted: Sat Mar 20, 2004 8:55 am Reply with quote

I still bet it's the variable name duplicity - somewhere. The problem is trying to trace all the INCLUDES. Just as a test, try reversing the ORDER they load in.
 
View user's profile Send private message
TheosEleos
Life Cycles Becoming CPU Cycles



Joined: Sep 18, 2003
Posts: 960
Location: Missouri

PostPosted: Sat Mar 20, 2004 10:55 am Reply with quote

I don't know how to do that.
Embarassed

_________________
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Visit poster's website AIM Address ICQ Number
Raven







PostPosted: Sat Mar 20, 2004 10:57 am Reply with quote

In your blocks admin adjust the Weight column to reverse the position order.
 
TheosEleos







PostPosted: Sat Mar 20, 2004 11:13 am Reply with quote

I would try to do that but now when I go to my admin page I get this.

Quote:
You can't access this file directly...


I don't know what I could have done to cause that. The only thing I am working on is this one issue.
 
Raven







PostPosted: Sat Mar 20, 2004 11:45 am Reply with quote

Try this. Use phpmyadmin and edit the nuke_blocks table. Find the coppermine block and set the Active column to 0 (zero). Can you access the admin now?
 
TheosEleos







PostPosted: Sat Mar 20, 2004 11:46 am Reply with quote

I had to go to my databse and turn off the coppermine block.

I bet the user changes I made to that include file did it to me.
 
TheosEleos







PostPosted: Sat Mar 20, 2004 11:46 am Reply with quote

That was cute. We posted together.
 
Raven







PostPosted: Sat Mar 20, 2004 11:47 am Reply with quote

TheosEleos wrote:
I had to go to my databse and turn off the coppermine block.

I bet the user changes I made to that include file did it to me.
Probably. Just restore it.
 
TheosEleos







PostPosted: Sat Mar 20, 2004 11:56 am Reply with quote

I had to restore the coppermine block.

This may not be worth our time. It's not your fault coppermine has poor block programing.
 
TheosEleos







PostPosted: Sat Mar 20, 2004 12:01 pm Reply with quote

I changed the $name to $cpg_name variable in that include file and I can now access the admin page.

I will mess with the blocks weight but if you want to bail on this I understand.
 
Raven







PostPosted: Sat Mar 20, 2004 12:01 pm Reply with quote

Well, it's a conflict between 2 blocks where there is no standard for programming blocks. My info block is simply an enhancement/expansion to the standard userInfo block that comes with nuke. I can't spend anymore time on this right now though.
 
TheosEleos







PostPosted: Sat Mar 20, 2004 12:05 pm Reply with quote

I completely understand. I don't want to either. lol
 
TheosEleos







PostPosted: Tue Mar 23, 2004 4:50 pm Reply with quote

Guess what? It was the load order. I had to move the block to the right and put it below your block. Is there a way to get the blocks on the right to load before the block on the left in block admin?
 
Raven







PostPosted: Tue Mar 23, 2004 5:01 pm Reply with quote

Raven wrote:
I still bet it's the variable name duplicity - somewhere. The problem is trying to trace all the INCLUDES. Just as a test, try reversing the ORDER they load in.
Well, my post from the 20th was pretty close, eh?
 
TheosEleos







PostPosted: Tue Mar 23, 2004 5:16 pm Reply with quote

Yup, and I got an interesting response from one of them at nukecops. Very Happy

http://nukecops.com/modules.php?name=Forums&file=viewtopic&p=112376#112376
 
Raven







PostPosted: Tue Mar 23, 2004 6:23 pm Reply with quote

Hmmmm. DJM is wrong on at least 2 points right off the bat. His statement
Code:
A array must be accessed like: $row['username'] NOT $row[username]
is incorrect. Sloppy coding maybe, but it works either way. And his statement
Code:
A. The $sql is incorrect should be:Code: 

$sql = "SELECT username FROM ".$user_prefix."_users ORDER BY user_id DESC LIMIT 1";
is totally wrong. This is right from the MySQL site and manual ( http://www.mysql.com/doc/en/SELECT.html )
Code:
In other words, LIMIT n is equivalent to LIMIT 0,n.
 
TheosEleos







PostPosted: Tue Mar 23, 2004 8:42 pm Reply with quote

I don't know what to do. I did post a response. I find their support on this issue to be pathetic.
 
GanjaUK
Life Cycles Becoming CPU Cycles



Joined: Feb 14, 2004
Posts: 633
Location: England

PostPosted: Tue Mar 23, 2004 8:55 pm Reply with quote

I have this problem too. I searched high and low, and like you said earlier, all they did is make a new user info block which is really poor. Seems to only happen when I have the blocks in the center which is where I need them.
It really annoyed me because I spent ages customizing the coppermine block only to find it conflicts with the user info block, in the end I just had to give up and not use the coppermine blocks at all.
 
View user's profile Send private message Visit poster's website
TheosEleos







PostPosted: Tue Mar 23, 2004 9:03 pm Reply with quote

If you make the coppermine block load after the user info block things work just fine.

Here is the site I am working on.

www.phenylshouse.com

I want the CPG block on the left side but if I do that it loads before the user info block and that issue is there.

As you can see I moved the CPG block to the right and now it loads after the user info block and things work.
 
TheosEleos







PostPosted: Tue Mar 23, 2004 9:06 pm Reply with quote

One thing is for sure.

I am not giving up Raven's info block!

I am going to figure out how to get the blocks on the right to load before the blocks on the left, if it can be done.
 
Raven







PostPosted: Tue Mar 23, 2004 9:49 pm Reply with quote

I've never looked into this but my guess would be in the blocks function in mainfile.php. At least I would start there.
 
TheosEleos







PostPosted: Wed Mar 24, 2004 5:29 am Reply with quote

Code:
function render_blocks($side, $blockfile, $title, $content, $bid, $url) {

    if ($url == "") {
   if ($blockfile == "") {
       if ($side == "c") {
      themecenterbox($title, $content);
       } elseif ($side == "d") {
      themecenterbox($title, $content);
       } else {
      themesidebox($title, $content);
       }
   } else {
       if ($side == "c") {
      blockfileinc($title, $blockfile, 1);
       } elseif ($side == "d") {
      blockfileinc($title, $blockfile, 1);
       } else {
      blockfileinc($title, $blockfile);
       }
   }
    } else {
   if ($side == "c" OR $side == "d") {
       headlines($bid,1);
   } else {
           headlines($bid);
   }
    }
}

function blocks($side) {
    global $storynum, $prefix, $multilingual, $currentlang, $db, $admin, $user;
    if ($multilingual == 1) {
       $querylang = "AND (blanguage='$currentlang' OR blanguage='')";
    } else {
       $querylang = "";
    }
    if (strtolower($side[0]) == "r") {
   $pos = "r";
    } elseif (strtolower($side[0]) == "l") {
   $pos = "l";
    }  elseif (strtolower($side[0]) == "c") {
   $pos = "c";
    } elseif  (strtolower($side[0]) == "d") {
   $pos = "d";
    }
    $side = $pos;
    $sql = "SELECT bid, bkey, title, content, url, blockfile, view FROM ".$prefix."_blocks WHERE bposition='$pos' AND active='1' $querylang ORDER BY weight ASC";
    $result = $db->sql_query($sql);
    while($row = $db->sql_fetchrow($result)) {
   $bid = $row[bid];
   $title = $row[title];
   $content = $row[content];
   $url = $row[url];
   $blockfile = $row[blockfile];
   $view = $row[view];
   if ($row[bkey] == admin) {
       adminblock();
   } elseif ($row[bkey] == userbox) {
       userblock();
   } elseif ($row[bkey] == "") {
       if ($view == 0) {
      render_blocks($side, $blockfile, $title, $content, $bid, $url);
       } elseif ($view == 1 AND is_user($user) || is_admin($admin)) {
      render_blocks($side, $blockfile, $title, $content, $bid, $url);
       } elseif ($view == 2 AND is_admin($admin)) {
      render_blocks($side, $blockfile, $title, $content, $bid, $url);
       } elseif ($view == 3 AND !is_user($user) || is_admin($admin)) {
      render_blocks($side, $blockfile, $title, $content, $bid, $url);
       }
   }
    }
}


I only found one place that used "L" or "R" and tried switched those but no change. Anything stand out to you?
 
Raven







PostPosted: Wed Mar 24, 2004 5:34 am Reply with quote

Try looking in your theme.php file and specifically at "function themeheader()". The "blocks(left)" call is where/when the left side is built.
 
GanjaUK







PostPosted: Wed Mar 24, 2004 7:29 am Reply with quote

TheosEleos, this was irritating the hell out of me too, so I tried some different things. Anyway, this seems to be the easiest solution all round.

Open your User Info block and find:
Code:
$lastuser = $row[username];

Change that to
Code:
$lastuser = $row['username'];


Latest member now shows again.


Last edited by GanjaUK on Wed Mar 24, 2004 7:40 am; edited 1 time in total 
Raven







PostPosted: Wed Mar 24, 2004 7:31 am Reply with quote

According to DJM that should clear it up. We just had an exchange at NC. I would recommend single tick marks though, not double.
 
Display posts from previous:       
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Ravens PHP Scripts And Web Hosting Forum Index -> phpnuke 6.9

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 ©