News:

Support the VirtueMart project and become a member

Main Menu

[SOLVED] Get Category images?

Started by EvanGR, June 03, 2022, 09:33:12 AM

Previous topic - Next topic

EvanGR

Hello,

I am trying to get the images for a category in a custom module I am working on.

I can get the category by doing:
$categoryModel->getCategory($catId);

However I don't see the images for the category.

I am interested in getting the filenames so I can use them in my code (instead of the built-in displayMediaThumb method)

Thanks

GJC Web Design

$category = $categoryModel->getCategory($catId);
$categoryModel->addImages($category);

does that work?
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

EvanGR