Friday, February 7, 2014

Detecting Browser's Touch Capability Using Javascript

Since the beginning of 2014, Google Chrome returns TRUE on document.createEvent("TouchEvent") javascript call even the browser doesn't support any touch action. The following shows the function I've been using to sniff the touch capability and it is no longer working on the latest Google Chrome: <script> function is_touch_device() {  try {   document.createEvent("TouchEvent");   return true;  }  catch (e) {   return false;...
Read More »

Wednesday, February 5, 2014

Guessing the Performance of Your Browser and Device Using Javascript

After coming out with the Javascript to guess the CPU speed previously, I discovered that the for-next looping codes are not enough to guess the performance of a device/browser. I realized the looping is only good to guess the performance of the browser, it is not enough to guess the speed of the animation which is crucial in today's web presence. I then came out with two sets of codes to assess the performance of the animation capability of a device of the browser. One is to test the...
Read More »