problem upgrade php-mapscript 4.0 to 4.1.1 $layer->open MyGis

Daniel Lagos dlagos at FDCCONSULT.COM
Fri Mar 4 05:49:47 PST 2005


Hi list,

I've recently been trying upgrade php-mapscript version 4.0 to 4 .4.1.

When I try to query clicking on one layer with connection type MYGIS I cannot get any data back from the feature data base table because I get error in function: 

$layer->open();

query code:
    
    $point = $this->createPoint($x,$y);
    @$q_object = $this->map->queryByPoint($point,MS_SINGLE,-1);
    $cur_layer = $this->map->getLayerByName($layerName);
    $res_layer = $cur_layer->getNumResults();
    
    if($res_layer)
    {
        $cur_layer->open(); <-------------------------------------------------------------------- The function error upgrade 4.0 to 4.4.1
        $cur_res = $cur_layer->getResult(0);
        $result = $cur_res->shapeindex;
        $cur_layer->close();
        return $result;
    }


Layer defined:

LAYER
    NAME "layer_10"
    TYPE POINT
    LABELMAXSCALE 100000
    STATUS OFF
    TOLERANCE 10
    CONNECTIONTYPE mygis
    CONNECTION "localhost:web:user_web:dbGis:bin:"
    DATA "geometry from G_Punto feature, G_Punto_bin geometry"

    TEMPLATE void
 
    CLASS
        NAME "class_1"  
        SYMBOL "symbol_5"
        TEXT ([nombre] - [sucursal])
        
        STYLE
            OUTLINECOLOR 0 0 0
            COLOR 0 0 255
            SIZE 18
            MINSIZE 8
           MAXSIZE 20
        END
        
        LABEL
            OUTLINECOLOR 255 255 255
            COLOR 127 0 0
            SIZE MEDIUM
            POSITION AUTO
            PARTIALS FALSE
        END
    END
END

The MapServer 4.4.1 released (2004-12-22) say: Fixed MyGIS build error introduced when adding msLayerIsOpen() (bug 1116). Is there some relations between the error and  the bug fixing?.

The old version php-mapscript 4.0 working fine with the same code.

I would be most grateful if anyone could offer any advise.

Thank's.

______________________________________
Daniel A. Lagos H.
Fernández y De Cea Ingenieros Ltda.
Av. Apoquindo 3650, Of. 902, Las Condes
Santiago, Chile
Tel:  +56 (2) 435 0099
Fax: +56 (2) 435 0258
www.fdcconsult.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20050304/dc7ad5a5/attachment.htm>


More information about the MapServer-users mailing list