_sefPluginPath = ''; // check for Joomsef plugin if( in_array( $this->_optionNoCom, $this->_config->useJoomsefRouter)) { // check if file exists, store path if it does $path = sh404SEF_ABS_PATH . 'plugins/sh404sefextjoomsef/'.$this->_option.'.php'; if ( shFileExists($path)) { $this->_sefPluginPath = $path; $this->_pluginType = Sh404sefClassBaseextplugin::TYPE_JOOMSEF_ROUTER; } } // check for Acesef plugin if( empty( $this->_sefPluginPath) && in_array( $this->_optionNoCom, $this->_config->useAcesefRouter)) { // check if file exists, store path if it does $path = sh404SEF_ABS_PATH .'plugins/sh404sefextacesef/'.$this->_option.'.php'; if ( shFileExists($path)) { $this->_sefPluginPath = $path; $this->_pluginType = Sh404sefClassBaseextplugin::TYPE_ACESEF_ROUTER; } } // read $useExtensionPlugin = in_array( $this->_optionNoCom, $this->_config->shDoNotOverrideOwnSef); // look first in component owndir for a joomla sef router.php file $path = sh404SEF_ABS_PATH.'components/'.$this->_option.'/router.php'; $pathSh404sefExtPlugin = sh404SEF_ABS_PATH.'components/'.$this->_option.'/sef_ext/'.$this->_option.'.php'; $pathSh404sefBuiltinPlugin = sh404SEF_ABS_PATH.'components/com_sh404sef/sef_ext/'.$this->_option.'.php'; if (empty( $this->_sefPluginPath) && shFileExists( $path) && ($useExtensionPlugin // and param said use extension plugin || (!$useExtensionPlugin // or param said do not use extension plugin BUT && !shFileExists( $pathSh404sefExtPlugin) // we don't have any other plugin to use && !shFileExists($pathSh404sefBuiltinPlugin)))) { // use router.php $this->_sefPluginPath = $path; $this->_pluginType = Sh404sefClassBaseextplugin::TYPE_JOOMLA_ROUTER; } // not found yet, look into extension dir for an sh404sef native plugin if (empty( $this->_sefPluginPath) && shFileExists( $pathSh404sefExtPlugin)) { $this->_sefPluginPath = $pathSh404sefExtPlugin; $this->_pluginType = Sh404sefClassBaseextplugin::TYPE_SH404SEF_ROUTER; } // not found yet, look into sh404sef dir for an sh404sef native plugin if (empty( $this->_sefPluginPath) && shFileExists( $pathSh404sefBuiltinPlugin)) { $this->_sefPluginPath = $pathSh404sefBuiltinPlugin; $this->_pluginType = Sh404sefClassBaseextplugin::TYPE_SH404SEF_ROUTER; } } protected function _findMetaPluginPath( $nonSefVars = array()) { $this->_metaPluginPath = ''; // look first in component owndir for a meta ext file $path = sh404SEF_ABS_PATH.'components/'. $this->_option . '/meta_ext/'. $this->_option . '.php'; if (shFileExists( $path)) { // use router.php $this->_metaPluginPath = $path; } // then look for our own meta ext file, if any if (empty( $this->_metaPluginPath)) { $path = sh404SEF_ABS_PATH.'components/com_sh404sef/meta_ext/'. $this->_option . '.php'; if(shFileExists( $path)) { // use router.php $this->_metaPluginPath = $path; } } } }