News:

Looking for documentation? Take a look on our wiki

Main Menu

Cannot override product layout in Joomla override section

Started by Graph_1802, March 07, 2023, 11:47:59 AM

Previous topic - Next topic

Graph_1802

Hi,
I'm using Joomla ‎4.2.8 ‎4.2.8 and Virtuemart 4.0.12.
Inside the override section of the template I'm trying to override virtuemart product layouts.
So I go to Create override -> com_virtuemart and click on "product".
The notice "Override created in /templates/shaper_helixultimate/html/com_virtuemart/product" appears.
BUT when I go inisde the override directory in FTP the product folder is empty.
The override of any other virtuemart layout works fine: this is the only one that doesn't work.
I have tried also on other domains and Joomla 4 installations: I always obtain the same result.
Can anyone help?
Thanks in advance!

jenkinhill

#1
There is no default VM template for "product" so no override can be created - I don't know why that folder is present, it does not exist in VM3. You should create overrides for "productdetails" to change the product layout.
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Graph_1802

Ok, thank you very much.
So could you please indicate me which layout I have to override in order to modify the product thumbnail in category view? Inside the "productdetails" templates override I cannot find any!

pinochico

You find inside the"productdetails" templates for "Category" view?!
And how you find?

Pls find something about joomla templating and view (MVC), then you will know where find

view->template for view->load layout
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds for FB, GMC,.. from products, categories, orders, users, articles, acymailing subscribers and database table
Virtuemart Email Manager - customs email templates
Import products for Virtuemart - from CSV and XML
Rich Snippets - Google Structured Data
VirtueMart Products Extended - Slider with products, show Others bought, Products by CF ID and others filtering products

Graph_1802

#4
Hi, thank you for the reply.
I'm not searching the templates for "category" view: I'm trying to guess which layout I have to override in order to modify the product thumbnail, inside the category view.
I don't find that portion of the code inside the category layout overrides, so I searched for the "product" overrides but, as I have learned above, they don't exist.
jenkinhill suggests to search inside "productdetails" overrides so I asked to kindly indicate if inside that directory I could find that layout.

pinochico

quote]I have to override in order to modify the product thumbnail in category view[/quote]

????
Why are you trying to trick me? :)

Sorry, you use category view, definitely, don't matther if you talk about products inside category view
If you know how function MVC Joomla (model, views, controllers), then you have to go inside category view

Hmmm, Why don't you look in the documentation joomla?

If you inside category view, the you see template default and inside you see which template is loaded for products.
It is not template for ProductDetails view.

Try self look inside PHP pls, don't wait to anybody.

Definitely is some layout from folder sublayouts.
www.minijoomla.org  - new portal for Joomla!, Virtuemart and other extensions
XML Easy Feeder - feeds for FB, GMC,.. from products, categories, orders, users, articles, acymailing subscribers and database table
Virtuemart Email Manager - customs email templates
Import products for Virtuemart - from CSV and XML
Rich Snippets - Google Structured Data
VirtueMart Products Extended - Slider with products, show Others bought, Products by CF ID and others filtering products

GJC Web Design

Quote->->modify the product thumbnail, inside the category view

over ride views/sublayouts/product.php

to

html/com_virtuemart/sublayouts/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

Graph_1802

#7
Hi GJC Web Design, thank you for the reply.
the folder "sublayouts" is not inside the folder "view" but on the same level. Moreover the file inside "sublayouts" is not product.php but products.php.
In any case creating the folder html/com_virtuemart/sublayouts/products.php via FTP inside the template, and modifying it, doesn't produces the expected result.

jenkinhill

First you say:

Quote from: Graph_1802 on March 07, 2023, 11:47:59 AM
Inside the override section of the template I'm trying to override virtuemart product layouts.

Then you tell us you want to "modify the product thumbnail, inside the category view".

OK, the thumb display code is in vm-product-media-container div within the products.php sublayout. You say that modifying that code does not produce the "expected result".

Can you tell us what you are trying to do with the thumb image display?
Kelvyn
Lowestoft, Suffolk, UK

Retired from forum life November 2023

Please mention your VirtueMart, Joomla and PHP versions when asking a question in this forum

Graph_1802

#9
Hi,
I have found which layout I had to modify: it is the bs3-products.php inside "sublayouts" folder.

It remains a question: why on the Joomla backend -> template -> create override -> com_virtuemart there is not the voice "sublayouts"?
And why, always inside "create override", the voice "product" is present but not working?
But perhaps it is better to leave this questions for another topic.

P.S. the expected result is to produce any kind of modification in the product thumbnail part of the category view.

Many thanks to everyone for your kind assistance!