This is the documentation for the pro version of our content plugin for Virtuemart.
Install using the Joomla installer. Enable the plugin in the plugin manager
The product snapshot can be embedded in any content that supports Joomla content plugins. This includes Joomla articles and the custom html module, also many 3rd party extensions such as K2. Use code such as the following:
{product id=23}
This will embed the product with an id number of 23 (the id number is the one in the right hand column in the column marked id in the Virtuemart product manager).
You can set default parameters in the plugin manager. These can be overridden with user parameters, the ones available are:
One of the following parameters is required:-
The others are optional. If used they must be separated by semi-colons and usually have a zero or one value:
{product id=23,27,34;showImage=1;showAddToCart=0;showDescription=1}
This will show three products with the image and description but not the add-to-cart button. The other parameters will take their default values as set in the plugin manager.
{product sku=c002a,c0002b,m0054;showImage=1;showStock=1;showDescription=0}
This will show three products with the listed skus, with the images and stock levels but no description. The other parameters will take their default values as set in the plugin manager.
{product cid=4}
will show products from the category with id number 4.
With listing multiple products you may want to set the orderBy and orderDir parameters. Possible values of orderyBy are:-
orderDir can take the values ASC or DESC
{product category=tools;limit=15;orderBy=product_price;orderDir=ASC}
This will list up to 15 products from the tools category, ordered by price in ascending order. Note that the plugin conducts a keyword search so if more than one category has 'tools' in the name (eg, garden tools, power tools) results from both will be displayed.
{product group=featured}
This will display products marked as featured.
It is possible to combine the cid parameter with some of the others (mid, manufacturer or group) to restrict results to a specific category, eg
{product group=latest;cid=6}
This will show the latest products from the category with id number 6.
The plugin will display the price fields selected in the Virtuemart price configuration. It will display custom fields, and is fully compatible with the stockable variants plugin.
The imageWidth, imageHeight and layout parameters are only available in the 'Pro' version of the plugin. The imageWidth and imageHeight parameters take an integer value for the size in pixels.
The 'pro' version of the plugin includes extra layouts. These are installed in the tmpl sub-directory of the plugin, and can be overridden by placing your own versions in the html folder of your site template. The layout parameter takes the values: default, thumbnails, small_thumbnails, lightbox_gallery and slideshow. For example:-
{product id=23;imageWidth=200;imageHeight=160;layout=slideshow}
If you wish to override the layout there are a long list of data available to your template:-