i discovered some strange behaviour on my nexus 5 - or am i doing something wrong?
i use this css for a bigger font on mobile devices with small displays (or in portrait view)
html {
font-size: 14px;
}
@media screen and (max-width : 800px) {
html{
font-size: 20px;
}
}
when loading the page in portrait view on my nexus 5, it looks just like it's supposed to: 20px font-size. now when turning the phone to landscape view it changes to 14px. so far so good.
now when turning the phone back to portrait view, the font-size stays 14px. Why that? My mistake?
我不确定,但是您是否设置了视口元标记?
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
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.