| 1 | = Instructions to install PHPMapScript on Fedora Core = |
| 2 | |
| 3 | These instructions were sent to mapserver-users by Lindsay C. Blanton: |
| 4 | |
| 5 | To get php_mapscript working properly on a Redhat Fedora box, I used the |
| 6 | following steps: |
| 7 | |
| 8 | 1. Download the php-devel rpm from Redhat and install |
| 9 | 2. Compile mapserver with the --with-php=/usr/include/php option |
| 10 | 3. Copy mapserv to /cgi-bin |
| 11 | 4. Copy the php_mapscript.so file into /usr/lib/php4/ |
| 12 | 5. Create a php wrapper script (php.sh) for the php cgi and save it |
| 13 | into /cgi/bin: |
| 14 | {{{ |
| 15 | #!/bin/bash |
| 16 | export SCRIPT_FILENAME=$PATH_TRANSLATED |
| 17 | /usr/bin/php |
| 18 | }}} |
| 19 | 6. Add the following action handlers for phtml (and/or .php) files in |
| 20 | httpd.conf |
| 21 | {{{ |
| 22 | Action phtml-script /cgi-bin/php.sh |
| 23 | AddHandler phtml-script .phtml |
| 24 | }}} |
| 25 | Now apache calls the php cgi for mapscript php files, and the php apache |
| 26 | module is called for everything else. |
| 27 | |
| 28 | Hope this helps someone out there using preinstalled Linux |
| 29 | distributions. |
| 30 | |