Bug Failed install 2.0.11 on vb 4.2.5

Status
Not open for further replies.

pcam

Customer
I have started a fresh install of vbulletin with 4.2.5 and have only installed dbtech addons thus far.

The error is:

Code:
Using $this when not in object context on line 11 in /var/www/domain/forums/http/dbtech/userthreads/hooks/global_start.php
#0 /var/www/domain/forums/http/admincp/global.php(245) : eval()'d code(3): require()
#1 /var/www/domain/forums/http/admincp/global.php(245): eval()
#2 /var/www/domain/forums/http/admincp/index.php(24): require_once('/var/www/domain...')
#3 /var/www/domain/forums/http/dbseo.php(504): require('/var/www/domain...')
#4 {main}


Fatal User Error: Using $this when not in object context on line 11 in ..../dbtech/userthreads/hooks/global_start.php in ..../vb/vb.php on line 286
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 6089
#2 : vbulletin_error_handler() called in  on line 
#3 : trigger_error() called in ..../vb/vb.php on line 286
#4 : vB::handleException() called in  on line 

Var Type:
[ NULL ]

Var Data:
null

This error locks up the board, so I have just reverted back to the last snapshot prior to this installation to skip it until I can find out how to proceed.

The order of installed addons


1. DragonByte Tech: SEO (Pro)2.0.39DragonByte SEO is an advanced Search Engine Optimisation tool to help increase your forum visibility on search engines.
2. DragonByte Tech: vBOptimise (Pro)2.7.1Optimises vBulletin by using cached content to reduce MySQL usage.
3. DragonByte Tech: Security (Pro)3.3.0DragonByte Security: Improve your forum's security with automated checks and alerts.
4. DragonByte Tech: Advanced Post Thanks / Like (Pro)3.6.3Advanced Post Thanks / Like lets members quickly voice their opinion on a post.
5. DragonByte Tech: Postbit Tabs (Pro)1.1.4Allows admins to easily create groups of postbit code in an organised tab format.
6. DragonByte Tech: AJAX Threads (Pro)1.1.3AJAX Threads by DragonByte Technologies: AJAX-powered automatic thread refreshing.
7. DragonByte Tech: Threadmins and Group Mods (Pro)2.0.11Threadmins and Group Moderators is a self moderation system that allows threads to be moderated by the user that created them, allows users to be assigned as moderators to a single thread and allows usergroups to be assigned as moderators to forums.

Thanks
 
I have started a fresh install of vbulletin with 4.2.5 and have only installed dbtech addons thus far.

The error is:

Code:
Using $this when not in object context on line 11 in /var/www/domain/forums/http/dbtech/userthreads/hooks/global_start.php
#0 /var/www/domain/forums/http/admincp/global.php(245) : eval()'d code(3): require()
#1 /var/www/domain/forums/http/admincp/global.php(245): eval()
#2 /var/www/domain/forums/http/admincp/index.php(24): require_once('/var/www/domain...')
#3 /var/www/domain/forums/http/dbseo.php(504): require('/var/www/domain...')
#4 {main}


Fatal User Error: Using $this when not in object context on line 11 in ..../dbtech/userthreads/hooks/global_start.php in ..../vb/vb.php on line 286
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 6089
#2 : vbulletin_error_handler() called in  on line 
#3 : trigger_error() called in ..../vb/vb.php on line 286
#4 : vB::handleException() called in  on line 

Var Type:
[ NULL ]

Var Data:
null

This error locks up the board, so I have just reverted back to the last snapshot prior to this installation to skip it until I can find out how to proceed.

The order of installed addons


1. DragonByte Tech: SEO (Pro)2.0.39DragonByte SEO is an advanced Search Engine Optimisation tool to help increase your forum visibility on search engines.
2. DragonByte Tech: vBOptimise (Pro)2.7.1Optimises vBulletin by using cached content to reduce MySQL usage.
3. DragonByte Tech: Security (Pro)3.3.0DragonByte Security: Improve your forum's security with automated checks and alerts.
4. DragonByte Tech: Advanced Post Thanks / Like (Pro)3.6.3Advanced Post Thanks / Like lets members quickly voice their opinion on a post.
5. DragonByte Tech: Postbit Tabs (Pro)1.1.4Allows admins to easily create groups of postbit code in an organised tab format.
6. DragonByte Tech: AJAX Threads (Pro)1.1.3AJAX Threads by DragonByte Technologies: AJAX-powered automatic thread refreshing.
7. DragonByte Tech: Threadmins and Group Mods (Pro)2.0.11Threadmins and Group Moderators is a self moderation system that allows threads to be moderated by the user that created them, allows users to be assigned as moderators to a single thread and allows usergroups to be assigned as moderators to forums.

Thanks

Thanks for the report pcam. What version of PHP are you using? And did you have Threadmins installed before and were updating it, or did you install it fresh?

