[Mapbender-commits] r8752 - in trunk/mapbender/http: geoportal php

svn_mapbender at osgeo.org svn_mapbender at osgeo.org
Wed Dec 11 11:13:34 PST 2013


Author: armin11
Date: 2013-12-11 11:13:34 -0800 (Wed, 11 Dec 2013)
New Revision: 8752

Modified:
   trunk/mapbender/http/geoportal/mod_pullInspireMonitoring.php
   trunk/mapbender/http/geoportal/mod_showInspireMonitoring.php
   trunk/mapbender/http/php/mod_dataISOMetadata.php
   trunk/mapbender/http/php/mod_validateInspire.php
Log:
Enable linking to metadata from INSPIRE catalogue

Modified: trunk/mapbender/http/geoportal/mod_pullInspireMonitoring.php
===================================================================
--- trunk/mapbender/http/geoportal/mod_pullInspireMonitoring.php	2013-12-11 17:53:20 UTC (rev 8751)
+++ trunk/mapbender/http/geoportal/mod_pullInspireMonitoring.php	2013-12-11 19:13:34 UTC (rev 8752)
@@ -558,7 +558,7 @@
 					$output['aaData'][$metadataIndex]->title = $sqlTable['title'][$i];
 					//TODO: following has problems with more than 1300 entries!
 					//$output['aaData'][$metadataIndex]->title = "<a href=\"../php/mod_iso19139ToHtml.php?url=".urlencode($mapbenderUrl."/php/mod_dataISOMetadata.php?outputFormat=iso19139&id=".$sqlTable['uuid'][$i])."\">".$sqlTable['title'][$i]."</a>";
-					$output['aaData'][$metadataIndex]->uuid = $sqlTable['uuid'][$i];
+					$output['aaData'][$metadataIndex]->uuid = "<p id=\"uuidref\">".$sqlTable['uuid'][$i]."</p>";
 					$output['aaData'][$metadataIndex]->organization = $sqlTable['organization'][$i];
 					$insCat = '';
 					$output['aaData'][$metadataIndex]->inspireCategories = '';

Modified: trunk/mapbender/http/geoportal/mod_showInspireMonitoring.php
===================================================================
--- trunk/mapbender/http/geoportal/mod_showInspireMonitoring.php	2013-12-11 17:53:20 UTC (rev 8751)
+++ trunk/mapbender/http/geoportal/mod_showInspireMonitoring.php	2013-12-11 19:13:34 UTC (rev 8752)
@@ -200,7 +200,8 @@
 //$html .= "{ \"bSortable\": false, \"aTargets\": [ 0 ] }";
 //$html .= "],";
 $html .= "\"bProcessing\": true,";
-
+//$html .= "\"bServerSide\": true,";
+//$html .= "\"iSortCol_0\": 1,";
 //internationalization
 $html .= "\"oLanguage\": {";
 $html .= "      \"sSearch\": \"Volltextsuche:\",";
@@ -219,18 +220,32 @@
 } else {
 	$html .= "\"sAjaxSource\": \"mod_pullInspireMonitoring.php\",";
 }
+/*$html .= "\"aoColumns\": [";
+//$html .= "\"<img src='../img/add.png'>\",";
+$html .= "{ \"mData\": \"detailImage\" , \"bSortable\": false },";		
+$html .= "{ \"mData\": \"title\" },";
+$html .= "{ \"mData\": \"uuid\" },";
+$html .= "{ \"mData\": \"organization\" , \"bSortable\": false },";
+if ($withCounts) {
+	$html .= "{ \"mData\": \"inspireCategories\" , \"bSortable\": false },";
+	$html .= "{ \"mData\": \"numberViewServices\" , \"bSortable\": false },";
+	$html .= "{ \"mData\": \"numberDownloadServices\" , \"bSortable\": false }";
+} else {
+	$html .= "{ \"mData\": \"inspireCategories\" , \"bSortable\": false }";
+}
+$html .= "]";*/
 $html .= "\"aoColumns\": [";
 //$html .= "\"<img src='../img/add.png'>\",";
-$html .= "{ \"mData\": \"detailImage\" },";		
+$html .= "{ \"mData\": \"detailImage\", \"bSortable\": false },";		
 $html .= "{ \"mData\": \"title\" },";
 $html .= "{ \"mData\": \"uuid\" },";
