vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vB3 General Discussions (https://vborg.vbsupport.ru/forumdisplay.php?f=111)
-   -   Unfamiliar PHP Error Message (https://vborg.vbsupport.ru/showthread.php?t=305907)

Digital Jedi 12-15-2013 05:19 PM

Unfamiliar PHP Error Message
 
http://www.cogonline.net/forums/prof...ditattachments
http://www.cogonline.net/forums/misc.php?do=bbcode

Code:

Fatal error: Cannot use assign-op operators with overloaded objects nor string offsets in...
I am going to go through my mods one by one, as it does go away if I disable the plugin system. I'm just unfamiliar with this particular PHP error, and am not sure where best to look first. Looking at Stack Overflow isn't really clarifying this one for me.

ozzy47 12-15-2013 05:22 PM

Looks like it has something to do with the smiles.

Digital Jedi 12-15-2013 05:33 PM

Even when viewing my attachments list?

ozzy47 12-15-2013 05:40 PM

If there is a bbcode in it, from what I can tell.

Digital Jedi 12-15-2013 06:07 PM

Quote:

Originally Posted by ozzy47 (Post 2468466)
If there is a bbcode in it, from what I can tell.

Maybe I've just been at this for too many days in a row, but why would their be BB Code in my attachments list, exactly? :confused:

ozzy47 12-15-2013 06:11 PM

I do not know, I am just surmising on what I have read about that error, http://www.vbulletin.com/forum/forum...ow-fatal-error

--------------- Added [DATE]1387135292[/DATE] at [TIME]1387135292[/TIME] ---------------

Actually now that I think about it, I am looking at code for vB4. :(

What is the code in your misc.php file around line 482?

Digital Jedi 12-15-2013 06:29 PM

I was just looking at that. For profile.php its:
PHP Code:

eval('$template[\'attachmentlistbits\'] .= "' fetch_template('modifyattachmentsbit') . '";'); 

And for misc.php it's:
PHP Code:

eval('$template[\'bbcodebits\'] .= "' fetch_template('help_bbcodes_bbcode') . '";'); 


ozzy47 12-15-2013 06:31 PM

Then I would have to guess it has something to do with the help for the bbcodes.

kh99 12-15-2013 06:58 PM

My guess is that one of your plugins is using $template as a string, so it's interfering with some vb code that uses it as an array. If you don't know which one, you might want to try my "search in plugins" mod to find it.

Digital Jedi 12-15-2013 08:09 PM

Well, after going through all products and disabling one by one (or five by five, rather) nothing seemed to stop the error. Yet disabling hooks does. Thanks for the search plugin mod. I haven't found anything yet, but I'll keep looking.

kh99 12-15-2013 08:13 PM

Hmm...well, I guess one possibility is that the "search plugins" mod wouldn't find it if the problem code is in an included file. And if the code is in more than one plugin (or included by more than one) then you might not find it by disabling plugins one by one (or five by five). (Edit:...oh, unless you ultimately disabled them all, then I guess it should have gone away at some point).

Of course it could also just be that I'm wrong.

BirdOPrey5 12-15-2013 09:17 PM

For http://www.cogonline.net/forums/misc.php?do=bbcode

It is definitely from a plugin om the help_bbcodes_bbcode hook.

That isn't a very commonly used hook in mods in my experience- see how many plugins you have on that hook, I would be surprised if it is more than 1.

If it is one, the problem is one line 24 of that plugin.

Digital Jedi 12-15-2013 10:01 PM

Quote:

Originally Posted by kh99 (Post 2468491)
Hmm...well, I guess one possibility is that the "search plugins" mod wouldn't find it if the problem code is in an included file. And if the code is in more than one plugin (or included by more than one) then you might not find it by disabling plugins one by one (or five by five). (Edit:...oh, unless you ultimately disabled them all, then I guess it should have gone away at some point).

Of course it could also just be that I'm wrong.

Yup, disabling hooks clears the problem just fine. Either manually or in the Admin CP. Disabling whole groups of products doesn't seem to do the trick, though. I can only assume its what's technically referred to as one of those weird thingys.

Quote:

Originally Posted by BirdOPrey5 (Post 2468509)
For http://www.cogonline.net/forums/misc.php?do=bbcode

It is definitely from a plugin om the help_bbcodes_bbcode hook.

That isn't a very commonly used hook in mods in my experience- see how many plugins you have on that hook, I would be surprised if it is more than 1.

If it is one, the problem is one line 24 of that plugin.

Could not find a plugin that used that hook. In fact, only found one that even referenced a BB Code function at all, and it's been disabled for a while now. EDIT: Correction. I should do a search for "bbcode", as well as "bbcodes". [sigh] BRB

kh99 12-15-2013 10:04 PM

Quote:

Originally Posted by Digital Jedi (Post 2468512)
Yup, disabling hooks clears the problem just fine. Either manually or in the Admin CP. Disabling whole groups of products doesn't seem to do the trick, though. I can only assume its what's technically referred to as one of those weird thingys.


Did you try the plugin manager? Maybe it's a plugin that has the product set to "vbulletin" or something like that, so it's not disabled by disabling any product.

Digital Jedi 12-15-2013 10:14 PM

Just tried that now on your suggestion, but none of those either. I'll just have to keep digging.

BirdOPrey5 12-16-2013 12:16 AM

<span style="text-decoration: line-through">You went to the plugin manager in Admin CP (plugin not product), hit CTRL+F on the keyboard to bring up "Find on Page" in your browser, and pasted in:

help_bbcodes_bbcode

And it didn't find anything? That is virtually impossible with the error message you are getting- so much so i'd ask are you sure you are in the right admincp?</span>

Misread the code.

Digital Jedi 12-16-2013 01:39 AM

Actually, I was using kh99's modification to search the plugins for the template name. But, no, nothing is using that hook, either. I don't know what to tell ya. :)

kh99 12-16-2013 10:27 AM

Well, the lines posted in post #7 seem to show that the problem is with template eval lines and not a hook. Also if the problem were in one of the misc_bbcode hooks, it wouldn't happen in profile.php. But they both use a $template array, so I still think that's your issue. I can reproduce the problem by creating a plugin using hook parse_templates and code:
Code:

$template = "test";

So maybe if you created a plugin using hook misc_bbcode_start and code like this:
PHP Code:

if (gettype($template) == 'string')
{
   die (
'$template='.$template);



Then go to the bbcode page, it might give you a clue about where it's being used (or if you never see that message, then I really am wrong).

Digital Jedi 12-16-2013 11:58 AM

Quote:

Originally Posted by kh99 (Post 2468632)
Well, the lines posted in post #7 seem to show that the problem is with template eval lines and not a hook. Also if the problem were in one of the misc_bbcode hooks, it wouldn't happen in profile.php. But they both use a $template array, so I still think that's your issue. I can reproduce the problem by creating a plugin using hook parse_templates and code:
Code:

$template = "test";

So maybe if you created a plugin using hook misc_bbcode_start and code like this:
PHP Code:

if (gettype($template) == 'string')
{
   die (
'$template='.$template);



Then go to the bbcode page, it might give you a clue about where it's being used (or if you never see that message, then I really am wrong).

You know, the very first thing I tried was turning all of my custom products/plugins off, even going so far as to delete some of them for re-import later, and that never worked. It was, in fact, one of the first ones I had worked on, which was using $template as a variable on parse_templates. Sheesh. I don't know how I could have missed that. Thanks for that. I guess I've just been in my Admin CP too long the last couple of weeks.


All times are GMT. The time now is 07:17 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01160 seconds
  • Memory Usage 1,769KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (3)bbcode_code_printable
  • (4)bbcode_php_printable
  • (5)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (19)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete