[Mapserver-users] Perl/MapScript or PHP/Mapscript

Sean Gillies sgillies at frii.com
Fri Jun 4 11:05:43 EDT 2004


On Jun 3, 2004, at 11:44 PM, Alexander Lim wrote:

> Hi all,
>
> I just getting started and realised that we can make
> use of Perl/MapScript and PHP/Mapscript, but i would
> like to know what's the differences and which one is
> "better" to use. And which one is more popular and
> more people are using it (This is for getting help
> from this list when i face some problem down the
> line). Does the two perform and is doing the same
> thing at all?
>
> which one should i adopt in terms of flexibility and
> features.
>
> please advice. thanks
>
> alex
>

Hi Alex,

The mapscript family tree looks like this:

                MapServer
                   /\
                  /  \
                 /    \
      PHP/MapScript    \
                        \  SWIG MapScript
                ---------+---------
                |        |         |
              Perl     Python    Ruby

The Perl, Python, Ruby flavors are like brothers and sisters and
the PHP MapScript is like a very close cousin to them.

They are all quite equal in mapping capability.  The Perl mapscript
does not quite work natively on Windows, but the others work equally
well across platforms.

There is no clear "better" choice.  It will depend on your needs.

The PHP language makes web programming easy, and this is the most
popular type of MapScript.  The DM Solutions Group uses PHP/Mapscript
primarily and have developed a bunch of great web mapping tools that
they share with PHP/Mapscript users.

   http://maptools.org/

They are also very good about answering questions on the users list, so
PHP/Mapscript has the best overall support.  One looming issue for
PHP/Mapscript is that there is currently no support for PHP 5.

On the other hand: Perl, Python, and Ruby are better and more complete
programming languages than PHP.  Each of these languages are great for
web programming.  The Ruby flavor of mapscript is very new, and is
being used in an application called MapDesk:

   http://www.sourcepole.com/mapdesk/

The Perl flavor of mapscript has been widely used, but isn't showing
much promise as a basis for apps like MapDesk.  I don't understand
why.

The Python flavor of mapscript is now the best supported of the
Perl/Python/Ruby family.  In my opinion, the strongest argument for
using Python/MapScript is that you can then also use the GDAL module
for Python.  This gives you the best access to many raster and
vector data formats.  If you are a windows user, you can download a
windows installer for Python Mapscript from

   http://users.frii.com/sgillies/projects/pymapscriptwin32.zip

It works right "out of the box" and batteries are included.

Hope this information helps you.  There are more options than you may
have expected!

cheers,
Sean

--
Sean Gillies
sgillies at frii dot com
http://users.frii.com/sgillies




More information about the mapserver-users mailing list