Is there anyway to detect when the orientation of the user's screen changes?
I'd like to fire some javascript functions when this happens to update various bits of content.
For example, I have a set of divs displayed as an accordion. Each div displays +/- icons to show / hide its content.
When the page loads in landscape, the content in each div is displayed by default, however when it loads in portrait the content is hidden.
I need to reset the +/- icons when the orientation of the screen changes.
Are there any events I can hook into to achieve this?
Any advice appreciated.
Thanks.