adjustment to clear browser location button only if use browser location option is set

This commit is contained in:
marijus 2014-12-09 15:22:53 +01:00
parent 242713ebef
commit cc365513ed
2 changed files with 2 additions and 2 deletions

View File

@ -60,7 +60,7 @@
<i id="profile-location" class="icon-globe jot-icons"></i>
</button>
{{if $noloc}}
<button id="profile-nolocation-wrapper" class="btn btn-default btn-sm" style="display: none;" title="{{$noloc}}" onclick="jotClearLocation();return false;">
<button id="profile-nolocation-wrapper" class="btn btn-default btn-sm" title="{{$noloc}}" onclick="jotClearLocation();return false;" disabled="disabled">
<i id="profile-nolocation" class="icon-circle-blank jot-icons"></i>
</button>
{{/if}}

View File

@ -1,7 +1,7 @@
if(navigator.geolocation) {
navigator.geolocation.getCurrentPosition(function(position) {
$('#jot-coord').val(position.coords.latitude + ' ' + position.coords.longitude);
$('#profile-nolocation-wrapper').show();
$('#profile-nolocation-wrapper').attr('disabled', false);
});
}