Detect if iOs

/* Detect iOs */
if (navigator.userAgent.match(/(iPod|iPhone|iPad)/)) {
// do something
}