Change dynamically Style on wms layer

Using mergeNewParams:


        wmsLayer.mergeNewParams({
            'styles': 'dist_servicios1'
        });

Or editing the params object:


    wmsLayer.params['STYLES'] = 'dist_servicios1';
    wmsLayer.redraw();

Advertisements