In my view.html.php I set UserState Variables. One of this variables is set like this:
When I try to get the variable in the model via populateState function
$status = $app->getUserStateFromRequest($this->context.'.filter.status', 'filter_status', null);
$status is empty.
In the layout default.php I have integrated a Joomla search tools bar with:
echo JLayoutHelper::render('joomla.searchtools.default', array('view' => $this));
Everything is done fine, execept I do a reload on the page, or I choose another option of the filter. To be more concret, I load the page, afterwards I select one of the filter options, I can do that one time good. If I choose another value of the same filter, or reload the page with F5, than the following error come up:
Warning: Attempt to assign property of non-object in D:\websites\etiral2015\libraries\framework\Joomla\Registry\Registry.php on line 428
What does that mean?
When I change '.filter.status' to anything else eg.
.filterstatus, $status gets the right value.
So, why is it not possible to set UserState Variables starting with
.filter. , like Joomla does with
I integrated the Joomla 3 SearchTools Bar in the layout, with a filter field which is located in
component->models->forms->xxxx.xml and it is called
status. But also removing this filter field, does not help to set the UserState variable called
It seems that the new Joomla filter bar in the form is responsible for this mistake.
The last two stack entries of the Joomlas integrated failure debugger, shows me, that the setting of the userState variable in the view.html.php won't be accepted anymore and that this is responsible for the problem.
Warning: Attempt to assign property of non-object in D:\home\joomla\libraries\framework\Joomla\Registry\Registry.php on line 428 11 ...... 12 0.2121 4313344 JApplicationCms->setUserState( ) ..\view.html.php:50 13 0.2121 4313344 Joomla\Registry\Registry->set( ) ..\cms.php:1047
Furthermore, new settings of userState variables cannot be done, also not in other views with other userState variables. This problem exists until I logout from the session. After a new login, everything seems to be clear, until I come to the procedure I described.
Finally this leads in a security whole of my site, because if this userState filters cannot be set, users can have access to data which they are not permitted to see.
Joomla Version 3.3.6