Check If You Are On a Touch Enabled Device |

by kirupa | 23 September 2013

Today's world is more complicated. It is annoyingly filled with input methods that go beyond a mouse and keyboard. You have to deal with iPhones, iPads, tablets, phablets (tablones?), hybrids, and so on that revolve around touch or support touch as a primary input method. There will be times when you need to know in your HTML document whether you are on a device that is touch friendly. In this short article, you will learn how to add a few lines of JavaScript to easily handle such times.

This is a companion discussion topic for the original entry at