News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Upgrading to 3.2.12 and lost my category layout override

Started by Jokingmind, January 03, 2018, 16:44:50 PM

Previous topic - Next topic

Jokingmind

Hello.
---------------------------------------
Joomla! 3.8.3 Stable
Php  7.1.12
Template - Gantry Framework with Helium v5.4.22
VM upgraded from 3.2.4 to 3.2.12
-----------------------------------------
I'm facing an issue with the upgrade of VM.
It seems it doesn't load my category view layout, even if it is selected.
And in most cases I recive this error: 0 Call to a member function displayMediaThumb() on null

You can compare the live site (no upgrade): www.shop.barbieri-italiani.it
with the test site: www.bidev.davide-strati.it

If you take a look at the category pages VM is able to load only the first item of the main menu with some errors (and only for the italian language) while the others category pages recive this 0 Call error.
No problem with the product pages.

What I have changed in the category layout is the product layout that is called from category, in order to load the second image of the product and not the first one (that has a gary background).

Thanks for help!

Jokingmind

Tried with 3.2.8 too, same result.
Uploaded using jenkinhill suggestions.
Also tried to switch template, no changes.

GJC Web Design

Find the line that is causing this by switching on full debugging/error

Then it can be fixed.. prob. from one of the sublayouts ..  e.g. product.php
GJC Web Design
VirtueMart and Joomla Developers - php developers https://www.gjcwebdesign.com
VM4 AusPost Shipping Plugin - e-go Shipping Plugin - VM4 Postcode Shipping Plugin - Radius Shipping Plugin - VM4 NZ Post Shipping Plugin - AusPost Estimator
Samport Payment Plugin - EcomMerchant Payment Plugin - ccBill payment Plugin
VM2 Product Lock Extension - VM2 Preconfig Adresses Extension - TaxCloud USA Taxes Plugin - Virtuemart  Product Review Component
https://extensions.joomla.org/profile/profile/details/67210
Contact for any VirtueMart or Joomla development & customisation

Jokingmind

OK, as I supposed the problem is related to this line

<a title="<?php echo $product->product_name ?>" href="<?php echo $product->link.$ItemidStr?>">
<?php
echo $product->images[1]->displayMediaThumb('class="browseProductImage"'false);
?>

</a>

Here I've changed the images[0] to images[1] in order to select the second image of the product that has a white background, insted of a gray one.
Before the update this line wasn't a problem, now it is, but i don't understand why.
If I revert it back to
  • everything seems to work fine.

    Can you explain me this behavior?

    Thanks!