blob: ac9323c087d4e32ab819e54d259024711c14ee5e [file] [log] [blame]
Derek Allard2067d1a2008-11-13 22:59:24 +00001<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
2/**
3 * CodeIgniter
4 *
5 * An open source application development framework for PHP 4.3.2 or newer
6 *
7 * @package CodeIgniter
8 * @author ExpressionEngine Dev Team
Derek Jones7f3719f2010-01-05 13:35:37 +00009 * @copyright Copyright (c) 2008 - 2010, EllisLab, Inc.
Derek Allard2067d1a2008-11-13 22:59:24 +000010 * @license http://codeigniter.com/user_guide/license.html
11 * @link http://codeigniter.com
12 * @since Version 1.0
13 * @filesource
14 */
15
16// ------------------------------------------------------------------------
17
18/**
19 * File Uploading Class
20 *
21 * @package CodeIgniter
22 * @subpackage Libraries
23 * @category Uploads
24 * @author ExpressionEngine Dev Team
25 * @link http://codeigniter.com/user_guide/libraries/file_uploading.html
26 */
27class CI_Upload {
28
29 var $max_size = 0;
30 var $max_width = 0;
31 var $max_height = 0;
32 var $max_filename = 0;
33 var $allowed_types = "";
34 var $file_temp = "";
35 var $file_name = "";
36 var $orig_name = "";
37 var $file_type = "";
38 var $file_size = "";
39 var $file_ext = "";
40 var $upload_path = "";
41 var $overwrite = FALSE;
42 var $encrypt_name = FALSE;
43 var $is_image = FALSE;
44 var $image_width = '';
45 var $image_height = '';
46 var $image_type = '';
47 var $image_size_str = '';
48 var $error_msg = array();
49 var $mimes = array();
50 var $remove_spaces = TRUE;
51 var $xss_clean = FALSE;
52 var $temp_prefix = "temp_file_";
53
54 /**
55 * Constructor
56 *
57 * @access public
58 */
59 function CI_Upload($props = array())
60 {
61 if (count($props) > 0)
62 {
63 $this->initialize($props);
64 }
65
66 log_message('debug', "Upload Class Initialized");
67 }
68
69 // --------------------------------------------------------------------
70
71 /**
72 * Initialize preferences
73 *
74 * @access public
75 * @param array
76 * @return void
77 */
78 function initialize($config = array())
79 {
80 $defaults = array(
81 'max_size' => 0,
82 'max_width' => 0,
83 'max_height' => 0,
84 'max_filename' => 0,
85 'allowed_types' => "",
86 'file_temp' => "",
87 'file_name' => "",
88 'orig_name' => "",
89 'file_type' => "",
90 'file_size' => "",
91 'file_ext' => "",
92 'upload_path' => "",
93 'overwrite' => FALSE,
94 'encrypt_name' => FALSE,
95 'is_image' => FALSE,
96 'image_width' => '',
97 'image_height' => '',
98 'image_type' => '',
99 'image_size_str' => '',
100 'error_msg' => array(),
101 'mimes' => array(),
102 'remove_spaces' => TRUE,
103 'xss_clean' => FALSE,
104 'temp_prefix' => "temp_file_"
105 );
106
107
108 foreach ($defaults as $key => $val)
109 {
110 if (isset($config[$key]))
111 {
112 $method = 'set_'.$key;
113 if (method_exists($this, $method))
114 {
115 $this->$method($config[$key]);
116 }
117 else
118 {
119 $this->$key = $config[$key];
120 }
121 }
122 else
123 {
124 $this->$key = $val;
125 }
126 }
127 }
128
129 // --------------------------------------------------------------------
130
131 /**
132 * Perform the file upload
133 *
134 * @access public
135 * @return bool
136 */
137 function do_upload($field = 'userfile')
138 {
139 // Is $_FILES[$field] set? If not, no reason to continue.
140 if ( ! isset($_FILES[$field]))
141 {
142 $this->set_error('upload_no_file_selected');
143 return FALSE;
144 }
145
146 // Is the upload path valid?
147 if ( ! $this->validate_upload_path())
148 {
149 // errors will already be set by validate_upload_path() so just return FALSE
150 return FALSE;
151 }
152
153 // Was the file able to be uploaded? If not, determine the reason why.
154 if ( ! is_uploaded_file($_FILES[$field]['tmp_name']))
155 {
156 $error = ( ! isset($_FILES[$field]['error'])) ? 4 : $_FILES[$field]['error'];
157
158 switch($error)
159 {
160 case 1: // UPLOAD_ERR_INI_SIZE
161 $this->set_error('upload_file_exceeds_limit');
162 break;
163 case 2: // UPLOAD_ERR_FORM_SIZE
164 $this->set_error('upload_file_exceeds_form_limit');
165 break;
166 case 3: // UPLOAD_ERR_PARTIAL
167 $this->set_error('upload_file_partial');
168 break;
169 case 4: // UPLOAD_ERR_NO_FILE
170 $this->set_error('upload_no_file_selected');
171 break;
172 case 6: // UPLOAD_ERR_NO_TMP_DIR
173 $this->set_error('upload_no_temp_directory');
174 break;
175 case 7: // UPLOAD_ERR_CANT_WRITE
176 $this->set_error('upload_unable_to_write_file');
177 break;
178 case 8: // UPLOAD_ERR_EXTENSION
179 $this->set_error('upload_stopped_by_extension');
180 break;
181 default : $this->set_error('upload_no_file_selected');
182 break;
183 }
184
185 return FALSE;
186 }
187
188 // Set the uploaded data as class variables
189 $this->file_temp = $_FILES[$field]['tmp_name'];
Derek Allard3343f462009-02-18 01:29:50 +0000190 $this->file_name = $this->_prep_filename($_FILES[$field]['name']);
Derek Allard2067d1a2008-11-13 22:59:24 +0000191 $this->file_size = $_FILES[$field]['size'];
192 $this->file_type = preg_replace("/^(.+?);.*$/", "\\1", $_FILES[$field]['type']);
193 $this->file_type = strtolower($this->file_type);
194 $this->file_ext = $this->get_extension($_FILES[$field]['name']);
195
196 // Convert the file size to kilobytes
197 if ($this->file_size > 0)
198 {
199 $this->file_size = round($this->file_size/1024, 2);
200 }
201
202 // Is the file type allowed to be uploaded?
203 if ( ! $this->is_allowed_filetype())
204 {
205 $this->set_error('upload_invalid_filetype');
206 return FALSE;
207 }
208
209 // Is the file size within the allowed maximum?
210 if ( ! $this->is_allowed_filesize())
211 {
212 $this->set_error('upload_invalid_filesize');
213 return FALSE;
214 }
215
216 // Are the image dimensions within the allowed size?
217 // Note: This can fail if the server has an open_basdir restriction.
218 if ( ! $this->is_allowed_dimensions())
219 {
220 $this->set_error('upload_invalid_dimensions');
221 return FALSE;
222 }
223
224 // Sanitize the file name for security
225 $this->file_name = $this->clean_file_name($this->file_name);
226
227 // Truncate the file name if it's too long
228 if ($this->max_filename > 0)
229 {
230 $this->file_name = $this->limit_filename_length($this->file_name, $this->max_filename);
231 }
232
233 // Remove white spaces in the name
234 if ($this->remove_spaces == TRUE)
235 {
236 $this->file_name = preg_replace("/\s+/", "_", $this->file_name);
237 }
238
239 /*
240 * Validate the file name
241 * This function appends an number onto the end of
242 * the file if one with the same name already exists.
243 * If it returns false there was a problem.
244 */
245 $this->orig_name = $this->file_name;
246
247 if ($this->overwrite == FALSE)
248 {
249 $this->file_name = $this->set_filename($this->upload_path, $this->file_name);
250
251 if ($this->file_name === FALSE)
252 {
253 return FALSE;
254 }
255 }
256
257 /*
258 * Move the file to the final destination
259 * To deal with different server configurations
260 * we'll attempt to use copy() first. If that fails
261 * we'll use move_uploaded_file(). One of the two should
262 * reliably work in most environments
263 */
264 if ( ! @copy($this->file_temp, $this->upload_path.$this->file_name))
265 {
266 if ( ! @move_uploaded_file($this->file_temp, $this->upload_path.$this->file_name))
267 {
268 $this->set_error('upload_destination_error');
269 return FALSE;
270 }
271 }
272
273 /*
274 * Run the file through the XSS hacking filter
275 * This helps prevent malicious code from being
276 * embedded within a file. Scripts can easily
277 * be disguised as images or other file types.
278 */
279 if ($this->xss_clean == TRUE)
280 {
281 $this->do_xss_clean();
282 }
283
284 /*
285 * Set the finalized image dimensions
286 * This sets the image width/height (assuming the
287 * file was an image). We use this information
288 * in the "data" function.
289 */
290 $this->set_image_properties($this->upload_path.$this->file_name);
291
292 return TRUE;
293 }
294
295 // --------------------------------------------------------------------
296
297 /**
298 * Finalized Data Array
299 *
300 * Returns an associative array containing all of the information
301 * related to the upload, allowing the developer easy access in one array.
302 *
303 * @access public
304 * @return array
305 */
306 function data()
307 {
308 return array (
309 'file_name' => $this->file_name,
310 'file_type' => $this->file_type,
311 'file_path' => $this->upload_path,
312 'full_path' => $this->upload_path.$this->file_name,
313 'raw_name' => str_replace($this->file_ext, '', $this->file_name),
314 'orig_name' => $this->orig_name,
315 'file_ext' => $this->file_ext,
316 'file_size' => $this->file_size,
317 'is_image' => $this->is_image(),
318 'image_width' => $this->image_width,
319 'image_height' => $this->image_height,
320 'image_type' => $this->image_type,
321 'image_size_str' => $this->image_size_str,
322 );
323 }
324
325 // --------------------------------------------------------------------
326
327 /**
328 * Set Upload Path
329 *
330 * @access public
331 * @param string
332 * @return void
333 */
334 function set_upload_path($path)
335 {
336 // Make sure it has a trailing slash
337 $this->upload_path = rtrim($path, '/').'/';
338 }
339
340 // --------------------------------------------------------------------
341
342 /**
343 * Set the file name
344 *
345 * This function takes a filename/path as input and looks for the
346 * existence of a file with the same name. If found, it will append a
347 * number to the end of the filename to avoid overwriting a pre-existing file.
348 *
349 * @access public
350 * @param string
351 * @param string
352 * @return string
353 */
354 function set_filename($path, $filename)
355 {
356 if ($this->encrypt_name == TRUE)
357 {
358 mt_srand();
359 $filename = md5(uniqid(mt_rand())).$this->file_ext;
360 }
361
362 if ( ! file_exists($path.$filename))
363 {
364 return $filename;
365 }
366
367 $filename = str_replace($this->file_ext, '', $filename);
368
369 $new_filename = '';
370 for ($i = 1; $i < 100; $i++)
371 {
372 if ( ! file_exists($path.$filename.$i.$this->file_ext))
373 {
374 $new_filename = $filename.$i.$this->file_ext;
375 break;
376 }
377 }
378
379 if ($new_filename == '')
380 {
381 $this->set_error('upload_bad_filename');
382 return FALSE;
383 }
384 else
385 {
386 return $new_filename;
387 }
388 }
389
390 // --------------------------------------------------------------------
391
392 /**
393 * Set Maximum File Size
394 *
395 * @access public
396 * @param integer
397 * @return void
398 */
399 function set_max_filesize($n)
400 {
401 $this->max_size = ((int) $n < 0) ? 0: (int) $n;
402 }
403
404 // --------------------------------------------------------------------
405
406 /**
407 * Set Maximum File Name Length
408 *
409 * @access public
410 * @param integer
411 * @return void
412 */
413 function set_max_filename($n)
414 {
415 $this->max_filename = ((int) $n < 0) ? 0: (int) $n;
416 }
417
418 // --------------------------------------------------------------------
419
420 /**
421 * Set Maximum Image Width
422 *
423 * @access public
424 * @param integer
425 * @return void
426 */
427 function set_max_width($n)
428 {
429 $this->max_width = ((int) $n < 0) ? 0: (int) $n;
430 }
431
432 // --------------------------------------------------------------------
433
434 /**
435 * Set Maximum Image Height
436 *
437 * @access public
438 * @param integer
439 * @return void
440 */
441 function set_max_height($n)
442 {
443 $this->max_height = ((int) $n < 0) ? 0: (int) $n;
444 }
445
446 // --------------------------------------------------------------------
447
448 /**
449 * Set Allowed File Types
450 *
451 * @access public
452 * @param string
453 * @return void
454 */
455 function set_allowed_types($types)
456 {
Derek Jonese12f64e2010-03-02 22:55:08 -0600457 if ( ! is_array($types) && $types == '*')
458 {
459 $this->allowed_types = '*';
460 return;
461 }
Derek Allard2067d1a2008-11-13 22:59:24 +0000462 $this->allowed_types = explode('|', $types);
463 }
464
465 // --------------------------------------------------------------------
466
467 /**
468 * Set Image Properties
469 *
470 * Uses GD to determine the width/height/type of image
471 *
472 * @access public
473 * @param string
474 * @return void
475 */
476 function set_image_properties($path = '')
477 {
478 if ( ! $this->is_image())
479 {
480 return;
481 }
482
483 if (function_exists('getimagesize'))
484 {
485 if (FALSE !== ($D = @getimagesize($path)))
486 {
487 $types = array(1 => 'gif', 2 => 'jpeg', 3 => 'png');
488
489 $this->image_width = $D['0'];
490 $this->image_height = $D['1'];
491 $this->image_type = ( ! isset($types[$D['2']])) ? 'unknown' : $types[$D['2']];
492 $this->image_size_str = $D['3']; // string containing height and width
493 }
494 }
495 }
496
497 // --------------------------------------------------------------------
498
499 /**
500 * Set XSS Clean
501 *
502 * Enables the XSS flag so that the file that was uploaded
503 * will be run through the XSS filter.
504 *
505 * @access public
506 * @param bool
507 * @return void
508 */
509 function set_xss_clean($flag = FALSE)
510 {
511 $this->xss_clean = ($flag == TRUE) ? TRUE : FALSE;
512 }
513
514 // --------------------------------------------------------------------
515
516 /**
517 * Validate the image
518 *
519 * @access public
520 * @return bool
521 */
522 function is_image()
523 {
524 // IE will sometimes return odd mime-types during upload, so here we just standardize all
525 // jpegs or pngs to the same file type.
526
527 $png_mimes = array('image/x-png');
528 $jpeg_mimes = array('image/jpg', 'image/jpe', 'image/jpeg', 'image/pjpeg');
529
530 if (in_array($this->file_type, $png_mimes))
531 {
532 $this->file_type = 'image/png';
533 }
534
535 if (in_array($this->file_type, $jpeg_mimes))
536 {
537 $this->file_type = 'image/jpeg';
538 }
539
540 $img_mimes = array(
541 'image/gif',
542 'image/jpeg',
543 'image/png',
544 );
545
546 return (in_array($this->file_type, $img_mimes, TRUE)) ? TRUE : FALSE;
547 }
548
549 // --------------------------------------------------------------------
550
551 /**
552 * Verify that the filetype is allowed
553 *
554 * @access public
555 * @return bool
556 */
557 function is_allowed_filetype()
558 {
Derek Jonese12f64e2010-03-02 22:55:08 -0600559 if ($this->allowed_types == '*')
560 {
561 return TRUE;
562 }
563
Derek Allard2067d1a2008-11-13 22:59:24 +0000564 if (count($this->allowed_types) == 0 OR ! is_array($this->allowed_types))
565 {
566 $this->set_error('upload_no_file_types');
567 return FALSE;
568 }
Derek Jonesafa282f2009-02-10 17:11:52 +0000569
570 $image_types = array('gif', 'jpg', 'jpeg', 'png', 'jpe');
571
Derek Allard2067d1a2008-11-13 22:59:24 +0000572 foreach ($this->allowed_types as $val)
573 {
574 $mime = $this->mimes_types(strtolower($val));
Derek Jonesafa282f2009-02-10 17:11:52 +0000575
576 // Images get some additional checks
577 if (in_array($val, $image_types))
578 {
579 if (getimagesize($this->file_temp) === FALSE)
580 {
581 return FALSE;
582 }
583 }
584
Derek Allard2067d1a2008-11-13 22:59:24 +0000585 if (is_array($mime))
586 {
587 if (in_array($this->file_type, $mime, TRUE))
588 {
589 return TRUE;
590 }
591 }
592 else
593 {
594 if ($mime == $this->file_type)
595 {
596 return TRUE;
597 }
598 }
599 }
600
601 return FALSE;
602 }
603
604 // --------------------------------------------------------------------
605
606 /**
607 * Verify that the file is within the allowed size
608 *
609 * @access public
610 * @return bool
611 */
612 function is_allowed_filesize()
613 {
614 if ($this->max_size != 0 AND $this->file_size > $this->max_size)
615 {
616 return FALSE;
617 }
618 else
619 {
620 return TRUE;
621 }
622 }
623
624 // --------------------------------------------------------------------
625
626 /**
627 * Verify that the image is within the allowed width/height
628 *
629 * @access public
630 * @return bool
631 */
632 function is_allowed_dimensions()
633 {
634 if ( ! $this->is_image())
635 {
636 return TRUE;
637 }
638
639 if (function_exists('getimagesize'))
640 {
641 $D = @getimagesize($this->file_temp);
642
643 if ($this->max_width > 0 AND $D['0'] > $this->max_width)
644 {
645 return FALSE;
646 }
647
648 if ($this->max_height > 0 AND $D['1'] > $this->max_height)
649 {
650 return FALSE;
651 }
652
653 return TRUE;
654 }
655
656 return TRUE;
657 }
658
659 // --------------------------------------------------------------------
660
661 /**
662 * Validate Upload Path
663 *
664 * Verifies that it is a valid upload path with proper permissions.
665 *
666 *
667 * @access public
668 * @return bool
669 */
670 function validate_upload_path()
671 {
672 if ($this->upload_path == '')
673 {
674 $this->set_error('upload_no_filepath');
675 return FALSE;
676 }
677
678 if (function_exists('realpath') AND @realpath($this->upload_path) !== FALSE)
679 {
680 $this->upload_path = str_replace("\\", "/", realpath($this->upload_path));
681 }
682
683 if ( ! @is_dir($this->upload_path))
684 {
685 $this->set_error('upload_no_filepath');
686 return FALSE;
687 }
688
689 if ( ! is_really_writable($this->upload_path))
690 {
691 $this->set_error('upload_not_writable');
692 return FALSE;
693 }
694
695 $this->upload_path = preg_replace("/(.+?)\/*$/", "\\1/", $this->upload_path);
696 return TRUE;
697 }
698
699 // --------------------------------------------------------------------
700
701 /**
702 * Extract the file extension
703 *
704 * @access public
705 * @param string
706 * @return string
707 */
708 function get_extension($filename)
709 {
710 $x = explode('.', $filename);
711 return '.'.end($x);
712 }
713
714 // --------------------------------------------------------------------
715
716 /**
717 * Clean the file name for security
718 *
719 * @access public
720 * @param string
721 * @return string
722 */
723 function clean_file_name($filename)
724 {
725 $bad = array(
726 "<!--",
727 "-->",
728 "'",
729 "<",
730 ">",
731 '"',
732 '&',
733 '$',
734 '=',
735 ';',
736 '?',
737 '/',
738 "%20",
739 "%22",
740 "%3c", // <
741 "%253c", // <
742 "%3e", // >
743 "%0e", // >
744 "%28", // (
745 "%29", // )
746 "%2528", // (
747 "%26", // &
748 "%24", // $
749 "%3f", // ?
750 "%3b", // ;
751 "%3d" // =
752 );
753
754 $filename = str_replace($bad, '', $filename);
755
756 return stripslashes($filename);
757 }
758
759 // --------------------------------------------------------------------
760
761 /**
762 * Limit the File Name Length
763 *
764 * @access public
765 * @param string
766 * @return string
767 */
768 function limit_filename_length($filename, $length)
769 {
770 if (strlen($filename) < $length)
771 {
772 return $filename;
773 }
774
775 $ext = '';
776 if (strpos($filename, '.') !== FALSE)
777 {
778 $parts = explode('.', $filename);
779 $ext = '.'.array_pop($parts);
780 $filename = implode('.', $parts);
781 }
782
783 return substr($filename, 0, ($length - strlen($ext))).$ext;
784 }
785
786 // --------------------------------------------------------------------
787
788 /**
789 * Runs the file through the XSS clean function
790 *
791 * This prevents people from embedding malicious code in their files.
792 * I'm not sure that it won't negatively affect certain files in unexpected ways,
793 * but so far I haven't found that it causes trouble.
794 *
795 * @access public
796 * @return void
797 */
798 function do_xss_clean()
799 {
800 $file = $this->upload_path.$this->file_name;
801
802 if (filesize($file) == 0)
803 {
804 return FALSE;
805 }
806
807 if (($data = @file_get_contents($file)) === FALSE)
808 {
809 return FALSE;
810 }
811
812 if ( ! $fp = @fopen($file, FOPEN_READ_WRITE))
813 {
814 return FALSE;
815 }
816
817 $CI =& get_instance();
Derek Jonese12f64e2010-03-02 22:55:08 -0600818 $data = $CI->security->xss_clean($data);
Derek Allard2067d1a2008-11-13 22:59:24 +0000819
820 flock($fp, LOCK_EX);
821 fwrite($fp, $data);
822 flock($fp, LOCK_UN);
823 fclose($fp);
824 }
825
826 // --------------------------------------------------------------------
827
828 /**
829 * Set an error message
830 *
831 * @access public
832 * @param string
833 * @return void
834 */
835 function set_error($msg)
836 {
837 $CI =& get_instance();
838 $CI->lang->load('upload');
839
840 if (is_array($msg))
841 {
842 foreach ($msg as $val)
843 {
844 $msg = ($CI->lang->line($val) == FALSE) ? $val : $CI->lang->line($val);
845 $this->error_msg[] = $msg;
846 log_message('error', $msg);
847 }
848 }
849 else
850 {
851 $msg = ($CI->lang->line($msg) == FALSE) ? $msg : $CI->lang->line($msg);
852 $this->error_msg[] = $msg;
853 log_message('error', $msg);
854 }
855 }
856
857 // --------------------------------------------------------------------
858
859 /**
860 * Display the error message
861 *
862 * @access public
863 * @param string
864 * @param string
865 * @return string
866 */
867 function display_errors($open = '<p>', $close = '</p>')
868 {
869 $str = '';
870 foreach ($this->error_msg as $val)
871 {
872 $str .= $open.$val.$close;
873 }
874
875 return $str;
876 }
877
878 // --------------------------------------------------------------------
879
880 /**
881 * List of Mime Types
882 *
883 * This is a list of mime types. We use it to validate
884 * the "allowed types" set by the developer
885 *
886 * @access public
887 * @param string
888 * @return string
889 */
890 function mimes_types($mime)
891 {
892 global $mimes;
893
894 if (count($this->mimes) == 0)
895 {
896 if (@require_once(APPPATH.'config/mimes'.EXT))
897 {
898 $this->mimes = $mimes;
899 unset($mimes);
900 }
901 }
902
903 return ( ! isset($this->mimes[$mime])) ? FALSE : $this->mimes[$mime];
904 }
905
906 // --------------------------------------------------------------------
907
908 /**
909 * Prep Filename
910 *
911 * Prevents possible script execution from Apache's handling of files multiple extensions
912 * http://httpd.apache.org/docs/1.3/mod/mod_mime.html#multipleext
913 *
914 * @access private
915 * @param string
916 * @return string
917 */
918 function _prep_filename($filename)
919 {
920 if (strpos($filename, '.') === FALSE)
921 {
922 return $filename;
923 }
Derek Allard616dab82009-02-16 15:44:32 +0000924
Derek Allard2067d1a2008-11-13 22:59:24 +0000925 $parts = explode('.', $filename);
926 $ext = array_pop($parts);
927 $filename = array_shift($parts);
Derek Allard616dab82009-02-16 15:44:32 +0000928
Derek Allard2067d1a2008-11-13 22:59:24 +0000929 foreach ($parts as $part)
930 {
931 if ($this->mimes_types(strtolower($part)) === FALSE)
932 {
933 $filename .= '.'.$part.'_';
934 }
935 else
936 {
937 $filename .= '.'.$part;
938 }
939 }
Derek Allardd70b0642009-02-16 13:51:42 +0000940
Derek Allard616dab82009-02-16 15:44:32 +0000941 // file name override, since the exact name is provided, no need to
942 // run it through a $this->mimes check.
Derek Allardd70b0642009-02-16 13:51:42 +0000943 if ($this->file_name != '')
944 {
945 $filename = $this->file_name;
946 }
947
Derek Allard2067d1a2008-11-13 22:59:24 +0000948 $filename .= '.'.$ext;
949
950 return $filename;
951 }
952
953 // --------------------------------------------------------------------
954
955}
956// END Upload Class
957
958/* End of file Upload.php */
Derek Jonesa3ffbbb2008-05-11 18:18:29 +0000959/* Location: ./system/libraries/Upload.php */