diff --git a/jquery.fancydropdown.js b/jquery.fancydropdown.js
old mode 100644
new mode 100755
index 4d6b033..d08c633
--- a/jquery.fancydropdown.js
+++ b/jquery.fancydropdown.js
@@ -20,7 +20,7 @@
return this.each(function() {
var el = $(this);
var id = $(this).attr('id');
- el.hide();
+ el.css({'position': 'absolute', 'left': '-999em'});
//create needed HTML
var html = '
';
$('option', el).each(function() {
@@ -43,7 +43,7 @@
if (private.bound_click_customdropdown === undefined) {
//bind the click event only once
private.bound_click_customdropdown = true;
- $('body').bind('click.customdropdown', function(e) {
+ $('body').bind('click.customdropdown touchstart', function(e) {
var elements = $(e.target).parents().andSelf();
var dropdown = elements.filter('.dropdown');
var dropdownlist = elements.filter('.dropdownlist');
@@ -81,6 +81,7 @@
$(dropdownlist[0]).fadeOut('fast');
//reflect change to original