Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
litespeed_wiki:php:uploadprogress_bar [2010/02/02 06:29] 127.0.0.1 external edit |
litespeed_wiki:php:uploadprogress_bar [2018/09/17 19:35] (current) Michael Alegre |
||
---|---|---|---|
Line 1: | Line 1: | ||
- | ''PECL package "[[http://pecl.php.net/package/uploadprogress|uploadprogress]]" is an PHP extension to track progress of a file upload.'' | + | #REDIRECT archive:php:uploadprogress_bar |
- | + | ||
- | ''In the website, it states "It is only known to work on Apache with mod_php, other SAPI implementations unfortunately still have issues. At least PHP 5.2 is needed."'' | + | |
- | + | ||
- | ''We tested, the extension also works with Litespeed since 4.1.'' | + | |
- | + | ||
- | test environment: | + | |
- | + | ||
- | Litespeed 4.1RC2 | + | |
- | PHP 5.3.1 + LSAPI 5.2 | + | |
- | uploadprogress 1.0.1 | + | |
- | + | ||
- | Steps: | + | |
- | + | ||
- | ==== 1.build PHP 5.3.1 + LASPI 5.2 ==== | + | |
- | [[litespeed_wiki:php:lsapi|Install PHP 4/5 with LSAPI]] | + | |
- | ==== 2.build uploadprogress extension ==== | + | |
- | + | ||
- | + | ||
- | + | ||
- | ~>wget http://pecl.php.net/get/uploadprogress-1.0.1.tgz | + | |
- | ~>tar zxvf uploadprogress-1.0.1.tgz | + | |
- | ~>cd uploadprogress-1.0.1 | + | |
- | ~/uploadprogress-1.0.1>/php5install/php5/bin/phpize | + | |
- | ~/uploadprogress-1.0.1>./configure --enable-uploadprogress --with-php-config=/php5install/php5/bin/php-config | + | |
- | ~/uploadprogress-1.0.1>make | + | |
- | ~/uploadprogress-1.0.1>make install | + | |
- | + | ||
- | in php.ini, add | + | |
- | + | ||
- | extension=uploadprogress.so | + | |
- | + | ||
- | ==== 3. start to test ==== | + | |
- | + | ||
- | ~/uploadprogress-1.0.1>cp -r examples /path/to/DocumentRoot | + | |
- | + | ||
- | test url: | + | |
- | + | ||
- | yourdomain.com/examples/index.php | + | |
- | + | ||
- | ==== 4.File Uploads Configuration Options ==== | + | |
- | + | ||
- | in PHP, refer http://www.php.net/manual/en/ini.core.php#ini.upload-max-filesize | + | |
- | + | ||
- | ^Name^Default^Changeable^Changelog^ | + | |
- | |file_uploads|"1"|PHP_INI_SYSTEM|PHP_INI_ALL in PHP <= 4.2.3. Available since PHP 4.0.3| | + | |
- | |upload_tmp_dir|NULL|PHP_INI_SYSTEM| | | + | |
- | |upload_max_filesize|"2M"|PHP_INI_PERDIR|PHP_INI_ALL in PHP <= 4.2.3| | + | |
- | |max_file_uploads|20|PHP_INI_ALL|Available since PHP 5.2.1| | + | |
- | |post_max_size|"8M"|PHP_INI_PERDIR|PHP_INI_SYSTEM in PHP <= 4.2.3. Available since PHP 4.0.3| | + | |
- | + | ||
- | in Litespeed: | + | |
- | + | ||
- | Server-->Tuning-->Max Request Body Size (bytes) | + |