Revision 4174 org.gvsig.raster.wms/trunk/org.gvsig.raster.wms/org.gvsig.raster.wms.remoteclient/src/main/java/org/gvsig/remoteclient/wms/WMSProtocolHandler.java

View differences:

WMSProtocolHandler.java
322 322
    	throws ServerErrorException, WMSException {
323 323
    	URL request = null;
324 324
		try {
325
			status.setOnlineResource(status.getOnlineResource().replaceAll(" ", "%20"));
325 326
			request = new URL(buildGetLegendGraphicRequest(status, layerName));
326 327
                        logger.info(request.toString());
327 328
            File f = Utilities.downloadFile(request, "wmsGetLegendGraphic", cancel);
......
375 376
    		while (it.hasNext()){
376 377
    			sty = (WMSStyle) it.next();
377 378
    			if (sty.getName().equals(status.getStyles().get(0).toString())){    				
378
    				return sty.getLegendURLOnlineResourceHRef();
379
    				return sty.getLegendURLOnlineResourceHRef().replaceAll(" ", "%20");
379 380
    			}
380 381
    		}
381 382
    	}

Also available in: Unified diff