Answer the question
In order to leave comments, you need to log in
Why doesn't device.js + ipad3 work?
There is a design
<a href="tel: 123" class="link">
<span>text</span>
</a>
$('.link').on('click', function(e) {
if (!device.mobile()) {
e.preventDefault();
// вызов попапа
}
});
$('.link').on('click', function(e) {
alert('test');
if (!device.mobile()) {
e.preventDefault();
// вызов попапа
}
});
Answer the question
In order to leave comments, you need to log in
I found the reason: if the href of the link contains "tel:", then iOS completely discards all events hung on this link, and only performs the default value - a call.
I solved the problem like this: on the tablet and desktop, I replace the href of the links with # and everything works.
If you go to the off site , then through the emulator (chrome) it works fine for me!
Check what the method returns! Open the off page and find out! Here is your answer
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question