[Mapserver-users] Mapserver crashing with PHP/Mapscript when...
P Wilkerson
1wilkerson at charter.net
Tue Jun 1 05:13:31 PDT 2004
Strangely, the script works fine on my MS4W install on a localhost computer
but not at a hosted site. What compilation parameters should I look at to
see if they are different?
Peter
----- Original Message -----
From: "P Wilkerson" <1wilkerson at charter.net>
To: <mapserver-users at lists.gis.umn.edu>
Sent: Tuesday, June 01, 2004 2:57 AM
Subject: [Mapserver-users] Mapserver crashing with PHP/Mapscript when...
> I am modifying the GMapDumpQueryResults function in GMap75.inc of the
GMap75
> demo (latest version)
>
> Mapserver stops when I add code to interact with the output from the SHP
> files.
>
> I cannot add new variables. I cannot IF statements. I cannot do much at
> all without causing the application to stop.
>
> By stopping I mean that the Mapserver program does not generate a map and
> ceases outputting the rest of the HTML page.
>
> Layer Name - layer01
> There are only two fields ITEM_NBR and TITLE.
>
> I am placing my code within the following FOR Loop of the
> GMapDumpQueryResults() function.
>
> for ($iField=0; $iField < count($selFields); $iField++)
> {
> < Some code in addition to mine >
> < --------- start of my
> code ------------------------->
> // TO OUTPUT FOR THUMBNAIL
> IF ($oLayer->getMetaData("DESCRIPTION") ==
> "layer01") {
> IF ($selFields[$iField] == "ITEM_NBR") {
> $oShapeVal04 =
> $oShape->values[$selFields[$iField]];
> printf('%s', '<img id="thumbnail_image"
> src="../data/images/imagefiles/'.$oShapeVal04.'.thumb.png"
> alt="thumbnail image">');
> }
> }
> // TO OUTPUT HREF FOR RELATED PAGE
> IF (($selFields[$iField] == "TITLE") ) {
> $dlconnectionstr = "http://LocalhostTest:";
> $imgIDVal =
> $oShape->values[$selFields[$iField]];
> $dlsource = substr($imgIDVal,0,3);
> if ($dlsource == "PLW") {
> $dlconnectionstr =
> $dlconnectionstr."PLW:";
> }
> ELSE
> IF ($dlsource == "GAD") {
> $dlconnectionstr =
> $dlconnectionstr."GAD:";
> }
>
> $oShapeVal03 =
> oShape->values[$selFields[$iField]];
> printf('%s', '<a
href="javascript:openClean(');
> printf("%s", "'".$dlconnectionstr);
> printf("%s", $oShapeVal03."');");
> printf('">');
> }
>
> // OUTPUTS FIELD VALUE EXCEPT FOR ITEM_NBR FIELD
> IF (! ($selFields[$iField] == "ITEM_NBR") )
> printf("%s",
> $oShape->values[$selFields[$iField]]);
>
> // CLOSES HREF IF TITLE FIELD
> IF (($selFields[$iField] == "TITLE") ) {
> printf("</A>");
> }
> < --------- end of my
code ------------------------->
> < Code in addition to mine >
> }
>
> Again, the problem is that the program stops generating HTML / image files
> when I start manipulating the variables.
>
> Any suggestions?
>
> Peter Wilkerson
>
> _______________________________________________
> Mapserver-users mailing list
> Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
More information about the MapServer-users
mailing list