[OpenLayers-Users] Error implement Style and Rules in WMS openlayer

fsalas fsalas at geocuba.cu
Wed Sep 9 13:17:26 EDT 2009


Hi, I like to make one filter using Openlayer Rule, and after that at result 
changed the style
But when I try to execute,  show this error "Openlayer.Style Is not a 
constructor "
My Openlayer version is 2.5

 var estilo = new OpenLayers.Style();

   var regla = new OpenLayers.Rule({
     filter: new OpenLayers.Filter.Comparison({
         type: OpenLayers.Filter.Comparison.EQUAL_TO,
         property: "tipo",
         value: 'FV',
      }),
   symbolizer: {pointRadius: 10, fillColor: "green",
               fillOpacity: 0.5, strokeColor: "black"}   });

   estilo.addRules([regla]);

     Sennales = new OpenLayers.Layer.WMS(
     "Señales","http://urano:3128/geoserver/wms",
     {
      layers: 'topp:sennal',
      srs: 'EPSG:4267',
      height: '557',
      styles: estilo,
      transparent: 'true',
      format: 'image/png'
     },
     {
        buffer: 0
     }
    );

Best , Regards
Salas





___________________________________
Dirección de Comunicaciones
Grupo Empresarial GEOCUBA
Este mensaje esta libre de virus. 
Revisado por Kaspersky Antivirus
----------------------------------------------------------------------
Definition count:  2513853
Definition date:  9/9/2009
SecurityPlus version: 3.0.5






More information about the Users mailing list