I am checking your VmConfig::set function.
You are using that in views like : components/com_virtuemart/views/category/view.html.php
Though none of these seem to work.
You can try your own
VmConfig::set('myVar', 10);
echo VmConfig::get('myVar',5); //gives 5
You have to be logged in as VM admin for some reason https://dev.virtuemart.net/projects/virtuemart/repository/entry/branches/com_virtuemart.3.0.12.4/administrator/components/com_virtuemart/helpers/config.php
static function set($key, $value){
if (empty(self::$_jpConfig->_params)) {
self::loadConfig();
}
if($admin = JFactory::getUser()->authorise('core.admin', 'com_virtuemart')){
if (!empty(self::$_jpConfig->_params)) {
self::$_jpConfig->_params[$key] = $value;
}
}
}
It makes no sense to be logged in, because this is used by the server to generate the front end views.
Only admins are allowed to change the config!
Max check your category view. It is used there, i suppose for backwards compatibility.
You are right. Nice trap.The function is useless this way. I just notice, we have this lines in that function for more than 3 years. But we never used it before. I just remove it. The function is indeed meant for dynamic changes of the config and when someone reached this level, he can manipulate the config anyway.