Author |
Message |
topmug
Hangin' Around

Joined: Aug 11, 2005
Posts: 26
|
Posted:
Fri Aug 12, 2005 1:06 am |
|
Hi there
I patched my 7.4 install to 3.1 last night but one of my modules does not work at all now.
http://www.themugsclan.co.uk/modules.php?name=Server_Viewer
As you can see it just goes to a blank page, now i know you cant do much as you dont know what the module is but is there anything i can look at in the index file of the module to see if i can change to be compatible with the patch. Im assuming that is the problem!
The index.php of the file can be found
Only registered users can see links on this board! Get registered or login!
can anyone see what is wrong
Thanks
Top |
|
|
|
 |
Guardian2003
Site Admin

Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam
|
Posted:
Fri Aug 12, 2005 3:01 am |
|
You may need to post a link to that file as a text document, nuke prevents you from accessing that file directly - you might also want to take a look at the post below this one. |
|
|
|
 |
topmug

|
Posted:
Fri Aug 12, 2005 4:48 am |
|
okay the new index file in txt format can be found Only registered users can see links on this board! Get registered or login!
Thanks |
|
|
|
 |
Guardian2003

|
Posted:
Fri Aug 12, 2005 6:52 am |
|
Hmm, I dont see anything obvious but I'm no expert.
This may sound silly but I just had a similar type of problem on another module I'm using....
about the sixth line of code down comment out Code:get_lang($module_name);
| like this Code:// get_lang($module_name);
|
Tell me if the page loads. |
|
|
|
 |
chatserv
Member Emeritus

Joined: May 02, 2003
Posts: 1389
Location: Puerto Rico
|
Posted:
Fri Aug 12, 2005 7:53 am |
|
Code:<?php
/************************************************************************/
/* OFxServerViewer v2.13 - An addon module for PHP-Nuke */
/* ===================== */
/* PHP-Nuke OFxServerViewer Module for PHP-Nuke v5.6+ */
/* By Gregory "OFxLedzeplin" Jones OFxLedzeplin@OFxClan.com */
/* http://www.ofxgamer.com */
/* */
/* Primary INDEX file: /modules/Server_Viewer/index.php */
/* */
/* Use as you wish, please add these sites to your weblinks - PEACE */
/* www.OFxGamer.com - www.OFxClan.com - www.OFxGaming.com */
/************************************************************************/
/* This program is free software. You can redistribute it and/or modify */
/* it under the terms of the GNU General Public License as published by */
/* the Free Software Foundation; either version 2 or a newer version. */
/************************************************************************/
if ( !defined('MODULE_FILE') )
{
die("You can't access this file directly...");
}
if ( !defined('NUKE_FILE') ) {
require_once("mainfile.php");
}
$module_name = basename(dirname(__FILE__));
get_lang($module_name);
global $prefix, $db, $gametype, $gameip, $gameport, $svrname;
$sql = "select sv_index from ".$prefix."_ofxviewer_config where ofxid='1'";
$result = $db->sql_query($sql);
if ( !$result ) {
echo "OFx Server Viewer data not available<br>";
echo "OFx Server Viewer v2.13<br>";
echo "Click <a href=\"modules.php?name=$module_name&file=ofxinstall&func=install\">HERE</a> to install initial data.";
die();
}
$sv = $db->sql_fetchrow($result);
$sv_index = $sv[sv_index];
$sql = "select sv_underline from ".$prefix."_ofxviewer_config where ofxid='1'";
$result = $db->sql_query($sql);
if ( !$result ) {
echo "OFx Server Viewer data requires updating.<br>";
echo "<br>";
echo "OFx Server Viewer v2.13<br>";
echo "This script will update your data<br>";
echo "Click <a href=\"modules.php?name=$module_name&file=ofxinstall&func=upgrade\">HERE</a> to upgrade data.";
die();
}
$sql = "select sv_pluginurl from ".$prefix."_ofxviewer_config where ofxid='1'";
$result = $db->sql_query($sql);
if ( !$result ) {
echo "OFx Server Viewer data requires updating.<br>";
echo "<br>";
echo "OFx Server Viewer v2.13<br>";
echo "This script will update your data<br>";
echo "Click <a href=\"modules.php?name=$module_name&file=ofxinstall&func=upgrade210a\">HERE</a> to upgrade data.";
die();
}
$sql = "select sv_plugin from ".$prefix."_ofxviewer_config where ofxid='1'";
$result = $db->sql_query($sql);
if ( !$result ) {
echo "OFx Server Viewer data requires updating.<br>";
echo "<br>";
echo "OFx Server Viewer v2.13<br>";
echo "This script will update your data<br>";
echo "Click <a href=\"modules.php?name=$module_name&file=ofxinstall&func=upgrade212\">HERE</a> to upgrade data.";
die();
}
if (($sv_index != 1) and ($sv_index != 0)) {
$sv_index = 1;
}
$index = $sv_index;
echo "<html><head><title>Servers</title>\n";
echo "<style type=\"text/css\">\n";
echo " a{text-decoration:none}\n";
echo "</style>\n";
echo "</head>\n";
include("header.php");
include("modules/$module_name/srvwin.php");
include("footer.php");
?>
|
|
|
|
|
 |
