xoops forums

Mamba

Moderator
Posted on: 2016/4/26 6:17
Mamba
Mamba (Show more)
Moderator
Posts: 10770
Since: 2004/4/23
#31

Re: animal pedigree database, problems moving to new server

Quote:
After making changes to the module I couldn't view the site and got an error of:
Error: Call to a member function dirname() on null
- Hope that's useful.

Yes, but please also include the line and the file name, where it happened. If you didn't do it yet, go to Admin/preferences/ and set the debug on. The errors will be visible only to the admin.

Quote:
I'll mark the repository in your link now as the definitive repository?

No, this is more or less "my experimental" version.

Once is tested and I feel comfortable with the results, it will be added the the "definitive repository", which for XOOPS 2.5.x is:

https://github.com/XoopsModules25x/

and the pedigree module is then in:

https://github.com/XoopsModules25x/pedigree

But everybody is welcome to check out the versions in my repository to see where it is going, and of course, to help!

Quote:
I am so glad to see the progress not just on this module but Xoops too. Thanks again. Much appreciated.

Yes, thanks to the hard work of Richard (aka Geekwright), things are starting to come together, and most importantly, the migration to XOOPS 2.6.0 is getting more consistent and easier, thanks to his work on XMF.

Also, thank you so much for your donation!!! Very much appreciated!!!!
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

ccpedigree

Just popping in
Posted on: 2016/4/26 10:28
ccpedigree
ccpedigree (Show more)
Just popping in
Posts: 9
Since: 2016/3/31
#32

Re: animal pedigree database, problems moving to new server

Thanks, changed the queries on our version (1.30) and works ok now.

Not ready for testing the latest module yet, since this is a production site with more than 52000 dogs entered.

Bleekk

Theme Designer
Posted on: 2016/4/26 10:30
Bleekk
Bleekk (Show more)
Theme Designer
Posts: 934
Since: 2002/12/14
#33

Re: animal pedigree database, problems moving to new server

you should never test anything on your production site. not even the final modules.
make a copy of your website and test it localy.

Mamba

Moderator
Posted on: 2016/4/26 19:00
Mamba
Mamba (Show more)
Moderator
Posts: 10770
Since: 2004/4/23
#34

Re: animal pedigree database, problems moving to new server

Quote:
you should never test anything on your production site. not even the final modules.
make a copy of your website and test it locally.

Yes, it's never enough to stress it!!!!

1) Always test it first on a non-production site,

2) always make a backup before any updates on your production site, even if the tests on the test site were positive!
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

supergran

Friend of XOOPS
Posted on: 2016/4/27 23:56
supergran
supergran (Show more)
Friend of XOOPS
Posts: 25
Since: 2011/6/6 1
#35

Re: animal pedigree database, problems moving to new server

Thank you for your patience! I'm beginning to get my head around the process now at least
I'll keep the latest module and 2.5.7 as my main development site and check out developments on a separate version.

The blank page seems to be caused as I have the module set as my main page as I used to on my site. The module's index.php references a non existent file? - class/animal.php at line 49:
The same file is referenced by common.php and result.php. I then get an undefined class error for PedigreeAnimal presumably because it hasn't been loaded in header.php.

I guess the crux is that I'm using different xoops template /block / permission/ theme configurations with the module that haven't been tried out since some of the rewrites.

Jan

Mamba

Moderator
Posted on: 2016/4/28 5:51
Mamba
Mamba (Show more)
Moderator
Posts: 10770
Since: 2004/4/23
#36

Re: animal pedigree database, problems moving to new server

I hope, to have some more time this weekend and do some more work on the Pedigree module.
Support XOOPS => DONATE
Use 2.5.10 | Docs | Modules | Bugs

supergran

Friend of XOOPS
Posted on: 2016/4/29 23:03
supergran
supergran (Show more)
Friend of XOOPS
Posts: 25
Since: 2011/6/6 1
#37

Re: animal pedigree database, problems moving to new server

Thank you

Bleekk

Theme Designer
Posted on: 2016/4/30 10:01
Bleekk
Bleekk (Show more)
Theme Designer
Posts: 934
Since: 2002/12/14
#38

Re: animal pedigree database, problems moving to new server

Can you please provide your Themen and Screenshots of all your settings

supergran

Friend of XOOPS
Posted on: 2016/5/7 1:11
supergran
supergran (Show more)
Friend of XOOPS
Posts: 25
Since: 2011/6/6 1
#39

Re: animal pedigree database, problems moving to new server

Hi, thank you.
I've tried a number of settings so thought I'd try from scratch to try and be more methodical about it. Default theme and the main issue I have occurs on both PHP 5.6.1.3 and 7. I'm using Xoops RC 2.5.8 as that will probably be live when I launch.
I hit an error as soon as I change anything in blocks. Moving the pedigree menu block, changing access permissions for the block etc result in a white page with the
Error: Error: Call to a member function dirname() on null in file /modules/pedigree/include/config.php line 27
Reversing the changes in admin makes no difference once that original change has been made I cannot access the front page of the site. I can access admin and view the pedigree module via a direct path to it. I can also deactivate the pedigree module and this restores front page access to xoops. Setting the pedigree module as my start module has the same effect. I used to do this and the welcome page would show as default content on the pedigree home page.
The error relates to this blockin the php:
global $xoopsModule; if (!defined('PEDIGREE_DIRNAME')) { define("PEDIGREE_DIRNAME"$xoopsModule->dirname()); define("PEDIGREE_PATH"XOOPS_ROOT_PATH "/modules/" PEDIGREE_DIRNAME); define("PEDIGREE_URL"XOOPS_URL "/modules/" PEDIGREE_DIRNAME); define("PEDIGREE_ADMIN"PEDIGREE_URL "/admin/index.php"); }


Jan

zyspec

Module Developer
Posted on: 2016/5/8 14:53
zyspec
zyspec (Show more)
Module Developer
Posts: 1042
Since: 2004/9/21
#40

Re: animal pedigree database, problems moving to new server

supergran,

Replace this line in ./include/config.php:

define('PEDIGREE_DIRNAME'$GLOBALS['xoopsModule']->dirname());


with:

define('PEDIGREE_DIRNAME'basename(dirname(__DIR__)));


This should fix the error you're seeing.