[Mapbender-commits] r7461 - trunk/mapbender/http/php

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Thu Jan 20 03:06:02 EST 2011


Author: armin11
Date: 2011-01-20 00:06:02 -0800 (Thu, 20 Jan 2011)
New Revision: 7461

Modified:
   trunk/mapbender/http/php/mod_getWmcDisclaimer.php
   trunk/mapbender/http/php/mod_showMetadata.php
Log:
Bugfix in paths

Modified: trunk/mapbender/http/php/mod_getWmcDisclaimer.php
===================================================================
--- trunk/mapbender/http/php/mod_getWmcDisclaimer.php	2011-01-20 07:21:19 UTC (rev 7460)
+++ trunk/mapbender/http/php/mod_getWmcDisclaimer.php	2011-01-20 08:06:02 UTC (rev 7461)
@@ -105,10 +105,9 @@
 
 foreach($validWMS as $WMS) {
 	
-	echo $resourceSymbol." <a href='".$mapbenderBaseUrl.$_SERVER['SCRIPT_NAME']."/../php/mod_showMetadata.php?resource=wms&layout=tabs&id=".$WMS['id']."&languageCode=".$languageCode."'>".$WMS['title']."</a><br>";
-
-	$touServiceConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../../php/mod_getServiceDisclaimer.php?resource=wms&id=".$WMS['id']."&languageCode=".$languageCode."&asTable=true");
-	$wmstou .= $touServiceConnector->file;
+	echo $resourceSymbol." <a href='".$mapbenderBaseUrl.$_SERVER['SCRIPT_NAME']."/../mod_showMetadata.php?resource=wms&layout=tabs&id=".$WMS['id']."&languageCode=".$languageCode."'>".$WMS['title']."</a><br>";
+	$touServiceConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../mod_getServiceDisclaimer.php?type=wms&id=".$WMS['id']."&languageCode=".$languageCode."&asTable=true");
+	$wmstou = $touServiceConnector->file;
 	#$wmstou = file_get_contents("http://localhost/mapbender/php/mod_getServiceDisclaimer.php?resource=wms&id=".$WMS['id']."&languageCode=".$languageCode."&asTable=true");
 	echo $wmstou."<br>";
 }

Modified: trunk/mapbender/http/php/mod_showMetadata.php
===================================================================
--- trunk/mapbender/http/php/mod_showMetadata.php	2011-01-20 07:21:19 UTC (rev 7460)
+++ trunk/mapbender/http/php/mod_showMetadata.php	2011-01-20 08:06:02 UTC (rev 7461)
@@ -477,11 +477,11 @@
 	$resP = db_prep_query($sqlP, $vP, $tP);
 	$rowP = db_fetch_array($resP);
 	if ($rowP['layer_map_preview_filename'] != "") {
-		//$resourceMetadata['preview'] = "<img src = '".PREVIEW_DIR."/".$rowP['layer_map_preview_filename']."'>";
-		$resourceMetadata['preview'] = "<img src = '".$mapbenderBaseUrl.$_SERVER['SCRIPT_NAME']."/../../geoportal/mod_showPreview.php?resource=layer&id=".$layerId."'>";
+		$resourceMetadata['preview'] = "<img src = '../geoportal/mod_showPreview.php?resource=layer&id=".$layerId."'>";
+
 	}
 	if ($rowP['layer_legend_preview_filename'] != "") {
-		$resourceMetadata['legend'] .= "<img src = '".$mapbenderBaseUrl.$_SERVER['SCRIPT_NAME']."/../../geoportal/mod_showPreview.php?resource=layerlegend&id=".$layerId."'>";
+		$resourceMetadata['legend'] .= "<img src = '../geoportal/mod_showPreview.php?resource=layerlegend&id=".$layerId."'>";
 	}
 /*	if ($rowP['layer_extent_preview_filename'] != "") {
 		$resourceMetadata['extent'] .= "<img src = '../x_geoportal/layer_preview/".$rowP['layer_extent_preview_filename']."'>";
@@ -489,7 +489,7 @@
 	
 }
 if ($resource == 'wmc') {
-	$resourceMetadata['preview'] = "<img src = '".$mapbenderBaseUrl.$_SERVER['SCRIPT_NAME']."/../../geoportal/mod_showPreview.php?resource=wmc&id=".$resourceMetadata['contentid']."'>";
+	$resourceMetadata['preview'] = "<img src = '../geoportal/mod_showPreview.php?resource=wmc&id=".$resourceMetadata['contentid']."'>";
 }
 //db select for service quality
 if ($resource == 'wms' or $resource == 'layer') {
@@ -890,13 +890,13 @@
 }
 $html .= '<p>';
 if ($resource == 'wms' or $resource == 'layer') {
-	$touServiceConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../../php/mod_getServiceDisclaimer.php?resource=wms&id=".$resourceMetadata['serviceid']."&languageCode=".$languageCode."&asTable=true");
-	$tou .= $touServiceConnector->file;
+	$touServiceConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../mod_getServiceDisclaimer.php?resource=wms&id=".$resourceMetadata['serviceid']."&languageCode=".$languageCode."&asTable=true");
+	$tou = $touServiceConnector->file;
 }
 if ($resource == 'wmc' ) {
 	$e = new mb_exception("mod_showMetadata: wmcid for disclaimer: ".$resourceMetadata['contentid']);
-	$touWmcConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../../php/mod_getWmcDisclaimer.php?&id=".$resourceMetadata['contentid']."&languageCode=".$languageCode."&hostName=".$hostName);
-	$tou .= $touWmcConnector->file;
+	$touWmcConnector = new connector($mapbenderProtocol."localhost".$_SERVER['SCRIPT_NAME']."/../mod_getWmcDisclaimer.php?&id=".$resourceMetadata['contentid']."&languageCode=".$languageCode."&hostName=".$hostName);
+	$tou = $touWmcConnector->file;
 }
 
 $html .= $tou;



More information about the Mapbender_commits mailing list