Quick Install Instructions For P.mapper 3.2: PHP Settings
Quick Install Instructions For P.mapper 3.2: PHP Settings
Quick Install Instructions For P.mapper 3.2: PHP Settings
1. Documentation
2. FAQ
3. User Portal
1. Use of this Wiki and Ticket system
PHP Settings
PHP/MapScript Library and WebServer
p.mapper in the current version requires PHP 5. If you want to run p.mapper on PHP 4 you need to use
the older version 3.0.
Install the PHP/MapScript library in the appropriate place and configure your webserver to parse *.php
and *.phtml files with PHP.
LIBICONV
PHP needs to be compiled with support of the ICONV library. This should be the default on Windows and
Unix versions of PHP
PHP.INI
enable_dl = On
alternatively: load the Mapscript extension via the php.ini. This is also the required method on Windows
both for IIS and Apache running PHP as module.
The application uses PHP sessions to store user settings during the session. Modify the php.ini file to
the following settings below section [Session]:
1
Using cookies for sessions
In most cases it is recommended to disable the usage of cookies for session handling. You achieve this
by the following setting
session.use_cookies = 0
For a more detailed discussion about this setting please see the FAQ
Settings for security As with all PHP installations it is strongly recommended to disable both
register_globals and allow_url_include (allow_url_fopen before PHP 5.2) to avoid
potential cross side scripting attacks:
register_globals = Off
allow_url_include = Off
Note that register_globals is set to Off by default and its dangerous activation needs an active input
by the system admin. Since v3.2 there are additional checks to prevent code insertion in case of very
weak PHP security settings that are against any [recommendations].
Application settings
config/config_default.ini The main configuration for p.mapper is set under the subdirectory config in
the file config.ini. Adapt following mandatory settings to your environment:
General rule: if a layer belongs to a group, use the group name, otherwise use the layer name. Layer
and group names must not have spaces.
Other settings
Directory /images/legend/
This directory has to be writeable for the user that runs the web server (used for automatic update of
legend icons). Important
On a Debian system for example, this could be achieved with the command
2
On Windows and IIS set the directory security properties to 'Modify' for user IUSR_hostname
Demo data
You can download the demo dataset (pmapper-demodata-3.zip) and test p.mapper with the supplied
map file pmapper_demo.map.
Map file
MAP
SHAPEPATH
(FONTSET)
(SYMBOLSET)
WEB
IMAGEPATH
IMAGEURL
Start p.mapper
Starting p.mapper can be done via the map.phtml file or a link from index.html.