I have a select option which displayes a certaing product category. How can I change this so it displays alphabetically?
<?php
$product = array();
$product[]= JHTML::_('select.option','','-select-');
echo $lists['product']= JHTML::_('select.genericList',$product,'product','class="inputbox" size="1"', 'value', 'text');
?>
For Product ordering, have you looked under VM config - Product Ordering Tab? This appears to allow for product ordering.
/administrator/index.php?option=com_virtuemart&view=config
If you are able to get things sorted by using the settings here, then no code changes are needed.
Quote from: mowlman on March 05, 2014, 18:05:52 PM
For Product ordering, have you looked under VM config - Product Ordering Tab? This appears to allow for product ordering.
/administrator/index.php?option=com_virtuemart&view=config
If you are able to get things sorted by using the settings here, then no code changes are needed.
I did try that method but it didn't work. I was using a custom application which was displaying the list at runtime so the solution involved a bit of AJAX work.
If you want to avoid hacking you can use Custom Filters. Its in the Free version
http://breakdesigns.net/extensions/custom-filters