-$html .= "{ \"mData\": \"organization\" },";
+$html .= "{ \"mData\": \"organization\"},";
 if ($withCounts) {
-	$html .= "{ \"mData\": \"inspireCategories\" },";
-	$html .= "{ \"mData\": \"numberViewServices\" },";
-	$html .= "{ \"mData\": \"numberDownloadServices\" }";
+	$html .= "{ \"mData\": \"inspireCategories\"},";
+	$html .= "{ \"mData\": \"numberViewServices\"},";
+	$html .= "{ \"mData\": \"numberDownloadServices\"}";
 } else {
-	$html .= "{ \"mData\": \"inspireCategories\" }";
+	$html .= "{ \"mData\": \"inspireCategories\"}";
 }
 $html .= "]";
 $html .= "});";
@@ -267,6 +282,12 @@
 $html .= "}";
 $html .= "});";
 $html .= "});";
+$html .= "$('#uuidref').live('click', function () {";
+$html .= "var nTr = $(this).parents('tr')[0];";
+//$html .= "alert($(this).text());";
+$html .= "var url = \"../php/mod_dataISOMetadata.php?outputFormat=iso19139&id=\"+$(this).text();";
+$html .="window.open(url, '_self');";
+$html .= "});";
 $html .= "</script>";
 $html .= "</head>";
 $html .= "<table id=\"example\">";

Modified: trunk/mapbender/http/php/mod_dataISOMetadata.php
===================================================================
--- trunk/mapbender/http/php/mod_dataISOMetadata.php	2013-12-11 17:53:20 UTC (rev 8751)
+++ trunk/mapbender/http/php/mod_dataISOMetadata.php	2013-12-11 19:13:34 UTC (rev 8752)
@@ -1490,14 +1490,6 @@
 	$gmd_report->appendChild($DQ_DomainConsistency);
 	$DQ_DataQuality->appendChild($gmd_report);
 
-
-
-
-
-
-
-
-
 	$DQ_DataQuality->appendChild($lineage);
 	$gmd_dataQualityInfo->appendChild($DQ_DataQuality);
 	//$MD_ScopeCode->setAttribute("codeListValue", "service");

Modified: trunk/mapbender/http/php/mod_validateInspire.php
===================================================================
--- trunk/mapbender/http/php/mod_validateInspire.php	2013-12-11 17:53:20 UTC (rev 8751)
+++ trunk/mapbender/http/php/mod_validateInspire.php	2013-12-11 19:13:34 UTC (rev 8752)
@@ -18,7 +18,7 @@
 //TODO - make a class of it - with url, and return mimetype as attributes
 require_once(dirname(__FILE__) . "/../../core/globalSettings.php");
 
-function validateInspire($xml) {
+function validateInspirehtml($xml) {
 	//$validatorUrl = 'http://localhost/mapbender_trunk/geoportal/log_requests.php';
 	//$validatorUrl = 'http://inspire-geoportal.ec.europa.eu/GeoportalProxyWebServices/resources/INSPIREResourceTester';
 	if (defined("INSPIRE_VALIDATOR_URL") && INSPIRE_VALIDATOR_URL != '') {
@@ -76,7 +76,7 @@
 	echo $repl;
 }
 
-function validateInspireXml($xml){
+function validateInspire($xml){
 	//$validatorUrl = 'http://localhost/mapbender_trunk/geoportal/log_requests.php';
 	//$validatorUrl = 'http://inspire-geoportal.ec.europa.eu/GeoportalProxyWebServices/resources/INSPIREResourceTester';
 	if (defined("INSPIRE_VALIDATOR_URL") && INSPIRE_VALIDATOR_URL != '') {
@@ -99,7 +99,7 @@
 	$header = "";
 	$header .= 'Accept: application/xml'.$eol;
 	$header .= 'Content-Type: multipart/form-data; boundary='.$mime_boundary.$eol;
-	//$header .= 'Content-Length: '.strlen($data).$eol;
+	$header .= 'Content-Length: '.strlen($data).$eol;
 	//$data = http_build_query($data);
 	//check proxy connections
 	if (defined("CONNECTION_PROXY") &&  CONNECTION_PROXY != "") {



More information about the Mapbender_commits mailing list