Matt
 
PHP 7.1.6, MySQL Version 5.6.36, and this was a fresh install so the order listed above was all first installs and not any of which were upgrades.
 
We are also running the same PHP version without issue. Can you show line 11 of /var/www/domain/forums/http/dbtech/userthreads/hooks/global_start.php ?
 
I think there was some slight difference in the first package generated and downloaded from the clientarea on this site, to the second attempt I just downloaded. Either that, or some fluke happened on ftp upload with no warning or errors given by FileZilla.

Both lines have:

Code:
if (isset($this) AND is_object($this))

Thank you
 
Hmm, on trying to configure the addon I'm now getting this from any of the disclosed options on the left side of the admincp nav frame

Code:
Fatal error: Redefinition of parameter $value1 in /var/www/domain/forums/http/dbtech/userthreads/includes/adminfunctions.php on line 26

where line 26:

PHP:
function print_label_double_row($title, $value1 = ' ', $value1 = ' ', $class = '', $valign = 'top', $helpname = NULL, $dowidth = false)
 
I think there was some slight difference in the first package generated and downloaded from the clientarea on this site, to the second attempt I just downloaded. Either that, or some fluke happened on ftp upload with no warning or errors given by FileZilla.

Both lines have:

Code:
if (isset($this) AND is_object($this))

Thank you
That is working perfectly fine here @ this forum on PHP 7.1.6, I don't know why it would cause issues for you.
 
Maybe redownload the files in case something is missing?

You could add each item step by step and double check that it's not another mod causing the issue. :)
 
Maybe redownload the files in case something is missing?

You could add each item step by step and double check that it's not another mod causing the issue. :)

Could you clarify on adding step by step? I have completely restarted with a fresh vBulletin installation and the order I listed in the first post is all that I have installed. No other (non-DragonByte Tech) mods, themes or anything 3rd party has been installed. I first installed DragonByte Tech SEO, then vBOptimise and so forth.

I have tried the following:

Disable all other mods, one by one and all together, and the problem persists.

I have uninstalled threadmins and group moderators and have tried the last version generated by the Client Area here as well as the lite version from vBulletin.org. With all Pro versions, the problem persists and the lite version from vBulletin.org brought me back to the original error in my first post.

I am monitoring my web server for any errors and the screen has remained inactive for the entire debugging process. I have also monitored php-fpm and its looking fine too.

I'm unsure where to go from here. Is there anything else I can try?
 
Ok, let me walk through the steps and see if I've got this straight as to where you are.

  1. If you install each of the mods in the order you listed before, you get the error ONLY when you get to Threadmins?
  2. If you then disable all the mods you get the second problem you mentioned?
  3. Redownloading the product Pro or Lite means the issue persists?

I noticed you use FileZilla. I've had issues with FileZilla not uploading correctly in the past. Fillip H., could that be an issue?

From what I can see the code should work fine, and I've not had issues here or on my test sites with this atm. Perhaps there's something unique to your setup we're missing?

If you install Threadmins on it's own do you get any issues at all?

If the issue still persists, could you arrange to send us some FTP login details and Admin logins and I'll take a look and see what I can find. :)
 
I've looked at the code and the constructor seems to have a duplicate call

PHP:
function print_label_double_row($title, $value1 = ' ', $value1 = ' ', $class = '', $valign = 'top', $helpname = NULL, $dowidth = false)

from the .zip [DBTech] Threadmins and Group Moderators v2.0.11 [L.UTHREADS.LIFE.9951UFAOJCP].zip

After getting that out of the way, I'm back to the original problem

Code:
Using $this when not in object context on line 11 in /var/www/domain/forums/http/dbtech/userthreads/hooks/global_start.php
#0 /var/www/domain/forums/http/admincp/global.php(245) : eval()'d code(3): require()
#1 /var/www/domain/forums/http/admincp/global.php(245): eval()
#2 /var/www/domain/forums/http/admincp/index.php(24): require_once('/var/www/domain...')
#3 /var/www/domain/forums/http/dbseo.php(504): require('/var/www/domain...')
#4 {main}


Fatal User Error: Using $this when not in object context on line 11 in ..../dbtech/userthreads/hooks/global_start.php in ..../vb/vb.php on line 286
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 6089
#2 : vbulletin_error_handler() called in  on line 
#3 : trigger_error() called in ..../vb/vb.php on line 286
#4 : vB::handleException() called in  on line 

Var Type:
[ NULL ]

Var Data:
null

where line 11 in dbtech/userthreads/hooks/global_start.php contains:

PHP:
if (is_object($this))
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $this->datastore_entries);
}
else
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $specialtemplates);
}

