Hello,
I found a very annoying side effect with pagination of the product's category view.
Description:
Every time when I navigate through my website, through different menus, and afterwards clicking to the virtuemart menu entry - the categories are shown. But then, after clicking into any category, only 20, or 6, or 10 product items are shown.
It depends on the menu where I navigated before! The value "# Intro" of the Parameters of the e.g. Category Blog Layout sets this default value... That's a side effect.
Inside each product category form, you can configure the parameters Category Form Limit List Max, etc. via Backend - But that doesn't matter if this "#Intro" value is lower.
Within my template, this was very annoying, because I have hidden the "results" selection box on the right upper side. And I wanted to show all devices without pagination.
Does anyone have the same error?
After some debugging, I found a solution - but I'm not sure if this is the most suitable one.
Inside /components/com_virtuemart/router.php line 583 I changed the code from
if (! array_key_exists ($instanceKey, self::$_instances)){
self::$_instances[$instanceKey] = new vmrouterHelper ($instanceKey,$query);
if (self::$limit===null){
$mainframe = Jfactory::getApplication(); ;
self::$limit= $mainframe->getUserStateFromRequest('global.list.limit', 'limit', VmConfig::get('list_limit', 20), 'int');
}
}
return self::$_instances[$instanceKey];
to
if (! array_key_exists ($instanceKey, self::$_instances)){
self::$_instances[$instanceKey] = new vmrouterHelper ($instanceKey,$query);
if (self::$limit===null){
$mainframe = Jfactory::getApplication();
self::$limit= $mainframe->getUserStateFromRequest('com_virtuemart.list.limit', 'limit', VmConfig::get('list_limit', 20), 'int');
}
}
return self::$_instances[$instanceKey];
Versions: Joomla 1.5.25, Virtuemart 2.0.6, 2.0.4, 2.0.3i, PHP 5.3.10-2, SEF on
best regards,
Thomas Kuschel, http://www.loytec.com
Thank you, this explains me something.
It should even contain the id of the category imho. Then you have the pagination stored per category, that was the idea and I wondered that it did not work with sef. thx.
Hi Milbo,
I've been too early pleased...
I have problems with the posted solution, after some more tests it didn't work any more...
I can't figure out the settings of limit, results, list_limit etc.
Hope you'll find the bug.
In the moment I changed the line 293 to
$vars['limit'] = 0; // vmrouterHelper::$limit;
So I get ALL my products listed! - : ::)
Thomas