Joomla PageBuilder Pro Incompatibility with HikaShop User Synchronization Plugin

  • Posts: 78
  • Thank you received: 4
  • Hikamarket Multivendor Hikashop Business
2 months 3 weeks ago #362914

-- url of the page with the problem -- : http://localhost/joomla/index.php/
-- HikaShop version -- : 5.1.0
-- Joomla version -- : 5.1.4
-- PHP version -- : 8.3.6
-- Browser(s) name and version -- : Chrome, 21. Aug 2024
-- Error-message(debug-mod must be tuned on) -- : Call to a member function onBeforeCompileHead() on false

Issue Summary:
When the HikaShop User Synchronization Plugin is enabled, Joomla's PageBuilder Pro encounters a fatal error, preventing it from functioning properly. The error message indicates a call to a member function on onBeforeCompileHead() on false.

How to Reproduce:
Install Joomla with the PageBuilder Pro component.
Install and enable the HikaShop User Synchronization Plugin.
Attempt to access or edit a page using PageBuilder Pro.
Observed Behavior:
Upon attempting to use the PageBuilder Pro, the following error is displayed:

Error Message: Call to a member function onBeforeCompileHead() on false
This message is followed by a detailed call stack, indicating where the error occurs in the code:

Function: plgSystemHikashopuser->onBeforeCompileHead()
Location: /JROOT/administrator/components/com_hikashop/pluginCompatJ4.php:68
The error prevents the PageBuilder Pro from loading, making it impossible to edit or create pages while the plugin is enabled.

Expected Behavior:
PageBuilder Pro should function normally, allowing for page creation and editing without any errors, even when the HikaShop User Synchronization Plugin is enabled.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82823
  • Thank you received: 13370
  • MODERATOR
2 months 3 weeks ago #362924

Hi,

I don't think it has anything to do with an incompatibility between HikaShop and PageBuilder.
On my own test website on my local computer, I have both installed and running and don't have the error when editing or creating pages.
Based on the screenshot you provided of the callstack and the error message, it seems that you've uninstalled the HikaShop cart notification plugin which comes with HikaShop. However, when the "Load HikaShop on all pages" setting of the HikaShop User Synchronization plugin is activated, HikaShop will try to load that cart notification plugin after loading HikaShop, if HikaShop isn't already loaded on the page. And on a PageBuilder page, HikaShop is not already loaded, and thus it goes in there.
But there is a check missing in this code on whether the cart notification plugin can be loaded before calling its onBeforeCompileHead method. So, I've add a check on our end in order to avoid that error.

Download again the install package of HikaShop on our website and install it on yours and you won't get the error.

Please Log in or Create an account to join the conversation.

Time to create page: 0.053 seconds
Powered by Kunena Forum