CP-999-04

COMPARATIVA CARGA CAPAS

by SIGC

HTML

<script src="https://sigc.desarrollo.guadaltel.es/mapea5/js/mapea.ol.min.js"></script>
<link rel="stylesheet" href="https://sigc.desarrollo.guadaltel.es/mapea5/assets/css/mapea.ol.min.css">
<script src="https://sigc.desarrollo.guadaltel.es/mapea5/js/configuration.js"></script>
  <body>
  	<div class='visor-container'>
    	<div  class="map-container">
    		<div id="mapjs"></div>
    	</div>
  	</div>
  </body>

CSS

html,
      body {
        margin: 0;
        padding: 0;
        height: 100%;
        overflow: hidden;
      }
      
	   .visor-container{
			min-width:100%; /* make width 100% in screen*/
    		margin: 0 auto -30px;
    		min-height: 100%;
		}
		
		.map-container{
			height: 100%;
			width:100%;
			position:fixed;
			z-index:1;
		}

JavaScript

var myMap;

window.onload=function(){
var aprovechamientoInitialLayers = [
		new M.layer.WMS({
			url: 'http://www.ideandalucia.es/wms/ortofoto2010?',
			name: 'OCA10_2010',
			legend: 'Ortofotografía Rigurosa Color de Andalucía 2010 2011',
			transparent: true
		},{
			visibility: false
		}),
		// Inf. Geog. Agua
		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'MSPF_LINE',
			legend: 'Masas de Agua Superficiales de Andalucía (lineal)',
			transparent: true
		},{
			visibility: true,
			format: "application/vnd.ogc.gml"
		}),

		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'MSPF_POLY',
			legend: 'Masas de Agua Superficiales de Andalucía (poligonal)',
			transparent: true
		},{
			visibility: true,
			format: "application/vnd.ogc.gml"
		}),
		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'MSBT',
			legend: 'Masas de Agua Subterránea',
			transparent: true
		},{
			visibility: false,
			format: "application/vnd.ogc.gml"
		}),
		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'permeabilidad_total',
			legend: 'Permeabilidad total',
			transparent: true
		},{
			visibility: false,
			format: "application/vnd.ogc.gml"
		}),
		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'zona_policia_aproximada',
			legend: 'Zona de Policía aproximada',
			transparent: true
		},{
			visibility: false,
			format: "application/vnd.ogc.gml"
		}),
		new M.layer.WMS({
			url: 'http://www.juntadeandalucia.es/medioambiente/mapwms/REDIAM_PPHH_2012?',
			name: 'unidades_hidrogeologicas',
			legend: 'Unidades Hidrogeológicas',
			transparent: true
		},{
			visibility: false,
			format: "application/vnd.ogc.gml"
		}),
		new M.layer.WMS({
			url:...