Search the Community
Showing results for tags 'disabled'.
-
Hello, I am using a component for joomla 2.5 but i hit snag where it comes to selecting the categories from a drop down box in the front end. I want to use the disabled element for the top category options so that they are visible but unselectable. Something like this: http://www.w3schools.com/tags/tryit.asp?filename=tryhtml_option_disabled The component uses the following code to hide certain categories of my choosing but i don't want to hide them i just want to add the HTML element "disabled" to the corresponding options: $options = JHTML::_('category.options','com_content',array('filter.published' => 1 )); require_once(JPATH_COMPONENT_SITE.DS.'config'.DS.'restrictions.php'); $myGroups = $acl->getGroupsByUser($my->id,false); foreach($myGroups as $gid) { if(isset($groupRestrictions[$gid])) { foreach($options as $k=>$option) { if(in_array( $option->value, $groupRestrictions[$gid] )) { unset($options[$k]); } } } } $opt = array('value'=>0,'text'=>JText::_('JOPTION_SELECT_CATEGORY')); array_unshift($options,$opt); return JHTML::_('select.genericlist',$options,'catid',"class='inputbox'",'value','text',$categoryId); } Any help is gratefully appreciated.
- 3 replies
-
- joomla 2.5
- form
-
(and 2 more)
Tagged with:
-
The code I am having a problem with is this: ob_start(); $resultTxt = system($command, $result); $errTxt = ob_get_contents(); ob_clean(); $resultTxt = nl2br($errTxt) . "$resultTxt"; I get a PHP Warning that the system () has been disabled for security reasons. I don't have access to the php.ini file to change this. Can the code be changed from system to something else that will work?