11
trabis
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/7 23:36

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


Quote:

fbcarter wrote:
I uninstalled everything then uploaded again and ran chechum.php.

The only error was:

./class/mail/phpmailer/language/phpmailer.lang-fo.php content invalid

I reuploaded this file and got the same error running checksum again.


OK, you can ignore that error. Please proceed with install.

12
fbcarter
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 2:48

  • fbcarter

  • Just popping in

  • Posts: 13

  • Since: 2009/6/11


I completed the install with the same effect. admin.php generates a blank page.

I put a few echos in the source to try to track it down further. I am not an expert at php so have only got so far. The program runs through admin.php to line 33: xoops_cp_header();

in cp_functions.php it runs xoops cp_header() see snippet below.

function xoops_cp_header()
{
    
xoops_load('cpanel''system');
    
$cpanel =& XoopsSystemCpanel::getInstance();
    echo 
'1';
    
$cpanel->gui->header();
    echo 
'4';
}


I get a '1' on the screen but not a 4. I am using the default backend so it should be setting up an instance of XoopsGuiDefault But I have not been able to locate where $cpanel->gui->header(); takes the program. I have looked in both modules\system\themes\default\default.php and modules\system\class\gui.php

13
trabis
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 3:03

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


Follow the header() method on file modules\system\themes\default\default.php

Probably you will be able to spot the bug.
Do you have write permission on all cache folders(specially xoops_cache)?

14
fbcarter
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 14:29

  • fbcarter

  • Just popping in

  • Posts: 13

  • Since: 2009/6/11


In going to the header method I put in an echo:

function header()
    {
        echo 
'default.header<br>'//farley
        
parent::header();

When testing I never reached here. So I went back and looked at the calling cp_functions.php

function xoops_cp_header()
{
    
xoops_load('cpanel''system'); 
    
$cpanel =& XoopsSystemCpanel::getInstance();
    echo 
'xoops_cp_header()<br>'//farley
    
$cpanel->gui->header();
}

and traced through xoops_load and in there through loadModule('cpanel','system');

function loadModule($name$dirname null)
    {
echo 
'1.0<br>'//farley
        
if (empty($dirname)) {
echo 
'1.1<br>'//farley
            
return false;
echo 
'1.2<br>'//farley
        
}
echo 
'1.3<br>'//farley
        
if (file_exists($file XOOPS_ROOT_PATH '/modules/' $dirname '/class/' $name '.php')) {
echo 
'1.4<br>'//farley
            
include $file;
echo 
'1.5 '.ucfirst($dirname) . ucfirst($name).'<br>'//farley
            
if (class_exists(ucfirst($dirname) . ucfirst($name))) {
echo 
'1.6<br>'//farley
                
return true;
echo 
'1.7<br>'//farley
            
}
echo 
'1.8<br>'//farley
        
}
echo 
'1.9<br>'//farley
        
return false;
echo 
'1.10<br>'//farley
    
}

Now my screen looks like this:

[b]1.0
1.3
1.4
1.5 SystemCpanel
1.8
1.9

xoops_cp_header()
[/b]

Which means the class does not exist. and false is returned. I would hav expected the class to be XoopsSystemCpanel?

15
fbcarter
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 15:07

  • fbcarter

  • Just popping in

  • Posts: 13

  • Since: 2009/6/11


I have looked deeper and I have it but do not know what to do about it.

function xoops_cp_header()
{
    
xoops_load('cpanel''system'); 
    
$cpanel =& XoopsSystemCpanel::getInstance();
    echo 
'xoops_cp_header()<br>'//farley
    
$cpanel->gui->header();
}

The problem is in the XoopsSystemCpanel::getInstance()

function &getInstance()
    {
        static 
$instance;
        if (!isset(
$instance)) {
            
$class __CLASS__;
echo 
'$class.'<br>'; //farley
            $instance = new $class();
        }
        return $instance; 
    }

On my local system (working) $class = XoopsSystemCpanel
On the non working online system $class = xoopssystemcpanel

Now I just need to know how to resolve this. The thing I do not know not knowing enough about php is where __CLASS__ is coming from.

16
trabis
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 15:47

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


Well done!
Just replace $instance = new $class(); with $instance = new XoopsSystemPanel();

Thank you, I will investigate this further. What are your system specs?

17
trabis
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 15:51

  • trabis

  • Core Developer

  • Posts: 2269

  • Since: 2006/9/1 1


http://php.net/manual/en/language.constants.predefined.php

__CLASS__ : The class name. (Added in PHP 4.3.0) As of PHP 5 this constant returns the class name as it was declared (case-sensitive). In PHP 4 its value is always lowercased. The class name includes the namespace it was declared in (e.g. Foo\Bar).

Are you using php 5.2? It is required by XOOPS 2.5.x.

18
fbcarter
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 16:17

  • fbcarter

  • Just popping in

  • Posts: 13

  • Since: 2009/6/11


My system

PHP version 4.4.9
MySQL version 4.1.22-standard
Architecture i686
Operating system linux
Perl version 5.8.8

Seems the PHP version is the problem. I will see if the hosting company can udate it. Thanks for all your help.

19
Mamba
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 19:10

  • Mamba

  • Moderator

  • Posts: 11366

  • Since: 2004/4/23


Looks like we need a huge warning, if the PHP versions is lower than 5.2, similar to what we have in ModuleAdmin...

The check should be in the Installer, when it is showing what PHP version is on the system.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

20
fbcarter
Re: Installation 2.53 but Admin page is blank.
  • 2011/10/8 22:59

  • fbcarter

  • Just popping in

  • Posts: 13

  • Since: 2009/6/11


The only other thing I had to do was to add a function in modules/system/class/cpanel.php


function XoopsSystemCpanel()
    {
        
$this->__construct();
    }



so far...

Login

Who's Online

252 user(s) are online (151 user(s) are browsing Support Forums)


Members: 0


Guests: 252


more...

Donat-O-Meter

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

Latest GitHub Commits