The Arcive of Official vBulletin Modifications Site.It is not a VB3 engine, just a parsed copy! |
|
#1
|
|||
|
|||
Plugin Problem
I have a plugin working fine on one vB site (running 4.1.2) and when I try implementing the same plugin on another site (4.1.4) it crashes the system with an Internal Error. Here is the actual plug-in code:
The Product is vBulletin, the Hook Location is template_register_var and the Execution Order is 5. Code:
$templater = vB_Template::create('banner_rotator'); $templatevalues['banner_rotator'] = $templater->render(); vB_Template::preRegister('header', $templatevalues); Like I said, on my vB 4.1.2 site it works fine but on the newer 4.1.4 site it crashes. I was wondering if there was something that vB updated that changes some of this code? |
#2
|
||||
|
||||
Have you tried changing the Execution Order? Do you have any other modifications that use the same hook location? Have you tried disabling your other products (or even going one-by-one) to see if it is a problem between two mods that is causing the error?
I don't see anything obviously wrong with that code you posted. |
#3
|
|||
|
|||
I tried changing the execution order to 1 and 10 and neither worked. No other mod uses that hook location, and I've tried disabling all mods as well as their plug-ins.
Is it possible something in the template that the plugin is calling at fault? (I did change the template name that's called in the plugin but that resulted in the same error.) And here is the exact error message: Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator, webmaster@[domain].com and inform them of the time the error occurred, and anything you might have done that may have caused the error. More information about this error may be available in the server error log. Additionally, a 404 Not Found error was encountered while trying to use an ErrorDocument to handle the request. Apache mod_fcgid/2.3.6 mod_auth_passthrough/2.1 mod_bwlimited/1.4 FrontPage/5.0.2.2635 Server at www.repairmanjack.com Port 80 And I did check the error log and all I get is: [Mon Jul 18 21:14:59 2011] [error] [client {IP ADDRESS}] File does not exist: /home/fpaul46/public_html/500.shtml --------------- Added [DATE]1311082958[/DATE] at [TIME]1311082958[/TIME] --------------- After some more digging this seems to be the actual error message when trying to activate the plugin: [19-Jul-2011 00:51:15] PHP Warning: chdir() [<a href='function.chdir'>function.chdir</a>]: No such file or directory (errno 2) in /home/fpaul46/public_html/forum/index.php on line 38 This is the code in index.php: Code:
chdir('./' . VB_RELATIVE_PATH); |
#4
|
||||
|
||||
Actually, the full code there is:
PHP Code:
|
#5
|
|||
|
|||
Quote:
|
#6
|
|||
|
|||
That seems strange to me - why should something in a plugin affect code in index.php, and how is it even getting there? Maybe an include() or require() is loading the wrong file or something?
Does the same thing happen if you put some totally different code in the plugin? |
#7
|
|||
|
|||
Quote:
I double checked with our host and this is what they said: From the php code the plugin introduces, the following is causing the error: $templatevalues['banner_rotator'] = $templater->render(); They asked me to double check the template code (I have) and it's the same as it is on the other site I run. |
#8
|
||||
|
||||
And what is that template code? And are you sure that template exists in that style?
And what happens if you remove line 38 from your index.php page? Then what is the error in your error_log? |
#9
|
|||
|
|||
Quote:
https://vborg.vbsupport.ru/showthread.php?t=252398 Quote:
|
#10
|
||||
|
||||
Quote:
|
Thread Tools | |
Display Modes | |
|
|
X vBulletin 3.8.12 by vBS Debug Information | |
---|---|
|
|
More Information | |
Template Usage:
Phrase Groups Available:
|
Included Files:
Hooks Called:
|