[Mapbender-commits] r8534 - trunk/mapbender/http/classes
svn_mapbender at osgeo.org
svn_mapbender at osgeo.org
Tue Dec 18 07:12:38 PST 2012
Author: armin11
Date: 2012-12-18 07:12:37 -0800 (Tue, 18 Dec 2012)
New Revision: 8534
Modified:
trunk/mapbender/http/classes/class_wmc.php
Log:
Bugfix for legends of owsproxy
Modified: trunk/mapbender/http/classes/class_wmc.php
===================================================================
--- trunk/mapbender/http/classes/class_wmc.php 2012-12-18 14:34:20 UTC (rev 8533)
+++ trunk/mapbender/http/classes/class_wmc.php 2012-12-18 15:12:37 UTC (rev 8534)
@@ -584,11 +584,13 @@
$layer->Server->OnlineResource->attributes('xlink', true)->href = $wmsGetMapUrl;
//Help for problem with xlink:href attributes: http://php.net/manual/de/class.simplexmlelement.php!!!!!
//exchange legend urls
- if (isset($row["wms_owsproxy"]) && $row["wms_owsproxy"] != '') {
- $arURL = parse_url($layer->StyleList->Style->LegendURL->OnlineResource->attributes('xlink', true)->href);
- $query = $arURL["query"];
- $url = $wmsGetLegendUrl . $query;
- $layer->StyleList->Style->LegendURL->OnlineResource->attributes('xlink', true)->href = $url;
+ if (isset($row["wms_owsproxy"]) && $row["wms_owsproxy"] != '' && !is_null($row["wms_owsproxy"])) {
+ if($layer->StyleList->Style->LegendURL->OnlineResource){
+ $arURL = parse_url($layer->StyleList->Style->LegendURL->OnlineResource->attributes('xlink', true)->href);
+ $query = $arURL["query"];
+ $url = $wmsGetLegendUrl . $query;
+ $layer->StyleList->Style->LegendURL->OnlineResource->attributes('xlink', true)->href = $url;
+ }
}
}
}
More information about the Mapbender_commits
mailing list