Merge pull request #19070 from mattwire/extensionupgrademsg
[civicrm-core.git] / templates / CRM / Admin / Form / Setting / Mapping.tpl
1 {*
2 +--------------------------------------------------------------------+
3 | Copyright CiviCRM LLC. All rights reserved. |
4 | |
5 | This work is published under the GNU AGPLv3 license with some |
6 | permitted exceptions and without any warranty. For full license |
7 | and copyright information, see https://civicrm.org/licensing |
8 +--------------------------------------------------------------------+
9 *}
10 <div class="help">
11 {ts}CiviCRM includes plugins for several mapping and geocoding web services. When your users save a contact or event location address, a geocoding service will convert the address into geographical coordinates, which are required for mapping. Mapping services allow your users to display addresses on a map.{/ts} {help id='map-intro-id'}
12 </div>
13 <div class="crm-block crm-form-block crm-map-form-block">
14 <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="top"}</div>
15 <table class="form-layout-compressed">
16 <tr class="crm-map-form-block-mapProvider">
17 <td>{$form.mapProvider.label}</td>
18 <td>{$form.mapProvider.html}<br />
19 <span class="description">{ts}Choose the mapping provider that has the best coverage for the majority of your contact addresses.{/ts}</span></td>
20 </tr>
21 <tr class="crm-map-form-block-mapAPIKey">
22 <td>{$form.mapAPIKey.label}</td>
23 <td>{$form.mapAPIKey.html|crmAddClass:huge}<br />
24 <span class="description">{ts}Enter your API Key or Application ID. An API Key is required for the Google Maps API. Refer to developers.google.com for the latest information.{/ts}</span></td>
25 </tr>
26 <tr class="crm-map-form-block-geoProvider">
27 <td>{$form.geoProvider.label}</td>
28 <td>{$form.geoProvider.html}<br />
29 <span class="description">{ts}This can be the same or different from the mapping provider selected.{/ts}</span></td>
30 </tr>
31 <tr class="crm-map-form-block-geoAPIKey">
32 <td>{$form.geoAPIKey.label}</td>
33 <td>{$form.geoAPIKey.html|crmAddClass:huge}<br />
34 <span class="description">{ts}Enter the API key or Application ID associated with your geocoding provider.{/ts}</span></td>
35 </tr>
36 </table>
37 <div class="crm-submit-buttons">{include file="CRM/common/formButtons.tpl" location="bottom"}</div>
38 </div>
39 {literal}
40 <script type="text/javascript">
41 CRM.$(function($) {
42 var $form = $('form.{/literal}{$form.formClass}{literal}');
43 function showHideMapAPIkey() {
44 var mapProvider = $(this).val();
45 if ( !mapProvider || ( mapProvider === 'OpenStreetMaps' ) ) {
46 $('tr.crm-map-form-block-mapAPIKey', $form).hide( );
47 } else {
48 $('tr.crm-map-form-block-mapAPIKey', $form).show( );
49 }
50 }
51 $('#mapProvider').each(showHideMapAPIkey).change(showHideMapAPIkey);
52 });
53 </script>
54 {/literal}