I just installed a completely fresh version of Drupal 6.20. The first thing I did was add the views module and enabled it in the administer panel.

As soon as I hit "apply changes", my whole page crashes, and all I can see is this error message:

Fatal error: Declaration of views_plugin_localization::init() must be compatible with that of views_plugin::init() in /homez.395/badbeats/www/sites/all/modules/views/plugins/views_plugin_localization.inc on line 156

Notice: Trying to get property of non-object in /homez.395/badbeats/www/modules/dblog/dblog.module on line 138

After this shows up, I cannot do anything on the website - neither access the admin panel, nor any other option. I need to remove the "Views" directory from my server to get things working again.

I've tried this on 2 fresh installations of Drupal, with the same result.

Please keep in mind that I didn't have this problem with my previous Drupal version (6.16) a few days ago.

CommentFileSizeAuthor
#12 1001304-notice-plugins-init.patch578 bytesdawehner
#4 error2.JPG76.8 KBggskygg
#3 error.JPG131.36 KBggskygg

Comments

dawehner’s picture

Views 2.12 doesn't provide the localization plugin. Are you using views3?

bojanz’s picture

Status: Active » Postponed (maintainer needs more info)
ggskygg’s picture

StatusFileSize
new131.36 KB

I think you might have been right; I removed Views and downloaded Views again, this time making sure it is version 2.12. However, I'm still having a similar problem, only this time it appears after after I provide the name/description/tag/view type and hit Next. This time the error reads:

Fatal error: Declaration of views_plugin_style_default::options() must be compatible with that of views_object::options() in /homez.395/badbeats/www/sites/all/modules/views/plugins/views_plugin_style_default.inc on line 25

Notice: Trying to get property of non-object in /homez.395/badbeats/www/modules/dblog/dblog.module on line 138.

If this helps: I'm also getting another error message, which appears as soon as I click "Views" in Admin/Site building:

"strict warning: Non-static method view::load() should not be called statically in /homez.395/badbeats/www/sites/all/modules/views/views.module on line 879."

I've attached a screenshot of the second error.

I've tried installing a completely fresh version of Drupal (6.20, 6.19 and 6.18) and each time I had the exact same effect with Views.

Thanks for your help.

ggskygg’s picture

StatusFileSize
new76.8 KB

Perhaps this will be of help as well:

At the bottom of the page, there is an error that is displayed constantly on every subpage on my website. This error appears when I'm logged off from the admin account, as well. The error reads:

Notice: Trying to get property of non-object in /homez.395/badbeats/www/modules/dblog/dblog.module on line 138

I've attached a screenshot of that, as well.

bojanz’s picture

Status: Postponed (maintainer needs more info) » Active
ggskygg’s picture

Update:

I have resolved the issue. It seems that the problem was caused by me activating php 6.0 throug .htaccess. I had no idea that Drupal did not support it. I downgraded php to 4.4.9 and everything is back to normal. So the problem was not with Views, but with my server settings.

I am very sorry for the trouble, please accept my apologies.

bojanz’s picture

Wait, what?

There is no PHP 6.0
And PHP 4.4.9 is only supported in Drupal 6, and dying fast.

If you mean PHP 5.3, it should work without a problem, but we're very interested in fixing any remaining bugs.

ggskygg’s picture

Sorry, as you can probably tell I'm not very acquainted with all this.

When I ran a php check, it said "6.0" both in the Drupal status report as well as in my server settings. This was enforced by some command that was in my .httaccess file, it looked smoething like this:

SetEnv PHP_VER 6 (i'm writing from memory so I can't be certain).

It was probably a part of some larger code I pasted in .htaccess when I was looking for a solution to a different problem that I had - that is the price I pay for not understanding what I was copy/pasting :)

After I removed this line, my php (according to status report) is now 4.4.9, and everything is working perfectly.

is there anyway I can help you further in determining what might have been the problem? Anything you would like me to check for you that might help you?

EDIT: I've just used the .httaccess file and set my php to 5.2.14. All is still perfect.

bojanz’s picture

Status: Active » Fixed

Okay, good to know.

merlinofchaos’s picture

Status: Fixed » Active

I think this actually is still a bug. PHP 5.3 is going to complain about this like it or not.

dawehner’s picture

Version: 6.x-2.12 » 6.x-3.x-dev

Sadly this notice is bad.

dawehner’s picture

Status: Active » Needs review
StatusFileSize
new578 bytes

So here is patch

dawehner’s picture

Basically the same patch was commited ~9 months ago to 7.x-3.x already. So it's definitive save to commit.

Additional every other plugin type implements the init method.

merlinofchaos’s picture

Status: Needs review » Fixed

Committed to 6.x-3.x

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.