News:

Looking for documentation? Take a look on our wiki

Main Menu

need category picture in category page

Started by mblokdijk, August 23, 2016, 17:44:41 PM

Previous topic - Next topic

mblokdijk

I want the category picture, not the thumb, in my category page, not the page that shows al categories, but the category page showing the products inside the category. i want the category image on top of that page, for design functionalty

i have tried for over an hour to get the code, but i cannot seem to get it working.

<?php echo $this->category->images[0]->displayMediaThumb('',false) ?>

it is the /template/<name>/html/com_virtuemart/category/default.php page that i need, i gues..

vm3.016 and joomla 3.6.2

could any one help me please?

Passionate Joomla webdeveloper from the Netherlands, please checkout jmodules.com

GJC Web Design

why not just add it in the cat desc editor?
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

mblokdijk

#2
because the image has to be re-used on the homepage... and the description is put below the products listing ( for seo )
Passionate Joomla webdeveloper from the Netherlands, please checkout jmodules.com

Studio 42

Hi,
Check the code inside components/com_virtuemart/views/category/view.html.php
You find all the code to get one category informations.

If you are not in VIrtuemart add, before, in your php file:
defined('DS') or define('DS', DIRECTORY_SEPARATOR);
if (!class_exists( 'VmConfig' )) require(JPATH_ROOT.DS.'administrator'.DS.'components'.DS.'com_virtuemart'.DS.'helpers'.DS.'config.php');

VmConfig::loadConfig();


Regards,
Patrick

mblokdijk

Passionate Joomla webdeveloper from the Netherlands, please checkout jmodules.com