Ruby mapscript oddness

The Cunctator cunctator at GMAIL.COM
Fri Nov 17 14:09:48 EST 2006


I'm happy to give settings/sample files etc but maybe someone has some idea
what my problem is -- I'm guessing it has to do with the installation.

The following script:

#!/usr/bin/env ruby

require "mapscript"
include Mapscript

map=MapObj.new("test.map")
image = map.draw
image.save('test.png')

fails:

in `draw': msEvalExpresssion: Expression parser error. Failed to parse
expression;msyyparse(): Expression parser error. syntax
error;msEvalExpression: Expression parser error. Failed to parse
expression;msyyparse():
...

etc.

whereas the php script

<?php
if(!extension_loaded("MapScript")) {
   dl('php_mapscript.'.PHP_SHLIB_SUFFIX);
}

$map = ms_newMapObj("test.map");

$image = $map->draw();
$image->saveImage('test.png');

?>

works fine.

map.drawLegend
and
map.drawScalebar
work fine.

Anyone have thoughts or what information would people need to diagnose?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/mapserver-users/attachments/20061117/afd65ab5/attachment.html


More information about the mapserver-users mailing list