Skip to content

Instantly share code, notes, and snippets.

@svenl77
Created February 20, 2017 09:43
Show Gist options
  • Select an option

  • Save svenl77/71e1fe016e63f9ba49289fcba452df47 to your computer and use it in GitHub Desktop.

Select an option

Save svenl77/71e1fe016e63f9ba49289fcba452df47 to your computer and use it in GitHub Desktop.
jQuery(document).ready(function () {
var $instance = jQuery('.buddyforms-pin').easypin({
init: '{"91":{"0":{"coords":{"lat":"303","long":"215.5"}},"canvas":{"src":"img/2011-12-18-23.51.12.jpg","width":"auto","height":"auto"}}}',
limit: 1,
exceeded: function(element) {
alert('You only able to create one pin at the time ;)');
},
responsive: true,
drop: function(long, lat, element) {
console.log(long, lat);
},
drag: function(long, lat, element) {
console.log(long, lat);
}
});
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment