AAAAhome/academiac/www/administrator/components/com_finder/models/fields/directories.php000064400000004763151457566510025170 0ustar00getCfg('log_path'), JFactory::getApplication()->getCfg('tmp_path') ); // Get the base directories. $dirs = JFolder::folders(JPATH_SITE, '.', false, true); // Iterate through the base directories and find the subdirectories. foreach ($dirs as $dir) { // Check if the directory should be excluded. if (in_array($dir, $exclude)) { continue; } // Get the child directories. $return = JFolder::folders($dir, '.', true, true); // Merge the directories. if (is_array($return)) { $values[] = $dir; $values = array_merge($values, $return); } } // Convert the values to options. for ($i = 0, $c = count($values); $i < $c; $i++) { $options[] = JHtml::_('select.option', str_replace(JPATH_SITE . DS, '', $values[$i]), str_replace(JPATH_SITE . DS, '', $values[$i])); } // Add a null option. array_unshift($options, JHTML::_('select.option', '', '- ' . JText::_('JNONE') . ' -')); // Handle default values of value1|value2|value3 if (is_string($value) && strpos($value, '|') && preg_match('#(?