When I view the products via categories I would like to remove the current sort methods available which are:"Creation date" , "category" and "manufacturer name"
And have "Sort by most viewed" , "price" and "popularity (most bought)". I have no idea how to do this.
I would like to remove the "manufacturer" tab completely.
Hope you guys can help ;D thanks in advance
The available sort fields are set in Configuration/Product Order Settings. http://docs.virtuemart.net/manual/21-configuration-menu/62-configuration.html#product-order-settings
You canh remove manufacturers by editing the div class="orderby-displaynumber" in components/com_virtuemart/views/category/tmpl/default.php and using the edited file as a template override.
Thanks I managed to change the sort fields just like I wanted them.
I don't think I understand The template override to remove the manufacturer option. What I tried is to comment this out:
<!-- <div class="orderby-displaynumber">
<div class="width70 floatleft">
<?php echo $this->orderByList['orderby']; ?>
<?php echo $this->orderByList['manufacturer']; ?>
</div> -->
It didn't work. What am I doing wrong here?
Personally, I think this really needs to be an option inside of VM itself. Nobody should be made to hack core files to turn off a title and drop down that many people won't need. I just checked the source and there is no difference between the manufacturer drop down and other drop downs. So you can't even make a CSS "display:none;" to hide it, which would mean you wouldn't need to hack any core files.
Also, there is a spelling mistake for the word "Height" when you turn on "Height" as an order option. It says "Heigth", not sure where to notify this.
jenkinhill
Your advice is usually spot on. However, I made the changes with the override and couldn't get the "Sort" to go away. I even uploaded the changes to the virtuemart folder ( /components/com_virtuemart/views/category/tmpl/default.php ) and that didn't work either. I thought it could be cache, cleared that in the site "and" browser, but still...that little "Sort" won't disappear.
<!-- <div class="orderby-displaynumber">
<div class="floatleft vm-order-list">
<?php //echo $this->orderByList['orderby']; ?>
<?php //echo $this->orderByList['manufacturer']; ?>
</div>
<div class="vm-pagination vm-pagination-top">
<?php //echo $this->vmPagination->getPagesLinks (); ?>
<span class="vm-page-counter"><?php //echo $this->vmPagination->getPagesCounter (); ?></span>
</div>
<div class="floatright display-number"><?php //echo $this->vmPagination->getResultsCounter ();?><br/><?php //echo $this->vmPagination->getLimitBox ($this->category->limit_list_step); ?></div>
<div class="clear"></div>
</div> --><!-- end of orderby-displaynumber -->
Any other thoughts?
I tried it with and without the <div> tags commented out as well.
Maybe it's just a ghost and will go away soon...
NEVERMIND!
...sigh...
I forgot that I was working in a sub-directory of the site, creating a mirror site that's updated.
I uploaded the echo commented file ( //echo..) and it works great.
Thanks, jenkinhill.