Migración a Bootstrap 4
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

220 lines
5.9KB

  1. <?php session_start();
  2. //ini_set('display_errors', 'On');
  3. require ('xajax/xajax.inc.php');
  4. $xajax = new xajax();
  5. //require ('json.lab.php');
  6. require ('funciones/funciones.php');
  7. require ("funciones/conex.php");
  8. require_once ('includes/markdown.php');
  9. //require ('funciones/convert.php');
  10. $xajax->processRequests();
  11. if($_REQUEST[id2] =='') {$agregar= $_REQUEST[id];}else {$agregar = $_REQUEST[id2];}
  12. $formulario_nombre = remplacetas('form_id','id',$_REQUEST[id],'nombre') ;
  13. $agregar_nombre = remplacetas('form_id','id',$agregar,'nombre') ;
  14. $plantilla ="mapa";
  15. ?>
  16. <!DOCTYPE html>
  17. <html lang="en">
  18. <head >
  19. <title><?php echo $formulario_nombre[0] ?> MILFS</title>
  20. <meta charset="utf-8">
  21. <meta name="viewport" content="user-scalable=no, width=device-width, maximum-scale=1, initial-scale=1">
  22. <meta http-equiv="X-UA-Compatible" content="IE=edge">
  23. <meta name="viewport" content="width=device-width, initial-scale=1">
  24. <meta name="description" content="">
  25. <?php $xajax->printJavascript("xajax/"); ?>
  26. <link rel="shortcut icon" href="favicon-152.png">
  27. <link rel="apple-touch-icon-precomposed" href="favicon-152.png">
  28. <script src='https://api.mapbox.com/mapbox.js/v2.2.2/mapbox.js'></script>
  29. <link href='https://api.mapbox.com/mapbox.js/v2.2.2/mapbox.css' rel='stylesheet' />
  30. <link href='https://api.mapbox.com/mapbox.js/plugins/leaflet-markercluster/v0.4.0/MarkerCluster.Default.css' rel='stylesheet' />
  31. <link href='https://mapbox.com/base/latest/base.css' rel='stylesheet' />
  32. <link href="https://maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css" rel="stylesheet" integrity="sha256-k2/8zcNbxVIh5mnQ52A0r3a6jAgMGxFJFE2707UxGCk= sha512-ZV9KawG2Legkwp3nAlxLIVFudTauWuBpC10uEafMHYL0Sarrz5A7G79kXh5+5+woxQ5HM559XX2UZjMJ36Wplg==" crossorigin="anonymous">
  33. <link rel="stylesheet" type="text/css" media="screen" href="css/bootstrap.css">
  34. <link rel="stylesheet" type="text/css" media="screen" href="css/bootstrap-markdown.css">
  35. <link rel="stylesheet" type="text/css" media="screen" href="css/bootstrap-markdown.min.css">
  36. <!-- <link href="css/estilos.php?hghgSs" rel="stylesheet"> -->
  37. <style type="text/css">
  38. .navbar-default {
  39. background:rgba(255,255,255,1) ;
  40. }
  41. @media (max-width: 800px) {
  42. .panel-map{
  43. max-width: 970px;
  44. }
  45. }
  46. @media (min-width: 800px) {
  47. .panel-map{
  48. max-width: 200px;
  49. }
  50. }
  51. .leaflet-popup-content { width:600px !important; }
  52. #map { position:absolute; top:0; bottom:0; width:100%; }
  53. /* Sticky footer styles
  54. -------------------------------------------------- */
  55. html {
  56. position: relative;
  57. min-height: 100%;
  58. }
  59. body {
  60. /* Margin bottom by footer height */
  61. margin-bottom: 60px;
  62. padding: 0; margin: 0;
  63. }
  64. /* Custom page CSS
  65. -------------------------------------------------- */
  66. /* Not required for template or sticky footer method. */
  67. body > .container {
  68. padding: 60px 15px 0;
  69. }
  70. .container .text-muted {
  71. margin: 20px 0;
  72. }
  73. .footer {
  74. position: absolute;
  75. bottom: 3px;
  76. width: 95%;
  77. margin: 0 auto;
  78. height: 120px;
  79. /* Set the fixed height of the footer here */
  80. z-index: 999999;
  81. }
  82. .footer > .container {
  83. padding: 2px;
  84. background-color: white;
  85. border-radius: 3px;
  86. width: 90%;
  87. height: 120px;
  88. overflow-x: scroll;
  89. }
  90. code {
  91. font-size: 80%;
  92. }
  93. .modal-dialog {
  94. width: 98%;
  95. height: auto;
  96. padding: 0;
  97. }
  98. .modal-content {
  99. height: auto;
  100. }
  101. </style>
  102. <!-- <link rel="points" type="application/json" href="json.php?id=<?php echo $_REQUEST["id"] ?>"> -->
  103. </head>
  104. <body>
  105. <div id='map'>
  106. <?php $categorias = lista_categorias($_REQUEST['id'],'','') ;
  107. if($categorias !="") {
  108. $pie="
  109. <div class='footer' id='contenedor_pie' >
  110. <div style='' class='container' >
  111. <a href='#' onclick=\"xajax_limpia_div('contenedor_pie'); \"><span class='pull-right'><i class='fa fa-times'></i></span></a>
  112. $categorias
  113. </div></div>
  114. </div>";
  115. }else{
  116. }
  117. echo $pie;
  118. ?>
  119. <script>
  120. L.mapbox.accessToken = 'pk.eyJ1IjoiZmNhc3Ryb3QiLCJhIjoiY2lnOWw1bmd1MG93eXVsbTJpcmluYTBxdCJ9.yG7C1rEH6-MpZBEEb68IVg';
  121. /* var map = L.mapbox.map('map', 'examples.map-i86nkdio')*/
  122. var map = L.mapbox.map('map', 'mapbox.outdoors')
  123. .setView([40, -74.50], 8);
  124. var geoJson = [ <?php echo imprime_geojson("$_REQUEST[id]","$_REQUEST[id2]","$plantilla");?> ];
  125. var myLayer = L.mapbox.featureLayer()
  126. .setGeoJSON(geoJson)
  127. .addTo(map);
  128. myLayer.on('layeradd', function(e) {
  129. var marker = e.layer,
  130. feature = marker.feature;
  131. // Create custom popup content
  132. var popupContent = '' + feature.properties.description + '';
  133. // http://leafletjs.com/reference.html#popup
  134. marker.bindPopup(popupContent,{
  135. closeButton: false,
  136. minWidth: 320
  137. });
  138. marker.setIcon(L.icon(feature.properties.icon));
  139. });
  140. map.fitBounds(myLayer.getBounds());
  141. myLayer.setGeoJSON(geoJson);
  142. </script>
  143. <?php echo mapa_ficha("$_REQUEST[id]");?>
  144. <!-- Modal -->
  145. <div class='modal fade ' id='muestraInfo' tabindex='-1' role='dialog' aria-labelledby='myModalLabel' aria-hidden='true'>
  146. <div class='modal-dialog' >
  147. <div class='modal-content'>
  148. <div class='modal-header' >
  149. <button type='button' class='close' data-dismiss='modal' aria-hidden='true'>&times;</button>
  150. <h4 class='modal-title' id='myModalLabel_info'><div id='titulo_modal'></div></h4>
  151. </div>
  152. <div class='modal-body'>
  153. <div id='muestra_form'></div>
  154. </div>
  155. <div class='modal-footer' id='pie_modal'>
  156. </div>
  157. </div>
  158. </div>
  159. </div>
  160. <!-- Bootstrap core JavaScript
  161. ================================================== -->
  162. <!-- Placed at the end of the document so the pages load faster -->
  163. <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.2/jquery.min.js"></script>
  164. <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.4/js/bootstrap.min.js"></script>
  165. <script src="js/markdown.js"></script>
  166. <script src="js/to-markdown.js"></script>
  167. <script src="js/bootstrap-markdown.js"></script>
  168. <script src="js/scripts.js"></script>
  169. </body>
  170. </html>