topmug

|
Posted:
Fri Aug 12, 2005 9:02 am |
|
Okay i tried both of your codes but neither worked im afraid! |
|
|
|
 |
chatserv

|
Posted:
Fri Aug 12, 2005 9:51 am |
|
Enable display_errors in config.php to see if the file returns any errors. |
|
|
|
 |
topmug

|
Posted:
Fri Aug 12, 2005 11:18 am |
|
Fatal error: Cannot redeclare stripos_clone() (previously declared in /home/chelsea/public_html/mainfile.php:123) in /home/chelsea/public_html/mainfile.php on line 123 |
|
|
|
 |
topmug

|
Posted:
Mon Aug 15, 2005 1:51 am |
|
Sorry to bump this but has anyone got any ideas?
Thx |
|
|
|
 |
Guardian2003

|
Posted:
Mon Aug 15, 2005 4:54 am |
|
Which page are you viewing when this error message is generated?
The cure may be simply to alter some of the code to
Code:if (!function_exists('stripos_clone')) {
function stripos_clone(whatever)
{
|
But we need to determine WHERE the second instance of the $stripos_clone() function is being called unless we alter mainfile.php itself which, not being a coder I'm reluctant to recommend without feedback from 'the professionals'.
If the error message is being generated on the sites main page, then we need to look at any files that have been 'included' in mainfile.php to determine if it is one of those 'included' files which is carrying the second or subsequent instance of the function. |
|
|
|
 |
topmug

|
Posted:
Mon Aug 15, 2005 8:15 am |
|
im viewing the server viewer page when the error pops up! |
|
|
|
 |
Guardian2003

|
Posted:
Mon Aug 15, 2005 9:12 am |
|
Perhaps the more knowledable people here can offer a better solution but for now;
do a search on mainfile for 'stripos_clone' (without the quotes) my mainfile.php is heavily modded so cannot give you an exact lin number but mines around line 12227
FindCode:function stripos_clone($haystack, $needle, $offset=0) {
return strpos(strtoupper($haystack), strtoupper($needle), $offset);
}
|
replace with
Code:if (!function_exists('stripos_clone')) {
function stripos_clone($haystack, $needle, $offset=0) {
return strpos(strtoupper($haystack), strtoupper($needle), $offset);
}
}
|
|
|
|
|
 |
topmug

|
Posted:
Mon Aug 15, 2005 11:52 am |
|
Thanks for the try mate, but still no difference.
Cheers |
|
|
|
 |
Guardian2003

|
Posted:
Mon Aug 15, 2005 11:19 pm |
|
In that case the function is being called more than once outside of mainfile.php, you will need to check the files in your module, if that is the only page that is causing the error.
Looking at the code above that Chatserv posted, we can see near the bottom that three other files have been called to be included the your file is accessed.
These are header.php, footer.php and the svrwin.php file. I'm prety sure than neither header or footer.php contain this function so it might be wise to check the svrwin.php file
Other than that, I am at a loss. |
|
|
|
 |
topmug

|
Posted:
Tue Aug 16, 2005 1:25 am |
|
umm, i looked in the file but there is nothing there aswell. Only registered users can see links on this board! Get registered or login! is the file if you want to have a look. Thanks for all the help your putting in, all my members are desperate for this file and i thank you from them.
Thx |
|
|
|
 |
Guardian2003

|
Posted:
Tue Aug 16, 2005 9:02 am |
|
OK I have run out of ideas for this one.
If you have the full module including the database SQL file, can you zip it and email it to me please. I'll try an install myself to see if I can resolve the issue. |
|
|
|
 |
topmug

|
Posted:
Tue Aug 23, 2005 8:20 am |
|
Just to let you know that the coppermine gallery i have on the site doesnt work either (blank screen) |
|
|
|
 |
Ga8or
New Member


Joined: Dec 13, 2005
Posts: 5
|
Posted:
Tue Jan 10, 2006 8:05 pm |
|
I get these errors after upgrading to 3.1 patched. Any idea? I also get the blank screen.
Warning: graphicadmin(admin/links/links.serverviewer.php): failed to open stream: Permission denied in C:\Inetpub\vhosts\GAMESHANTY.COM\httpdocs\admin.php on line 308
Warning: graphicadmin(): Failed opening 'admin/links/links.serverviewer.php' for inclusion (include_path='.;./includes;./pear') in C:\Inetpub\vhosts\GAMESHANTY.COM\httpdocs\admin.php on line 308 |
|
|
|
 |
|