blob: 6e8a4ded1e50b973f2d039d98f6a9c96670a0665 [file] [log] [blame]
Andrey Andreev8bf6bb62012-01-06 16:11:04 +02001<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
Derek Allard2067d1a2008-11-13 22:59:24 +00002/**
3 * CodeIgniter
4 *
Phil Sturgeon07c1ac82012-03-09 17:03:37 +00005 * An open source application development framework for PHP 5.2.4 or newer
Derek Allard2067d1a2008-11-13 22:59:24 +00006 *
Derek Jonesf4a4bd82011-10-20 12:18:42 -05007 * NOTICE OF LICENSE
Andrey Andreev8bf6bb62012-01-06 16:11:04 +02008 *
Derek Jonesf4a4bd82011-10-20 12:18:42 -05009 * Licensed under the Open Software License version 3.0
Andrey Andreev8bf6bb62012-01-06 16:11:04 +020010 *
Derek Jonesf4a4bd82011-10-20 12:18:42 -050011 * This source file is subject to the Open Software License (OSL 3.0) that is
12 * bundled with this package in the files license.txt / license.rst. It is
13 * also available through the world wide web at this URL:
14 * http://opensource.org/licenses/OSL-3.0
15 * If you did not receive a copy of the license and are unable to obtain it
16 * through the world wide web, please send an email to
17 * licensing@ellislab.com so we can send you a copy immediately.
18 *
Derek Allard2067d1a2008-11-13 22:59:24 +000019 * @package CodeIgniter
Derek Jonesf4a4bd82011-10-20 12:18:42 -050020 * @author EllisLab Dev Team
Greg Aker0defe5d2012-01-01 18:46:41 -060021 * @copyright Copyright (c) 2008 - 2012, EllisLab, Inc. (http://ellislab.com/)
Derek Jonesf4a4bd82011-10-20 12:18:42 -050022 * @license http://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
Derek Allard2067d1a2008-11-13 22:59:24 +000023 * @link http://codeigniter.com
24 * @since Version 1.0
25 * @filesource
26 */
27
Derek Allard2067d1a2008-11-13 22:59:24 +000028/**
29 * CodeIgniter File Helpers
30 *
31 * @package CodeIgniter
32 * @subpackage Helpers
33 * @category Helpers
Derek Jonesf4a4bd82011-10-20 12:18:42 -050034 * @author EllisLab Dev Team
Derek Jonesc37f0e12009-04-21 13:33:40 +000035 * @link http://codeigniter.com/user_guide/helpers/file_helpers.html
Derek Allard2067d1a2008-11-13 22:59:24 +000036 */
37
38// ------------------------------------------------------------------------
39
40/**
41 * Read File
42 *
43 * Opens the file specfied in the path and returns it as a string.
44 *
Derek Allard2067d1a2008-11-13 22:59:24 +000045 * @param string path to file
46 * @return string
Barry Mienydd671972010-10-04 16:33:58 +020047 */
Derek Allard2067d1a2008-11-13 22:59:24 +000048if ( ! function_exists('read_file'))
49{
50 function read_file($file)
51 {
52 if ( ! file_exists($file))
53 {
54 return FALSE;
55 }
Barry Mienydd671972010-10-04 16:33:58 +020056
Derek Allard2067d1a2008-11-13 22:59:24 +000057 if (function_exists('file_get_contents'))
58 {
Barry Mienydd671972010-10-04 16:33:58 +020059 return file_get_contents($file);
Derek Allard2067d1a2008-11-13 22:59:24 +000060 }
61
62 if ( ! $fp = @fopen($file, FOPEN_READ))
63 {
64 return FALSE;
65 }
Barry Mienydd671972010-10-04 16:33:58 +020066
Derek Allard2067d1a2008-11-13 22:59:24 +000067 flock($fp, LOCK_SH);
Barry Mienydd671972010-10-04 16:33:58 +020068
Derek Allard2067d1a2008-11-13 22:59:24 +000069 $data = '';
70 if (filesize($file) > 0)
71 {
72 $data =& fread($fp, filesize($file));
73 }
74
75 flock($fp, LOCK_UN);
76 fclose($fp);
77
78 return $data;
79 }
80}
Barry Mienydd671972010-10-04 16:33:58 +020081
Derek Allard2067d1a2008-11-13 22:59:24 +000082// ------------------------------------------------------------------------
83
84/**
85 * Write File
86 *
87 * Writes data to the file specified in the path.
88 * Creates a new file if non-existent.
89 *
Derek Allard2067d1a2008-11-13 22:59:24 +000090 * @param string path to file
91 * @param string file data
92 * @return bool
Barry Mienydd671972010-10-04 16:33:58 +020093 */
Derek Allard2067d1a2008-11-13 22:59:24 +000094if ( ! function_exists('write_file'))
95{
96 function write_file($path, $data, $mode = FOPEN_WRITE_CREATE_DESTRUCTIVE)
97 {
98 if ( ! $fp = @fopen($path, $mode))
99 {
100 return FALSE;
101 }
Barry Mienydd671972010-10-04 16:33:58 +0200102
Derek Allard2067d1a2008-11-13 22:59:24 +0000103 flock($fp, LOCK_EX);
104 fwrite($fp, $data);
105 flock($fp, LOCK_UN);
Barry Mienydd671972010-10-04 16:33:58 +0200106 fclose($fp);
Derek Allard2067d1a2008-11-13 22:59:24 +0000107
108 return TRUE;
109 }
110}
Barry Mienydd671972010-10-04 16:33:58 +0200111
Derek Allard2067d1a2008-11-13 22:59:24 +0000112// ------------------------------------------------------------------------
113
114/**
115 * Delete Files
116 *
117 * Deletes all files contained in the supplied directory path.
118 * Files must be writable or owned by the system in order to be deleted.
119 * If the second parameter is set to TRUE, any directories contained
120 * within the supplied base directory will be nuked as well.
121 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000122 * @param string path to file
123 * @param bool whether to delete any directories found in the path
124 * @return bool
Barry Mienydd671972010-10-04 16:33:58 +0200125 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000126if ( ! function_exists('delete_files'))
127{
128 function delete_files($path, $del_dir = FALSE, $level = 0)
Barry Mienydd671972010-10-04 16:33:58 +0200129 {
Derek Allard2067d1a2008-11-13 22:59:24 +0000130 // Trim the trailing slash
Derek Jonesc37f0e12009-04-21 13:33:40 +0000131 $path = rtrim($path, DIRECTORY_SEPARATOR);
Barry Mienydd671972010-10-04 16:33:58 +0200132
Derek Allard2067d1a2008-11-13 22:59:24 +0000133 if ( ! $current_dir = @opendir($path))
Greg Aker3e9519e2010-01-15 00:09:34 +0000134 {
Barry Mienydd671972010-10-04 16:33:58 +0200135 return FALSE;
Greg Aker3e9519e2010-01-15 00:09:34 +0000136 }
Barry Mienydd671972010-10-04 16:33:58 +0200137
Pascal Kriete45e3cdf2011-02-14 13:26:20 -0500138 while (FALSE !== ($filename = @readdir($current_dir)))
Derek Allard2067d1a2008-11-13 22:59:24 +0000139 {
Andrey Andreevb2518642012-03-26 21:44:08 +0300140 if ($filename !== '.' && $filename !== '..')
Derek Allard2067d1a2008-11-13 22:59:24 +0000141 {
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200142 if (is_dir($path.DIRECTORY_SEPARATOR.$filename) && $filename[0] !== '.')
Derek Allard2067d1a2008-11-13 22:59:24 +0000143 {
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200144 delete_files($path.DIRECTORY_SEPARATOR.$filename, $del_dir, $level + 1);
Derek Allard2067d1a2008-11-13 22:59:24 +0000145 }
146 else
147 {
Andrey Andreevb2518642012-03-26 21:44:08 +0300148 @unlink($path.DIRECTORY_SEPARATOR.$filename);
Derek Allard2067d1a2008-11-13 22:59:24 +0000149 }
150 }
151 }
152 @closedir($current_dir);
Barry Mienydd671972010-10-04 16:33:58 +0200153
Andrey Andreevb2518642012-03-26 21:44:08 +0300154 if ($del_dir == TRUE && $level > 0)
Derek Allard2067d1a2008-11-13 22:59:24 +0000155 {
Greg Aker3e9519e2010-01-15 00:09:34 +0000156 return @rmdir($path);
Derek Allard2067d1a2008-11-13 22:59:24 +0000157 }
Barry Mienydd671972010-10-04 16:33:58 +0200158
Greg Aker3e9519e2010-01-15 00:09:34 +0000159 return TRUE;
Derek Allard2067d1a2008-11-13 22:59:24 +0000160 }
161}
162
163// ------------------------------------------------------------------------
164
165/**
166 * Get Filenames
167 *
Barry Mienydd671972010-10-04 16:33:58 +0200168 * Reads the specified directory and builds an array containing the filenames.
Derek Allard2067d1a2008-11-13 22:59:24 +0000169 * Any sub-folders contained within the specified path are read as well.
170 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000171 * @param string path to source
172 * @param bool whether to include the path as part of the filename
173 * @param bool internal variable to determine recursion status - do not use in calls
174 * @return array
Barry Mienydd671972010-10-04 16:33:58 +0200175 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000176if ( ! function_exists('get_filenames'))
177{
178 function get_filenames($source_dir, $include_path = FALSE, $_recursion = FALSE)
179 {
180 static $_filedata = array();
Barry Mienydd671972010-10-04 16:33:58 +0200181
Derek Allard2067d1a2008-11-13 22:59:24 +0000182 if ($fp = @opendir($source_dir))
183 {
184 // reset the array and make sure $source_dir has a trailing slash on the initial call
185 if ($_recursion === FALSE)
186 {
187 $_filedata = array();
188 $source_dir = rtrim(realpath($source_dir), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR;
189 }
Barry Mienydd671972010-10-04 16:33:58 +0200190
Derek Allard2067d1a2008-11-13 22:59:24 +0000191 while (FALSE !== ($file = readdir($fp)))
192 {
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200193 if (@is_dir($source_dir.$file) && $file[0] !== '.')
Derek Allard2067d1a2008-11-13 22:59:24 +0000194 {
Barry Mienydd671972010-10-04 16:33:58 +0200195 get_filenames($source_dir.$file.DIRECTORY_SEPARATOR, $include_path, TRUE);
Derek Allard2067d1a2008-11-13 22:59:24 +0000196 }
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200197 elseif ($file[0] !== '.')
Derek Allard2067d1a2008-11-13 22:59:24 +0000198 {
Derek Allard2067d1a2008-11-13 22:59:24 +0000199 $_filedata[] = ($include_path == TRUE) ? $source_dir.$file : $file;
200 }
201 }
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200202 closedir($fp);
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200203
Derek Allard2067d1a2008-11-13 22:59:24 +0000204 return $_filedata;
205 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200206
207 return FALSE;
Derek Allard2067d1a2008-11-13 22:59:24 +0000208 }
209}
210
211// --------------------------------------------------------------------
212
213/**
214 * Get Directory File Information
215 *
Barry Mienydd671972010-10-04 16:33:58 +0200216 * Reads the specified directory and builds an array containing the filenames,
Derek Allard2067d1a2008-11-13 22:59:24 +0000217 * filesize, dates, and permissions
218 *
219 * Any sub-folders contained within the specified path are read as well.
220 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000221 * @param string path to source
Derek Jones626d39f2010-03-02 23:14:56 -0600222 * @param bool Look only at the top level directory specified?
Derek Allard2067d1a2008-11-13 22:59:24 +0000223 * @param bool internal variable to determine recursion status - do not use in calls
224 * @return array
Barry Mienydd671972010-10-04 16:33:58 +0200225 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000226if ( ! function_exists('get_dir_file_info'))
227{
Derek Jones788b00f2009-11-27 18:00:20 +0000228 function get_dir_file_info($source_dir, $top_level_only = TRUE, $_recursion = FALSE)
Derek Allard2067d1a2008-11-13 22:59:24 +0000229 {
Derek Jones63dc27f2009-02-10 21:59:20 +0000230 static $_filedata = array();
Derek Allard2067d1a2008-11-13 22:59:24 +0000231 $relative_path = $source_dir;
Derek Jonesc37f0e12009-04-21 13:33:40 +0000232
Derek Allard2067d1a2008-11-13 22:59:24 +0000233 if ($fp = @opendir($source_dir))
234 {
235 // reset the array and make sure $source_dir has a trailing slash on the initial call
236 if ($_recursion === FALSE)
237 {
238 $_filedata = array();
239 $source_dir = rtrim(realpath($source_dir), DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR;
240 }
241
Derek Jones788b00f2009-11-27 18:00:20 +0000242 // foreach (scandir($source_dir, 1) as $file) // In addition to being PHP5+, scandir() is simply not as fast
Derek Allard2067d1a2008-11-13 22:59:24 +0000243 while (FALSE !== ($file = readdir($fp)))
244 {
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200245 if (@is_dir($source_dir.$file) && $file[0] !== '.' && $top_level_only === FALSE)
Derek Allard2067d1a2008-11-13 22:59:24 +0000246 {
Barry Mienydd671972010-10-04 16:33:58 +0200247 get_dir_file_info($source_dir.$file.DIRECTORY_SEPARATOR, $top_level_only, TRUE);
248 }
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200249 elseif ($file[0] !== '.')
Barry Mienydd671972010-10-04 16:33:58 +0200250 {
Derek Allard2067d1a2008-11-13 22:59:24 +0000251 $_filedata[$file] = get_file_info($source_dir.$file);
252 $_filedata[$file]['relative_path'] = $relative_path;
253 }
254 }
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200255 closedir($fp);
Derek Jones788b00f2009-11-27 18:00:20 +0000256
Derek Allard2067d1a2008-11-13 22:59:24 +0000257 return $_filedata;
258 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200259
260 return FALSE;
Derek Allard2067d1a2008-11-13 22:59:24 +0000261 }
262}
263
264// --------------------------------------------------------------------
265
266/**
267* Get File Info
268*
269* Given a file and path, returns the name, path, size, date modified
270* Second parameter allows you to explicitly declare what information you want returned
271* Options are: name, server_path, size, date, readable, writable, executable, fileperms
272* Returns FALSE if the file cannot be found.
273*
Derek Jonesc37f0e12009-04-21 13:33:40 +0000274* @param string path to file
275* @param mixed array or comma separated string of information returned
Derek Allard2067d1a2008-11-13 22:59:24 +0000276* @return array
277*/
278if ( ! function_exists('get_file_info'))
279{
280 function get_file_info($file, $returned_values = array('name', 'server_path', 'size', 'date'))
281 {
282
283 if ( ! file_exists($file))
284 {
285 return FALSE;
286 }
287
288 if (is_string($returned_values))
289 {
290 $returned_values = explode(',', $returned_values);
291 }
292
293 foreach ($returned_values as $key)
294 {
295 switch ($key)
296 {
297 case 'name':
Derek Jonesc37f0e12009-04-21 13:33:40 +0000298 $fileinfo['name'] = substr(strrchr($file, DIRECTORY_SEPARATOR), 1);
Derek Allard2067d1a2008-11-13 22:59:24 +0000299 break;
300 case 'server_path':
301 $fileinfo['server_path'] = $file;
302 break;
303 case 'size':
304 $fileinfo['size'] = filesize($file);
305 break;
306 case 'date':
Robin Sowell73c19fc2010-04-09 11:18:26 -0400307 $fileinfo['date'] = filemtime($file);
Derek Allard2067d1a2008-11-13 22:59:24 +0000308 break;
309 case 'readable':
310 $fileinfo['readable'] = is_readable($file);
311 break;
312 case 'writable':
Derek Jones37f4b9c2011-07-01 17:56:50 -0500313 // There are known problems using is_weritable on IIS. It may not be reliable - consider fileperms()
Derek Allard2067d1a2008-11-13 22:59:24 +0000314 $fileinfo['writable'] = is_writable($file);
315 break;
316 case 'executable':
317 $fileinfo['executable'] = is_executable($file);
318 break;
319 case 'fileperms':
320 $fileinfo['fileperms'] = fileperms($file);
321 break;
322 }
323 }
324
325 return $fileinfo;
326 }
327}
328
329// --------------------------------------------------------------------
330
331/**
332 * Get Mime by Extension
333 *
Barry Mienydd671972010-10-04 16:33:58 +0200334 * Translates a file extension into a mime type based on config/mimes.php.
Derek Allard2067d1a2008-11-13 22:59:24 +0000335 * Returns FALSE if it can't determine the type, or open the mime config file
336 *
337 * Note: this is NOT an accurate way of determining file mime types, and is here strictly as a convenience
338 * It should NOT be trusted, and should certainly NOT be used for security
339 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000340 * @param string path to file
341 * @return mixed
Barry Mienydd671972010-10-04 16:33:58 +0200342 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000343if ( ! function_exists('get_mime_by_extension'))
344{
345 function get_mime_by_extension($file)
346 {
Derek Allard95023112010-01-17 07:51:21 +0000347 $extension = strtolower(substr(strrchr($file, '.'), 1));
Derek Jonesc37f0e12009-04-21 13:33:40 +0000348
Derek Allard2067d1a2008-11-13 22:59:24 +0000349 global $mimes;
Derek Jonesc37f0e12009-04-21 13:33:40 +0000350
Derek Allard2067d1a2008-11-13 22:59:24 +0000351 if ( ! is_array($mimes))
352 {
Andrey Andreev3b8ad8f2012-01-10 18:09:07 +0200353 if (defined('ENVIRONMENT') && is_file(APPPATH.'config/'.ENVIRONMENT.'/mimes.php'))
Greg Akerd96f8822011-12-27 16:23:47 -0600354 {
355 include(APPPATH.'config/'.ENVIRONMENT.'/mimes.php');
356 }
357 elseif (is_file(APPPATH.'config/mimes.php'))
358 {
359 include(APPPATH.'config/mimes.php');
360 }
Eric Barnes92808342011-03-18 09:02:37 -0400361
bubbafoley0ea04142011-03-17 14:55:41 -0500362 if ( ! is_array($mimes))
Derek Allard2067d1a2008-11-13 22:59:24 +0000363 {
364 return FALSE;
365 }
366 }
367
368 if (array_key_exists($extension, $mimes))
369 {
370 if (is_array($mimes[$extension]))
371 {
372 // Multiple mime types, just give the first one
373 return current($mimes[$extension]);
374 }
375 else
376 {
377 return $mimes[$extension];
378 }
379 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200380
381 return FALSE;
Derek Allard2067d1a2008-11-13 22:59:24 +0000382 }
383}
384
385// --------------------------------------------------------------------
386
387/**
388 * Symbolic Permissions
389 *
390 * Takes a numeric value representing a file's permissions and returns
391 * standard symbolic notation representing that value
392 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000393 * @param int
394 * @return string
Barry Mienydd671972010-10-04 16:33:58 +0200395 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000396if ( ! function_exists('symbolic_permissions'))
397{
398 function symbolic_permissions($perms)
Barry Mienydd671972010-10-04 16:33:58 +0200399 {
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200400 if (($perms & 0xC000) === 0xC000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000401 {
402 $symbolic = 's'; // Socket
403 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200404 elseif (($perms & 0xA000) === 0xA000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000405 {
406 $symbolic = 'l'; // Symbolic Link
407 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200408 elseif (($perms & 0x8000) === 0x8000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000409 {
410 $symbolic = '-'; // Regular
411 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200412 elseif (($perms & 0x6000) === 0x6000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000413 {
414 $symbolic = 'b'; // Block special
415 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200416 elseif (($perms & 0x4000) === 0x4000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000417 {
418 $symbolic = 'd'; // Directory
419 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200420 elseif (($perms & 0x2000) === 0x2000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000421 {
422 $symbolic = 'c'; // Character special
423 }
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200424 elseif (($perms & 0x1000) === 0x1000)
Derek Allard2067d1a2008-11-13 22:59:24 +0000425 {
426 $symbolic = 'p'; // FIFO pipe
427 }
428 else
429 {
430 $symbolic = 'u'; // Unknown
431 }
432
433 // Owner
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200434 $symbolic .= (($perms & 0x0100) ? 'r' : '-')
435 . (($perms & 0x0080) ? 'w' : '-')
436 . (($perms & 0x0040) ? (($perms & 0x0800) ? 's' : 'x' ) : (($perms & 0x0800) ? 'S' : '-'));
Derek Allard2067d1a2008-11-13 22:59:24 +0000437
438 // Group
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200439 $symbolic .= (($perms & 0x0020) ? 'r' : '-')
440 . (($perms & 0x0010) ? 'w' : '-')
441 . (($perms & 0x0008) ? (($perms & 0x0400) ? 's' : 'x' ) : (($perms & 0x0400) ? 'S' : '-'));
Derek Allard2067d1a2008-11-13 22:59:24 +0000442
443 // World
Andrey Andreev8bf6bb62012-01-06 16:11:04 +0200444 $symbolic .= (($perms & 0x0004) ? 'r' : '-')
445 . (($perms & 0x0002) ? 'w' : '-')
446 . (($perms & 0x0001) ? (($perms & 0x0200) ? 't' : 'x' ) : (($perms & 0x0200) ? 'T' : '-'));
Derek Allard2067d1a2008-11-13 22:59:24 +0000447
Barry Mienydd671972010-10-04 16:33:58 +0200448 return $symbolic;
Derek Allard2067d1a2008-11-13 22:59:24 +0000449 }
450}
451
452// --------------------------------------------------------------------
453
454/**
455 * Octal Permissions
456 *
457 * Takes a numeric value representing a file's permissions and returns
458 * a three character string representing the file's octal permissions
459 *
Derek Allard2067d1a2008-11-13 22:59:24 +0000460 * @param int
461 * @return string
Barry Mienydd671972010-10-04 16:33:58 +0200462 */
Derek Allard2067d1a2008-11-13 22:59:24 +0000463if ( ! function_exists('octal_permissions'))
464{
465 function octal_permissions($perms)
466 {
467 return substr(sprintf('%o', $perms), -3);
468 }
469}
470
Derek Allard2067d1a2008-11-13 22:59:24 +0000471/* End of file file_helper.php */
Andrey Andreevb2518642012-03-26 21:44:08 +0300472/* Location: ./system/helpers/file_helper.php */