-1
A
답변
0
function yourfunction()
{
switch(window.orientation)
{
case -90:
case 90:
alert('landscape');
break;
default:
alert('portrait');
break;
}
}
window.addEventListener('onorientationchange', yourfunction);