简体   繁体   中英

Device orientation & pagination

I'm currently working on a mobile site that has tiles which represent each article. The pages have 15 tiles on them which is clean and works for both orientations on a mobile device. I recently added a featured article which takes up two space tiles worth of page space, so now I have one tile that is widowed on the bottom of the page.

Using some media queries I'm able to show/hide the last two tiles which works great until users click to the next page of tiles. If a user is in portrait orientation then they will miss two article tiles because they were hidden on the last page.

So I want to create some type of AJAX function that allows me to check the orientations and dynamically change the tile count request server side. Is this possible?

Jquery Mobile提供了查看和了解设备方向的方法。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM