How do I run PHP as a CGI to avoid safe_mode restrictions?
Running PHP as a CGI is usually done when PHP is not available on your server (but you can execute cgi-bin scripts) or when the normal PHP installation is running in safe mode. Note that in order for this to work, your server must be configured to read .htaccess files, which your host can disable! • Obtain a CGI version of PHP for your platform. You can downloads PHP binaries for various platforms on the Gallery Download Page. If you can’t find a binary for your platform, but you have access to compile programs, you can configure PHP with this configure line. ./configure –enable-force-cgi-redirect –disable-safe-mode –with-config-file-path=/usr/local/lib/php-cgi Then run make. The resulting binary will be called php in the sapi/cgi/ directory of the PHP source. Please submit the binary to alindeman, so he can include it on the download page. Please only submit binaries that use that exact configure line, for consistancy reasons.
Running PHP as a CGI is usually done when PHP is not available on your server (but you can execute cgi-bin scripts) or when the normal PHP installation is running in safe mode. Note that in order for this to work, your server must be configured to read .htaccess files, which your host can disable! • Obtain a CGI version of PHP for your platform. You can downloads PHP binaries for various platforms on the Gallery Download Page. If you can’t find a binary for your platform, but you have access to compile programs, you can configure PHP with this configure line. ./configure –enable-force-cgi-redirect –disable-safe-mode –with-config-file-path=/usr/local/lib/php-cgi Then run make. The resulting binary will be called php in the sapi/cgi/ directory of the PHP source. Please submit the binary to alindeman, so he can include it on the download page. Please only submit binaries that use that exact configure line, for consistancy reasons. • Upload the CGI version of PHP to the cgi-bin director