english/libraries/joomla/application/component/helper.php
/**
	 * Load the installed components into the _components property.
	 *
	 * @param   string  $option  The element value for the extension
	 *
	 * @return  boolean  True on success
	 * @since   11.1
	 */
Load the installed components into the _components property.
@param   string  $option  The element value for the extension

@return  boolean  True on success
@since   11.1
Load the installed components into the _components property . @param string $option The element value for the extension @return boolean True on success @since 11 . 1
protected static function _load($option)
	{
		$db		= JFactory::getDbo();
		$query	= $db->getQuery(true);
		$query->select('extension_id AS "id", element AS "option", params, enabled');
		$query->from('#__extensions');
		$query->where('`type` = '.$db->quote('component'));
		$query->where('`element` = '.$db->quote($option));
		$db->setQuery($query);
		$cache = JFactory::getCache('_system','callback');
		self::$_components[$option] =  $cache->get(array($db, 'loadObject'), null, $option, false);
		if ($error = $db->getErrorMsg() || empty(self::$_components[$option])) {
			JError::raiseWarning(500, JText::sprintf('JLIB_APPLICATION_ERROR_COMPONENT_NOT_LOADING', $option, $error));
			return false;
		}
		if (is_string(self::$_components[$option]->params)) {
			$temp = new JRegistry;
			$temp->loadString(self::$_components[$option]->params);
			self::$_components[$option]->params = $temp;
		}
		return true;
	}
protected static function _load ( $ option ) { $ db = JFactory :: getDbo ( ) ; $ query = $ db -> getQuery ( true ) ; $ query -> select ( 'extension_id AS "id", element AS "option", params, enabled' ) ; $ query -> from ( '#__extensions' ) ; $ query -> where ( '`type` = ' . $ db -> quote ( 'component' ) ) ; $ query -> where ( '`element` = ' . $ db -> quote ( $ option ) ) ; $ db -> setQuery ( $ query ) ; $ cache = JFactory :: getCache ( '_system' , 'callback' ) ; self :: $ _components [ $ option ] = $ cache -> get ( array ( $ db , 'loadObject' ) , null , $ option , false ) ; if ( $ error = $ db -> getErrorMsg ( ) || empty ( self :: $ _components [ $ option ] ) ) { JError :: raiseWarning ( 500 , JText :: sprintf ( 'JLIB_APPLICATION_ERROR_COMPONENT_NOT_LOADING' , $ option , $ error ) ) ; return false ; } if ( is_string ( self :: $ _components [ $ option ] -> params ) ) { $ temp = new JRegistry ; $ temp -> loadString ( self :: $ _components [ $ option ] -> params ) ; self :: $ _components [ $ option ] -> params = $ temp ; } return true ; }
Load the installed components into the _components property.
Load the installed components into the _components property .
// Fatal error. // Convert the params to an object.