Greaaat !
That's was my goal when i initiate de Gmap api plugin, but i did'nt finish the job !
Cédric
Le 27 juin 08 à 17:29, horaciogd@vhplab.net a écrit :
Author: horaciogd@vhplab.net
Date: Fri Jun 27 17:29:18 2008
New Revision: 21145Log:
I have been making a lot of changes in order to clean and organize Gis and Googlemap Api plug-in. Both have functions and documents mixed that belong to the opposite plug-in. I am also developing a third plug-in to use instead of Googlemap Api plug-in. This new plug-in will allow Spip to use Open Layers (http://openlayers.org/) instead of Googlemaps. My concern is to use really free maps and also to make a modular structure that allows the user to choose from multiple map services you can exchange in any moment.Added:
_plugins_/_dev_/open_layers/
_plugins_/_dev_/open_layers/base/
_plugins_/_dev_/open_layers/base/openlayer_upgrade.php
_plugins_/_dev_/open_layers/geomap.js.html
_plugins_/_dev_/open_layers/geomap.js_fonctions.php
_plugins_/_dev_/open_layers/img_pack/
_plugins_/_dev_/open_layers/img_pack/correxir.png (with props)
_plugins_/_dev_/open_layers/img_pack/ie/
_plugins_/_dev_/open_layers/img_pack/ie/ctlBot.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlBotLeft.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlBotRight.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlCenter.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlHyb.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlLeft.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlMap.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlRight.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlSat.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlTop.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlTopLeft.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlTopRight.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlZoomIn.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlZoomNotch.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlZoomOut.gif (with props)
_plugins_/_dev_/open_layers/img_pack/ie/ctlZoomSel.gif (with props)
_plugins_/_dev_/open_layers/img_pack/logo_google.gif (with props)
_plugins_/_dev_/open_layers/img_pack/png/
_plugins_/_dev_/open_layers/img_pack/png/center.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/corner01.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/corner02.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/corner03.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/corner04.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlBot.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlBotLeft.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlBotRight.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlCenter.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlHyb.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlLeft.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlMap.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlRight.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlSat.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlTop.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlTopLeft.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlTopRight.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlZoomIn.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlZoomNotch.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlZoomOut.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/ctlZoomSel.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/go.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/left.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/libro.png (with props)
_plugins_/_dev_/open_layers/img_pack/png/right.png (with props)
_plugins_/_dev_/open_layers/img_pack/shadow.png (with props)
_plugins_/_dev_/open_layers/inc/
_plugins_/_dev_/open_layers/inc/openlayer_append_clicable_map.php
_plugins_/_dev_/open_layers/inc/openlayer_append_mini_map.php
_plugins_/_dev_/open_layers/inc/openlayer_append_moveend_map.php
_plugins_/_dev_/open_layers/inc/openlayer_append_view_map.php
_plugins_/_dev_/open_layers/inc/openlayer_config.php
_plugins_/_dev_/open_layers/inc/openlayer_public_script_init.php
_plugins_/_dev_/open_layers/inc/openlayer_script_init.php
_plugins_/_dev_/open_layers/inc_public_map.html
_plugins_/_dev_/open_layers/js/
_plugins_/_dev_/open_layers/js/customControls.js
_plugins_/_dev_/open_layers/js/geomap.js
_plugins_/_dev_/open_layers/js/jquery-1.2.6.js
_plugins_/_dev_/open_layers/lang/
_plugins_/_dev_/open_layers/lang/openlayer_en.php
_plugins_/_dev_/open_layers/lang/openlayer_es.php
_plugins_/_dev_/open_layers/lang/openlayer_fr.php
_plugins_/_dev_/open_layers/lang/openlayer_gl.php
_plugins_/_dev_/open_layers/mapfiles.js.html
_plugins_/_dev_/open_layers/modeles/
_plugins_/_dev_/open_layers/modeles/geomap.html
_plugins_/_dev_/open_layers/openlayer_pipeline.php
_plugins_/_dev_/open_layers/plugin.xml
_plugins_/_dev_/open_layers/public/
_plugins_/_dev_/open_layers/public/openlayer_balises.phpAdded: _plugins_/_dev_/open_layers/base/openlayer_upgrade.php
--- _plugins_/_dev_/open_layers/base/openlayer_upgrade.php (added)
+++ _plugins_/_dev_/open_layers/base/openlayer_upgrade.php Fri Jun 27 17:29:18 2008
@@ -0,0 +1,47 @@
+<?php
+/*
+ * Open Layers plugin
+ * free WMS map layers for SPIP
+ *
+ * Authors :
+ * Horacio Gonz‡lez
+ * (c) 2007 - Distributed under GNU/GPL licence
+ *
+ */
+ $GLOBALS['openlayer_version'] = 0.0;
+
+ function openlayer_verifier_base(){
+ $version_base = $GLOBALS['openlayer_version'];
+ $current_version = 0.0;
+ if ((!isset($GLOBALS['meta']['openlayer_version']) )
+ || (($current_version = $GLOBALS['meta']['openlayer_version'])!=$version_base)){
+ if ($current_version==0.0){
+ ecrire_meta('openlayer_version',$current_version=$version_base,'non');
+ }
+ }
+ ecrire_meta('gis_map','openlayer');
+ }
+
+ function openlayer_vider_tables(){
+ ecrire_meta('gis_map','no');
+ effacer_meta("openlayer_wms");
+ effacer_meta("openlayer_version");
+ }
+
+ function openlayer_install($action){
+ $version_base = $GLOBALS['openlayer_version'];
+ switch ($action){
+ case 'test':
+ ecrire_meta('gis_map','openlayer');
+ return (isset($GLOBALS['meta']['openlayer_version'])
+ AND ($GLOBALS['meta']['openlayer_version']>=$version_base));
+ break;
+ case 'install':
+ openlayer_verifier_base();
+ break;
+ case 'uninstall':
+ openlayer_vider_tables();
+ break;
+ }
+ }
+?>
\ No newline at end of fileAdded: _plugins_/_dev_/open_layers/geomap.js.html
--- _plugins_/_dev_/open_layers/geomap.js.html (added)
+++ _plugins_/_dev_/open_layers/geomap.js.html Fri Jun 27 17:29:18 2008
@@ -0,0 +1,10 @@
+[(#REM)
+
+ Charger la librairie GoogleMaps et nos ajouts
+
+]#CACHE{7*24*3600,cache-client}
+#HTTP_HEADER{'Content-Type: text/javascript'}
+[(#CONFIG**{geomap_googlemapkey,''}|?{' '})
+#SET{cache,#REM|sinon{http://maps.google.com/maps?file=api&v=\}|concat{#CONFIG**{geomap_googlemapversion}}|concat{&key=}|concat{#CONFIG**{geomap_googlemapkey}}|concat{&hl=}|concat{#LANG}}
+[(#GET{cache}|recuperer_page|compacte_js)]]
+[(#INCLURE{js/geomap.js})]Added: _plugins_/_dev_/open_layers/geomap.js_fonctions.php
--- _plugins_/_dev_/open_layers/geomap.js_fonctions.php (added)
+++ _plugins_/_dev_/open_layers/geomap.js_fonctions.php Fri Jun 27 17:29:18 2008
@@ -0,0 +1,7 @@
+<?php
+
+function geomap_cache_map($script){
+ if (preg_match(",http://maps\.google\.com/mapfiles/(.*)\.js,Uims",$script,$regs))
+ $script = str_replace($regs[0],generer_url_public('mapfiles.js','map='.$regs[1].".js",true),$script);
+ return $script;
+}
\ No newline at end of fileAdded: _plugins_/_dev_/open_layers/img_pack/correxir.png
Binary file - no diff available.
Propchange: _plugins_/_dev_/open_layers/img_pack/correxir.png
------------------------------------------------------------------------------
svn:mime-type = application/octet-streamAdded: _plugins_/_dev_/open_layers/img_pack/ie/ctlBot.gif
Binary file - no diff available.
Propchange: _plugins_/_dev_/open_layers/img_pack/ie/ctlBot.gif
------------------------------------------------------------------------------
svn:mime-type = application/octet-streamAdded: _plugins_/_dev_/open_layers/img_pack/ie/ctlBotLeft.gif
Binary file - no diff available.
Propchange: _plugins_/_dev_/open_layers/img_pack/ie/ctlBotLeft.gif
------------------------------------------------------------------------------
svn:mime-type = application/octet-streamAdded: _plugins_/_dev_/open_layers/img_pack/ie/ctlBotRight.gif
Binary file - no diff available.
Propchange: _plugins_/_dev_/open_layers/img_pack/ie/ctlBotRight.gif
------------------------------------------------------------------------------
svn:mime-type = application/octet-streamAdded: _plugins_/_dev_/open_layers/img_pack/ie/ctlCenter.gif
Binary file - no diff available.
[... 5223 lines stripped ...]
_______________________________________________
Spip-zone-commit@rezo.net - http://listes.rezo.net/mailman/listinfo/spip-zone-commit