Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NukeSentinel™
Author Message
southern
Client


Joined: Jan 29, 2004
Posts: 591
Location: Texas

PostPosted: Tue Dec 28, 2004 9:44 pm Reply with quote

I was looking in my error log and saw numerous instances of:

Code:


[Tue Dec 28 06:01:43 2004] [error] PHP Warning:  stristr(): Empty delimiter. in /home/-----/public_html/includes/sentinel.php on line 283
[Tue Dec 28 06:01:27 2004] [error] PHP Warning:  stristr(): Empty delimiter. in /home/-----/public_html/includes/sentinel.php on line 298


What could this mean and how do I correct it?
 
View user's profile Send private message Visit poster's website MSN Messenger ICQ Number
sixonetonoffun
Spouse Contemplates Divorce


Joined: Jan 02, 2003
Posts: 2496

PostPosted: Tue Dec 28, 2004 9:57 pm Reply with quote

NukeSentinel v2.1.3 Has Been Released! Upgrade it should fix that error message.

_________________
[b][size=5]openSUSE 11.4-x86 | Linux 2.6.37.1-1.2desktop i686 | KDE: 4.6.41>=4.7 | XFCE 4.8 | AMD Athlon(tm) XP 3000+ | MSI K7N2 Delta-L | 3GB Black Diamond DDR
| GeForce 6200@433Mhz 512MB | Xorg 1.9.3 | NVIDIA 270.30[/size:2b8 
View user's profile Send private message
BobMarion
Former Admin in Good Standing


Joined: Oct 30, 2002
Posts: 1037
Location: RedNeck Land (known as Kentucky)

PostPosted: Tue Dec 28, 2004 10:01 pm Reply with quote

These have been fixed in 2.1.3. I uped the version number by 1 due to the new protection and the numerous code corrections.

_________________
Bob Marion
Codito Ergo Sum
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Send e-mail Visit poster's website
southern
PostPosted: Tue Dec 28, 2004 10:30 pm Reply with quote

Thank you, sixone and BobM, I'll get 2.1.3 and put it on.
 
southern
PostPosted: Thu Dec 30, 2004 6:27 pm Reply with quote

OK I put on 2.1.3 and saw no more sentinel.php errors in the log until today when I saw
Code:


[Thu Dec 30 13:43:44 2004] [error] PHP Fatal error:  Cannot redeclare get_remote_port() (previously declared in /home/--------/public_html/includes/sentinel.php:371) in /home/--------/public_html/includes/sentinel.php on line 370

Could this have anything to do with the lines I put in my .htaccess to thwart the rash of sc ript kid dies we've all been seeing of late? If not how to fix it if it needs fixed? Thanks. Smile
 
BobMarion
PostPosted: Thu Dec 30, 2004 6:42 pm Reply with quote

That line is the start of the function:
Code:
function get_remote_port() {

  if (isset($_SERVER["REMOTE_PORT"])) {
    return $_SERVER["REMOTE_PORT"];
  } elseif (isset($HTTP_SERVER_VARS["REMOTE_PORT"])) {
    return $HTTP_SERVER_VARS["REMOTE_PORT"];
  } elseif (getenv("REMOTE_PORT")) {
    return getenv("REMOTE_PORT");
  } else {
    return "none";
  }
}


Line 370 is:
Code:
function get_remote_port() {


Line 371 is:
Code:
  if (isset($_SERVER["REMOTE_PORT"])) {


So I'm not sure how it's redefingin it when it is the definition of it Sad
 
PHrEEkie
Subject Matter Expert


Joined: Feb 23, 2004
Posts: 358

PostPosted: Thu Dec 30, 2004 6:44 pm Reply with quote

Sounds like an include problem guys... somehow his sentinel.php is being included twice, which is causing the redeclare problem...

PHrEEk

_________________
PHP - Breaking your legacy scripts one build at a time. 
View user's profile Send private message
sixonetonoffun
PostPosted: Thu Dec 30, 2004 6:46 pm Reply with quote

Be easy enough to change the include lines to include_once some of the forums mods might cause it to happen I would bet.
 
BobMarion
PostPosted: Thu Dec 30, 2004 7:03 pm Reply with quote

That is a great point. Change
Code:
if ($forum_admin == 1) {

    include("../../../includes/sentinel.php");
} elseif ($inside_mod == 1) {
    include("../../includes/sentinel.php");
} else {
    include("includes/sentinel.php");
}
To:
Code:
if ($forum_admin == 1) {

    include_once("../../../includes/sentinel.php");
} elseif ($inside_mod == 1) {
    include_once("../../includes/sentinel.php");
} else {
    include_once("includes/sentinel.php");
}
 
southern
PostPosted: Thu Dec 30, 2004 10:32 pm Reply with quote

I have seen only that one error in my log as opposed to numerous instances before I upgraded to 2.1.3. I have no forum modifications to speak of, it is a standard 2.0.6 forum though with the viewtopic.php patched for the highlight thing. Is it 'safe' to call sentinel.php only once? I dunno how it is getting called twice... I'll put on that change and see how it works. Meantime, I'll stand you guys to a cold one. Smile
ImageImageImage
 
manunkind
Client


Joined: Apr 26, 2004
Posts: 368
Location: Albuquerque, NM

PostPosted: Sat Jan 01, 2005 10:46 am Reply with quote

Should we all change this?
 
View user's profile Send private message Visit poster's website
sixonetonoffun
PostPosted: Sat Jan 01, 2005 11:32 am Reply with quote

Yes this is going to be the recomended install now. But if its not giving you any trouble you can leave it alone for now.
 
southern
PostPosted: Sat Jan 01, 2005 5:51 pm Reply with quote

Thanks very much. I haven't seen any more errors in my log.
 
PHrEEkie
PostPosted: Sat Jan 08, 2005 10:24 pm Reply with quote

Ok, strangely enough, a client of mine just got hit with this...

First off, the FORM image at the bottom of News articles (moderate.gif) was missing, and I got that fix from another post here.

After the image was restored, clicking on it produced the error above, Cannot redeclare get_remote_port in sentinel.php

So I applied this fix, which was changing include to include_once for the sentinel calls. Now when I click on the moderate gif, I'm getting:

Code:
Fatal error: Cannot redeclare translate() (previously declared in /home/xxxxx/public_html/language/lang-english.php:206) in /home/xxxxx/public_html/language/lang-english.php on line 206


which is the datestring translation function inside of lang-english.php. Seems there is something wrong with this moderation call somehow. I'd like to know who out there is running 7.5 with Chat's 2.8 patch and Sentinel, can login as Admin, read a News article or view a Survey and click the 'moderate' image. Can you reproduce this problem? I'd like to know if this is a bug that I need to track down and fix, or whether or not it's only on my client's filesystem.

Thanks!
PHrEEk
 
sixonetonoffun
PostPosted: Sat Jan 08, 2005 10:35 pm Reply with quote

I get that in 7.6 patched 2.8 with Nuke-Sentinel 2.1.3 as well didn't ever use that function so I never noticed it until I checked.

So its not just the one version or your clients site.
 
sixonetonoffun
PostPosted: Sat Jan 08, 2005 10:41 pm Reply with quote

Same fix works for me though there are 2 instances of
include("mainfile.php");
I changed both to
include_once("mainfile.php");
Back to rip roarin moderation on my site lol!
 
sixonetonoffun
PostPosted: Sat Jan 08, 2005 10:42 pm Reply with quote

Spose I should mention its in /modules/News/comments.php
 
PHrEEkie
PostPosted: Sat Jan 08, 2005 11:00 pm Reply with quote

That cleared up the error Six... although what does it do..? lol... When I click it, it just takes me back to the exact same News article... weird.

PHrEEk

PS, tried it on both articles with comments and without...
 
PHrEEkie
PostPosted: Sun Jan 09, 2005 1:22 am Reply with quote

nebbermind...

according to Only registered users can see links on this board! Get registered or login! this is just another FB vapor-feature. It does nothing as far as anyone knows... I tried following the logic behind the op=moderate in comments.php, but everytime my $emp is exploded into two variables, my $emp[1] always equals 0, which then bypasses the IF logic and tosses me straight to the header function and I'm returned to the original article (or Poll, since the same vapor-feature seems to be in /modules/Surveys/comments.php). Not sure what this has to do with 'moderating' or 'comments', as it appears that even if it made it through the IF logic, it only alters the score for the article. Quite bizarre... anyways, another 3 hours wasted for nuthin'! Thanks for your help Six! Cheers

PHrEEk
 
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> NukeSentinel™

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 ©