HTML 5 CSS 3 @viewport mediaquery

So, I was browsing the web to find out if there was any solution to block orientation. I found this:

http://www.w3.org/TR/css-device-adapt/

It states that with @viewport you should be able to block orientation, but I cannot find any support information or anything else. I just tried

 @viewport{
orientation: portrait;
}

But he does nothing, no complaints about this?

+3
source share
2 answers

You need to add the provider prefix.

Example:

IE10

@-ms-viewport {
  width: 1024px;
  height: 768px;
}

More details http://msdn.microsoft.com/en-us/library/ie/hh708740(v=vs.85).aspx

Opera

@-o-viewport {
  width: 1024px;
  height: 768px;
}

More details http://dev.opera.com/articles/view/an-introduction-to-meta-viewport-and-viewport/

http://docs.webplatform.org/wiki/css/atrules/@viewport

+1
@viewport all and (max-width: 480px) {
 orientation:portrait;
}

, , , CSS @media.

0

All Articles