Hide Div on IOS

Asked

Viewed 65 times

1

I have a redirect button for Whatsapp on my site that doesn’t work on Ios, would there be any way to hide it just for that OS? In case it is inside a href in html, just hide it when the user is using ios.

1 answer

1


You can try an approach of this kind,

var ehIOS = /iPad|iPhone|iPod/.test(navigator.userAgent) && !window.MSStream;

if(ehIOS){
   //codigo para ocultar
}
  • Thanks! It worked!

Browser other questions tagged

You are not signed in. Login or sign up in order to post.