Welcome to the in5 Answer Exchange! This a place to get answers about in5 (InDesign to HTML5) and make requests.
0 votes
I want the device to load the appropriate layout when it is turned. Is this possible?
in how_to by (150 points)

1 Answer

0 votes
Best answer

It will take some custom JavaScript. Here's an (incomplete) proof of concept document to get you started.

by (197k points)
selected by
can this not be done by media queries within the css. Can you export the two layouts and then load the CSS from each depending on screen width but using the same resources. So you dont have two separate  documents that need to load with the same content. Thanks for the help.
You could use a media query to switch layouts. I haven't figured out a way to use the same resources, as InDesign treats them as separate pages items.
thank you, is there a way to do this without reloading the page when you turn the device. Maybe ajax?
This one doesn't reload the page. It loads both documents and shows/hides them as needed. It also updates the page of the hidden orientation(s).