I would like to apply a class to a div according to a specific view of the page. If the page is a category blog view I want to add the class "blogview" else if the page is an article I want to apply the class "articleview". I would do this in the index.php file of my template. How could I do that?
Thanks in advance.
JRequest
is deprecated. Use JFactory::getApplication()->input
instead. For example JFactory::getApplication()->input->get('view')
See: https://docs.joomla.org/Retrieving_request_data_using_JInput