javascript - Hooking into browser rotation -


i'd execute javascript code when mobile phone rotated. i'm using jquery. there custom hook can use mobile browsers?

one way can think of hooking change of viewport size, , checking if height/width ratio has changed. there api method use instead?

it should "onorientationchange" event attached on <body> tag.

looking @ window.orientation property should angle in degrees.


Comments

Popular posts from this blog

ASP.NET/SQL find the element ID and update database -

jquery - appear modal windows bottom -

c++ - Compiling static TagLib 1.6.3 libraries for Windows -