diff options
author | dchill42 <dchill42@gmail.com> | 2012-07-23 16:53:47 +0200 |
---|---|---|
committer | dchill42 <dchill42@gmail.com> | 2012-07-23 16:53:47 +0200 |
commit | c5079de78e5141330c07e990811ef15e998e95aa (patch) | |
tree | 0f39d8c4fc7614246fc185810bfeaa7fad88a33a /system/helpers/directory_helper.php | |
parent | 00fcb545109d4e61bc14e403ec828749c34a54b3 (diff) | |
parent | ede49ba66b127535f3430e20aac72ceed2c4611a (diff) |
Merge branch develop of github.com:/EllisLab/CodeIgniter into session
Diffstat (limited to 'system/helpers/directory_helper.php')
-rw-r--r-- | system/helpers/directory_helper.php | 53 |
1 files changed, 31 insertions, 22 deletions
diff --git a/system/helpers/directory_helper.php b/system/helpers/directory_helper.php index 38347fa62..e7d3b5e8a 100644 --- a/system/helpers/directory_helper.php +++ b/system/helpers/directory_helper.php @@ -1,46 +1,56 @@ -<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); +<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed'); /** * CodeIgniter * - * An open source application development framework for PHP 5.1.6 or newer + * An open source application development framework for PHP 5.2.4 or newer + * + * NOTICE OF LICENSE + * + * Licensed under the Open Software License version 3.0 + * + * This source file is subject to the Open Software License (OSL 3.0) that is + * bundled with this package in the files license.txt / license.rst. It is + * also available through the world wide web at this URL: + * http://opensource.org/licenses/OSL-3.0 + * If you did not receive a copy of the license and are unable to obtain it + * through the world wide web, please send an email to + * licensing@ellislab.com so we can send you a copy immediately. * * @package CodeIgniter - * @author ExpressionEngine Dev Team - * @copyright Copyright (c) 2008 - 2011, EllisLab, Inc. - * @license http://codeigniter.com/user_guide/license.html + * @author EllisLab Dev Team + * @copyright Copyright (c) 2008 - 2012, EllisLab, Inc. (http://ellislab.com/) + * @license http://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0) * @link http://codeigniter.com * @since Version 1.0 * @filesource */ -// ------------------------------------------------------------------------ - /** * CodeIgniter Directory Helpers * * @package CodeIgniter * @subpackage Helpers * @category Helpers - * @author ExpressionEngine Dev Team + * @author EllisLab Dev Team * @link http://codeigniter.com/user_guide/helpers/directory_helper.html */ // ------------------------------------------------------------------------ -/** - * Create a Directory Map - * - * Reads the specified directory and builds an array - * representation of it. Sub-folders contained with the - * directory will be mapped as well. - * - * @access public - * @param string path to source - * @param int depth of directories to traverse (0 = fully recursive, 1 = current dir, etc) - * @return array - */ if ( ! function_exists('directory_map')) { + /** + * Create a Directory Map + * + * Reads the specified directory and builds an array + * representation of it. Sub-folders contained with the + * directory will be mapped as well. + * + * @param string path to source + * @param int depth of directories to traverse (0 = fully recursive, 1 = current dir, etc) + * @param bool whether to show hidden files + * @return array + */ function directory_map($source_dir, $directory_depth = 0, $hidden = FALSE) { if ($fp = @opendir($source_dir)) @@ -52,7 +62,7 @@ if ( ! function_exists('directory_map')) while (FALSE !== ($file = readdir($fp))) { // Remove '.', '..', and hidden files [optional] - if ( ! trim($file, '.') OR ($hidden == FALSE && $file[0] == '.')) + if ( ! trim($file, '.') OR ($hidden === FALSE && $file[0] === '.')) { continue; } @@ -75,6 +85,5 @@ if ( ! function_exists('directory_map')) } } - /* End of file directory_helper.php */ /* Location: ./system/helpers/directory_helper.php */
\ No newline at end of file |