In ios, the horizontal screen and then the vertical screen back to the style are all deformed, I can add an alert, how can it be feasible without adding alert? Or simply prohibit the horizontal screen.

in ios, the horizontal screen and then back to the vertical style are all deformed, I can add an alert, how can it be feasible without adding alert? Or directly prohibit horizontal screen

normal page:

clipboard.png

clipboard.png

alert

clipboard.png

console.log()

clipboard.png

window.onorientationchange=function(){
   if(window.orientation==90||window.orientation==-90){
       alert("");
    }else{
       alert("");
   }
 }

Question1: why can I just write alert? Why not write console?
question 2: is it possible to disable the horizontal screen directly?

Mar.14,2021

may be a problem with dom . Try scrolling 1px


<meta name="screen-orientation" content="portrait">
<meta name="x5-orientation" content="portrait">

it seems to be invalid in Wechat's official account


change the height of the page after the screen switch is detected, trigger the re-rendering of the page, or reload

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1eb00fc-22a4.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1eb00fc-22a4.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?