source: extensions/edit_gmaps/admin/admin_edit.tpl @ 4557

Last change on this file since 4557 was 4557, checked in by cljosse, 14 years ago

[Edit_gmaps] update version

File size: 7.1 KB
Line 
1{html_head}
2{* $Id: info_deroulante.tpl 3723 2009-08-07 04:53:38Z rvelices $ *}
3
4{known_script id="jquery.cluetip" src=$ROOT_URL|@cat:"template-common/lib/plugins/jquery.cluetip.js"}
5
6
7<script type="text/javascript">
8jQuery().ready(
9  function(){ldelim}
10  jQuery('.cluetip').cluetip({ldelim}
11    width: 300,
12    splitTitle: '|'
13   }
14  );
15 }
16);
17</script>
18
19{if $lat}
20<script src="http://maps.google.com/maps?file=api&amp;v=2&amp;key={$GMAPS_API_KEY}&amp;hl={$lang_info.code}" type="text/javascript"></script>
21
22
23<script src="plugins/rv_gmaps/template/windows_13/javascripts/prototype.js" type="text/javascript"></script>
24
25
26<style type="text/css">{literal}
27
28#map2{   
29left:0px;
30 width:250px
31}
32#mapPicture{
33
34width:100px ;
35 border:outset;
36 height:100px;
37}
38#map{ float:left;
39 top:20px;
40 right:0px;
41  width:500px;
42  height:500px;
43 border:outset;
44}
45
46
47{/literal}
48</style>
49{/if}
50{/html_head}
51
52<fieldset>
53  <legend>{'Display options'|@translate}</legend>
54  <table ><td class="cluetip" title="{'set'|translate}|{'hlp_line1'|@translate}." align="left"  >
55<form>
56Set:
57<select onchange="document.location = this.options[this.selectedIndex].value;"   >
58  <optgroup label="Specials">
59    {html_options options=$specials}
60  </optgroup>
61  <optgroup label="{'Categories'|@translate}">
62        {html_options options=$categories selected=$categories_selected}
63  </optgroup>
64  <!-- <optgroup label="{'Tags'|@translate}"></optgroup> -->
65</select>
66</form>
67</td>
68<td > {'hlp_line2'|@translate} </td>
69
70</table>
71
72
73  <p>{'elements per page'|@translate}:
74      <a href="{$U_DISPLAY}&amp;display=20">20</a>
75    | <a href="{$U_DISPLAY}&amp;display=50">50</a>
76    | <a href="{$U_DISPLAY}&amp;display=100">100</a>
77    | <a href="{$U_DISPLAY}&amp;display=all">{'all'|@translate}</a>
78  </p>
79</fieldset>
80
81
82<form action="" method="post" id="Envoie" name="Envoie"   >
83
84<fieldset>
85        <legend>{'Elements'|@translate}</legend>
86
87        <div class="navigationBar">{$NAV_BAR}</div>
88  {if not empty($thumbnails)}
89        <ul class="thumbnails">
90                {foreach from=$thumbnails item=thumbnail}
91                <li><span class="wrap1">
92                        <label>
93                                <span class="wrap2"><span>
94                                        <img src="{$thumbnail.U_TN}" alt="{$thumbnail.file}" title="{$thumbnail.TITLE}" class="thumbnail" />
95                                </span></span>
96                                <input type="checkbox" name="selection[]" value="{$thumbnail.id}" />
97                        </label>
98
99                        <span class="thumbLegend">
100                        {if isset($thumbnail.U_MAP)}
101                        <a href="{$thumbnail.U_MAP}" target="_blank">{$thumbnail.lat},{$thumbnail.lon}</a>
102                        {/if}
103                        </span>
104
105                        </span>
106                </li>
107                {/foreach}
108        </ul>
109        {/if}
110</fieldset>
111
112<!--/===================================================================================-->
113
114<fieldset>
115<legend>{'map'|@translate}</legend>
116 
117<input class="cluetip" title="{'selection'|@translate}|{'hlp_line3'|@translate}." type="submit" name="submit" value="{'selection'|@translate}" />
118<input class="cluetip" title="{'reset'|@translate}|{'hlp_line4'|@translate}."  type="submit" name="submit" value="{'reset'|@translate}" /><br />
119
120<input class="cluetip" title="{'search_title'|@translate}|{'hlp_line6'|@translate}."  type="submit" name="submit" value="{'search_title'|@translate}" />
121<input class="cluetip" title="{'lieu'|@translate}|{'hlp_line5'|@translate}." type="text" size="70"   value="{$match}"  name="match"    />
122{if $lat}
123<div id="map"></div>
124{if not empty($Selectthumbnails)}
125        <ul class="thumbnails">
126                {foreach from=$Selectthumbnails item=thumbnail}
127                 
128                        <li><span class="wrap1">
129                                <label>
130                                        <span class="wrap2"><span>
131                                                <img src="{$thumbnail.U_TN}" alt="{$thumbnail.file}" title="{$thumbnail.TITLE}" class="thumbnail" />
132                                        </span>
133                                       
134                                        </span>
135                                        <br/>
136</label>
137                                <input type="hidden"  value={$thumbnail.id}  name="selection[]"    />
138                               
139                               
140                               
141                                <span class="thumbLegend">
142                                {if isset($thumbnail.U_MAP)}
143                                        <a href="{$thumbnail.U_MAP}" target="_blank">{$thumbnail.lat},{$thumbnail.lon}</a>
144                                {/if}
145                                {$thumbnail.file} 
146                                </span>
147
148                                </span>
149                        </li>
150                       
151                {/foreach}
152        </ul>
153        {/if}
154
155 <script src="dragzoom.js" type="text/javascript"></script>
156<script type="text/javascript">
157
158{literal}
159 //<![<!--CDATA[
160function onLoad()
161{
162  if (!GBrowserIsCompatible())   return;
163  var mapElement = document.getElementById("map");
164  var map = new GMap2(document.getElementById("map"),{mapTypes: [G_SATELLITE_MAP,G_HYBRID_MAP,G_NORMAL_MAP,G_PHYSICAL_MAP,G_SATELLITE_3D_MAP]});
165 
166  map.addControl(new GLargeMapControl());
167  map.addControl(new GMapTypeControl());
168  map.addControl(new GScaleControl());
169<!--  map.enableScrollWheelZoom();-->
170<!--  map.enableDoubleClickZoom();-->
171{/literal}
172{if isset($lat)}{/if}
173var coord = new GLatLng( {$lat}, {$lon} );
174
175  Ma_position=coord;
176  var echelle=18;
177if ({$lat}=='49' && {$lon}=='3' )   echelle=4;
178 
179  map.setCenter( coord, echelle);
180  var marker = new GMarker(coord);
181  map.addOverlay(marker);
182
183{literal}
184  if ( !map.isLoaded() )
185    map.setCenter( new GLatLng(49,3), 4);
186  try {
187    // the overview must be added after setting map center
188    var ovcontrol = new GOverviewMapControl(new GSize(165,165));
189                map.addControl(ovcontrol);
190                var ov_map = ovcontrol.getOverviewMap();
191                GEvent.addListener(map, 'maptypechanged', function(){
192                        ov_map.setMapType(G_NORMAL_MAP);
193                });
194               
195
196GEvent.addListener(map,"click", function(overlay,latlng)
197            {
198 if (overlay) { return; }
199            var myHtml = "<input    type=\"text\" name=\"lat\" value="+latlng.lat()+" /><input   type=\"text\" name=\"lon\" value="+latlng.lng()+" /> ";       
200             map.openInfoWindow(latlng, myHtml);       
201
202                {/literal}
203                                document.Envoie.lat.value=latlng.lat() ;
204                                document.Envoie.lon.value=latlng.lng() ;
205
206                               
207                               
208
209
210                {literal}       
211            }
212                        );
213                         
214                                 
215  }
216  catch(e){ alert( e.message ); }
217 
218
219}
220
221function blowupUrl(theUrl)
222{
223  var win = new Window({
224    title: document.title,
225    url: theUrl,
226    classname: "alphacube",
227    left: 0, top: 0,
228    width:"640", height:"480",
229    minimizable: false,
230    maximizable: false,
231    draggable: false,
232    resizable: false,
233    destroyOnClose: true,
234    hideEffect: Element.hide,
235    showEffectOptions: {duration:1.5}
236  });
237
238  win.setConstraint(true, {top:20, left:20, bottom:30, right:20} );
239  win.maximize();
240  win.showCenter(true, 20, 20);
241 
242  return false;
243}
244
245 Event.observe(window, 'load', onLoad );
246 Event.observe(window, 'unload', GUnload );
247//]-->]>
248{/literal}
249 
250</script>
251
252{/if}
253
254</fieldset>
255
256
257<fieldset>
258  <legend>{'Form'|@translate}</legend>
259
260 
261  <label>Latitude (-90=S to 90=N)
262    <input type="text" size="8" value="{$lat}"  name="lat" />
263  </label>
264  <label>Longitude (-180=E to 180=W)
265    <input type="text" size="9"value="{$lon}"  name="lon"  />
266  </label>
267 
268  <p>
269    {'target'|@translate}
270    <label><input type="radio" name="target" value="all" /> {'all'|@translate}</label>
271    <label><input type="radio" name="target" value="selection" checked="checked" /> {'selection'|@translate}</label>
272  </p>
273
274  <p><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" {$tag_input_enabled} /></p>
275</fieldset>
276
277</form>
Note: See TracBrowser for help on using the repository browser.