Regarding the steps, you have it mostly right. I have been installing my fresh installation in order of mod precedence priorities descending. For me, I needed dbseo more than any other mod so I installed it first. I ran into this problem on my 7th install, right after AJAX Threads. Prior to this, no php errors or mod errors were shown anywhere. Upon the 7th installation of Threadmins and Group Mods Pro (2.0.11), I received the initial error in my first post. First I checked to make sure I wasn't seeing any php errors. I then proceeded to try to see if there were any conflicts from the prior 6 and only 6 mods installed, so I disabled them one-by-one until all were disabled and I was still seeing the problem that has persisted even after removing the duplicate constructor call.

I was thinking maybe my .zip I downloaded was corrupted, but at least the same duplicate constructor call was in the vbulletin.org lite download of 2.0.10.

I don't know if you cannot make duplicate calls in < php 7, but it seems you cannot in > php 7.

I was using FileZilla, since it was referenced in the vbulletin manual, but to see if that could be an issue I have recently used WinSCP and no luck.

Does this help?
 
I've looked at the code and the constructor seems to have a duplicate call

PHP:
function print_label_double_row($title, $value1 = ' ', $value1 = ' ', $class = '', $valign = 'top', $helpname = NULL, $dowidth = false)

from the .zip [DBTech] Threadmins and Group Moderators v2.0.11 [L.UTHREADS.LIFE.9951UFAOJCP].zip

That's good. I'll make an adjustment for the next update. Thanks for spotting that. :)

After getting that out of the way, I'm back to the original problem

Code:
Using $this when not in object context on line 11 in /var/www/domain/forums/http/dbtech/userthreads/hooks/global_start.php
#0 /var/www/domain/forums/http/admincp/global.php(245) : eval()'d code(3): require()
#1 /var/www/domain/forums/http/admincp/global.php(245): eval()
#2 /var/www/domain/forums/http/admincp/index.php(24): require_once('/var/www/domain...')
#3 /var/www/domain/forums/http/dbseo.php(504): require('/var/www/domain...')
#4 {main}


Fatal User Error: Using $this when not in object context on line 11 in ..../dbtech/userthreads/hooks/global_start.php in ..../vb/vb.php on line 286
Trace Data:
#1 : vbstop() called in ..../includes/class_core.php on line 6089
#2 : vbulletin_error_handler() called in  on line 
#3 : trigger_error() called in ..../vb/vb.php on line 286
#4 : vB::handleException() called in  on line 

Var Type:
[ NULL ]

Var Data:
null

where line 11 in dbtech/userthreads/hooks/global_start.php contains:

PHP:
if (is_object($this))
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $this->datastore_entries);
}
else
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $specialtemplates);
}

Regarding the steps, you have it mostly right. I have been installing my fresh installation in order of mod precedence priorities descending. For me, I needed dbseo more than any other mod so I installed it first. I ran into this problem on my 7th install, right after AJAX Threads. Prior to this, no php errors or mod errors were shown anywhere. Upon the 7th installation of Threadmins and Group Mods Pro (2.0.11), I received the initial error in my first post. First I checked to make sure I wasn't seeing any php errors. I then proceeded to try to see if there were any conflicts from the prior 6 and only 6 mods installed, so I disabled them one-by-one until all were disabled and I was still seeing the problem that has persisted even after removing the duplicate constructor call.

I was thinking maybe my .zip I downloaded was corrupted, but at least the same duplicate constructor call was in the vbulletin.org lite download of 2.0.10.

I don't know if you cannot make duplicate calls in < php 7, but it seems you cannot in > php 7.

I was using FileZilla, since it was referenced in the vbulletin manual, but to see if that could be an issue I have recently used WinSCP and no luck.

Does this help?

I'll have a look again and see if I can find anything.
 
where line 11 in dbtech/userthreads/hooks/global_start.php contains:

PHP:
if (is_object($this))
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $this->datastore_entries);
}
else
{
        // Loads the cache class
        USERTHREADS_CACHE::init($vbulletin, $specialtemplates);
}

I don't know if you cannot make duplicate calls in < php 7, but it seems you cannot in > php 7.

That should be an updated fix from the latest download. I've just double checked my code and the issue was patched for PHP7. I've reuploaded the file (which should be the same anyway) and if you redownload the files again from here we can see if that sorts your issue. If it does I'll fix the downloads on vb.org later. :)

I've also fixed the adminfunctions file issue.
 
Hello pcam,

This ticket has now been closed with the status Fixed.

We hope your issue or question has been addressed to your satisfaction. If not, please feel free to re-open it by clicking this link.

If you have any further issues or questions, please feel free to start a new support ticket via the button at the top of every page.

Thank you!
 
Status
Not open for further replies.

Legacy Threadmins and Group Moderators

vBulletin 4.x.x
Seller
Mokonzi
Release date
Last update
Total downloads
252
Customer rating
0.00 star(s) 0 ratings
Back
Top