defines.php in latest update causing fatal error

BasilC

Member
Just updated a copy of my website to Fabrik 3.3.4 using the Extensions Manager and tried to access a list in the back end. Got a fatal error

Fatal error: Class 'FabrikView' not found in /home/.../public_html/pgcdev2/components/com_fabrik/views/list/view.base.php on line 24

After some googling found http://fabrikar.com/forums/index.php?threads/class-fabrikview-not-found.42337/ where you discover an error in plugins/system/fabrik/defines.php. So I went to the github page you referenced and copied the updated code into defines.php on the website. It fixed the fatal error, but I now get a list of violations of strict standards:

Strict Standards: Declaration of PlgFabrik_ElementYesno::renderListData() should be compatible with PlgFabrik_ElementList::renderListData($data, stdClass &$thisRow, $opts = Array) in /home/palmersg/public_html/pgcdev2/plugins/fabrik_element/yesno/yesno.php on line 487

Strict Standards: Declaration of PlgFabrik_ElementDate::renderListData() should be compatible with PlgFabrik_ElementList::renderListData($data, stdClass &$thisRow, $opts = Array) in /home/palmersg/public_html/pgcdev2/plugins/fabrik_element/date/date.php on line 2522

Strict Standards: Declaration of PlgFabrik_ElementField::renderListData() should be compatible with PlgFabrik_Element::renderListData($data, stdClass &$thisRow, $opts = Array) in /home/palmersg/public_html/pgcdev2/plugins/fabrik_element/field/field.php on line 673

Strict Standards: Declaration of PlgFabrik_ElementDatabasejoin::renderListData() should be compatible with PlgFabrik_ElementList::renderListData($data, stdClass &$thisRow, $opts = Array) in /home/palmersg/public_html/pgcdev2/plugins/fabrik_element/databasejoin/databasejoin.php on line 3733

Strict Standards: Declaration of PlgFabrik_ElementTextarea::renderListData() should be compatible with PlgFabrik_Element::renderListData($data, stdClass &$thisRow, $opts = Array) in /home/palmersg/public_html/pgcdev2/plugins/fabrik_element/textarea/textarea.php on line 593

I know that I'm supposed to update from GitHub before going on the forums, but that takes a while to do. But do you not need to fix the defines.php issue because other people using Extension Manager to update Fabrik must be running into the same problem?
 
I can't replicate, my test site is updating without error.

In the thread you are mentioning the problem is coming from an outdated file user_defines.php
For now, I just renamed ./plugins/system/fabrik/user_defines.php to user_defines.php.sav and all is well

So check if you have this file and rename/adapt/delete it.

"Strict standard" notices are related to your php version.
 
Last edited:
I had the same issue. It seemed that something happened during the update (maybe forgot to clear the cache before checking for updates so I had an incomplete list?), so I had some plugins at 3.3.3 and others at 3.3.4.
Redoing an update fixed the issue.
 
There should not be a user_defines.php file. It's a very little used feature that allows sites to override the main Fabrik defines.php, where we include most of our "framework" files and set up some of the basic defines. There shouldn't be one in the distribution. But it appears that at some point in the last year, a user_defines.php managed to creep in to a release. Up till now it hasn't been noticed, because the main defines.php rarely changes. But we recently added a new file to the defines.php, the one that sets up the FabrikView class. So now any site which has the user_defines.php is blowing up because that file isn't getting included.

I think I'm going to add a global config switch to turn the user defines feature on and off, which will default to Off. I don''t know of anyone (except myself) who actually uses a user_defines.php, but if there is ... they'll just have to enable that switch.

Bottom line - if you have that ./plugins/system/fabrik/user_defines.php file, just delete it.

-- hugh
 
I don't have ./plugins/system/fabrik/user_defines.php. The problem was that I still had an old version of ./plugins/system/fabrik/defines.php even after updating. Like jfq above, I'd done an incomplete update which didn't include Fabrik System Plugin. So nothing wrong with the Fabrik update, just with the way I applied it.
 
We are in need of some funding.
More details.

Thank you.

Members online

Back
Top