iPhone 5 Media Queries
iPhone 5 in portrait & landscape
@media only screen and (min-device-width : 320px) and (max-device-width : 568px) { /* STYLES GO HERE */}
iPhone 5 in landscape
@media only screen and (min-device-width : 320px) and (max-device-width : 568px) and (orientation : landscape) { /* STYLES GO HERE */}
iPhone 5 in portrait
@media only screen and (min-device-width : 320px) and (max-device-width : 568px) and (orientation : portrait) { /* STYLES GO HERE */ }
iPhone 2G, 3G, 4, 4S Media Queries
It's noteworthy that these media queries are also the same for iPod Touch generations 1-4.
iPhone 2G-4S in portrait & landscape
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) { /* STYLES GO HERE */}
iPhone 2G-4S in landscape
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) and (orientation : landscape) { /* STYLES GO HERE */}
iPhone 2G-4S in portrait
@media only screen and (min-device-width : 320px) and (max-device-width : 480px) and (orientation : portrait) { /* STYLES GO HERE */ }
iPhone 5 Resolution
Screen Width = 320px (CSS Pixels) Screen Height = 568px (CSS Pixels) Screen Width = 640px (Actual Pixels) Screen Height = 1136px (Actual Pixels) Device-pixel-ratio: 2
iPhone 4/4S Resolution
Screen Width = 320px (CSS Pixels) Screen Height = 480px (CSS Pixels) Screen Width = 640px (Actual Pixels) Screen Height = 960px (Actual Pixels) Device-pixel-ratio: 2
iPhone 2G/3G/3GS Resolution
Screen Width = 320px (CSS Pixels) Screen Height = 480px (CSS Pixels) Screen Width = 320px (Actual Pixels) Screen Height = 480px (Actual Pixels) Device-pixel-ratio: 1
Pad Media Queries (All generations - including iPad mini)
Thanks to Apple's work in creating a consistent experience for users, and easy time for developers, all 5 different iPads (iPads 1-5 and iPad mini) can be targeted with just one CSS media query. The next few lines of code should work perfect for a responsive design.
iPad in portrait & landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) { /* STYLES GO HERE */}
iPad in landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : landscape) { /* STYLES GO HERE */}
iPad in portrait
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : portrait) { /* STYLES GO HERE */ }
iPad 3 & 4 Media Queries
If you're looking to target only 3rd and 4th generation Retina iPads (or tablets with similar resolution) to add @2x graphics, or other features for the tablet's Retina display, use the following media queries.
Retina iPad in portrait & landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (-webkit-min-device-pixel-ratio: 2) { /* STYLES GO HERE */}
Retina iPad in landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : landscape) and (-webkit-min-device-pixel-ratio: 2) { /* STYLES GO HERE */}
Retina iPad in portrait
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : portrait) and (-webkit-min-device-pixel-ratio: 2) { /* STYLES GO HERE */ }
iPad 1 & 2 Media Queries
If you're looking to supply different graphics or choose different typography for the lower resolution iPad display, the media queries below will work like a charm in your responsive design!
iPad 1 & 2 in portrait & landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (-webkit-min-device-pixel-ratio: 1){ /* STYLES GO HERE */}
iPad 1 & 2 in landscape
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : landscape) and (-webkit-min-device-pixel-ratio: 1) { /* STYLES GO HERE */}
iPad 1 & 2 in portrait
@media only screen and (min-device-width : 768px) and (max-device-width : 1024px) and (orientation : portrait) and (-webkit-min-device-pixel-ratio: 1) { /* STYLES GO HERE */ }
相关推荐
官方最新powercharts 3.12.2,图表上无水印。支持最新的HTML5,跨平台。PCs, Macs, iPads, iPhones, Android devices, our JavaScript (HTML5) charts work everywhere. Heck, even on
Apress 2014最新iOS、iphone开发书籍,EPUB格式 Apress Beginning iOS Media App Development (2014).epub ...Apress The Business of iOS App Development, For iPhones iPads and iPod touches 3rd (2014).epub
官方最新Fusioncharts 3.12.2,图表上无水印。支持最新的HTML5,跨平台。PCs, Macs, iPads, iPhones, Android devices, our JavaScript (HTML5) charts work everywhere. Heck, even on IE 6
官方最新Fusioncharts 3.12.2,图表上无水印。支持最新的HTML5,跨平台。PCs, Macs, iPads, iPhones, Android devices, our JavaScript (HTML5) charts work everywhere. Heck, even on IE 6
IOS13.0-13.5越狱APP ... It's also a snappy, responsive experience that you can't find anywhere else, with full support for iOS 13.0-13.5 devices, including the latest iPads and iPhones.
and from that insight you’ll be able to vision and create your own apps, on iPhones and iPads, that work perfectly within the new iOS 7 interface. What youll learn How to build apps that work ...
iPhone and Mac Programming Made Easy," is designed specifically for those who are new to programming and wish to start developing applications for Apple devices such as iPhones, iPads, and Mac ...
Recent announcements of increased AR capabilities on the latest iPhones and iPads show a clear dedication on Apple’s part to this emerging market of immersive games and apps. Unity 2017 is the latest...
- 使用外部CSS文件(如`iPads.css`),便于样式管理与维护。 - **页面结构**:页面顶部通常有一个100%宽度的导航栏,包含了网站的主要菜单项,便于用户导航;底部也通常有一个固定宽度的区域用于放置版权信息和其他...
5月2日消息,据国外媒体报道,苹果开始大规模测试iOS5操作系统,参与测试的设备包括iPods、iPads和iPhones,据悉连iPhone3GS也参与了测试。同时,已经有软件开发商正在进行iOS5.0的第三方软件兼容性测试,近日iOS...
As of March 2018, Apple's App Store contains more than 2.1 million iOS applications, 1 million of which are native for iPads.[12] These mobile apps have collectively been downloaded more than 130 ...
You can build one powerful and expressive app that runs smoothly on all your devices: iPhones and iPads, Android phones and tablets, Linux Systems (using FMXLinux), and MacBooks and Windows computers...
Raspberry pi 2B 和 pi 3+ 计算机的一些音乐相关软件的免费测试版。 我收录了 20 多首免版税的圣诞曲调,我曾在歌词上添加和弦,然后... IPADS/IPHONES、ANDROIDS、LAPTOPS & DESKTOPS 可以连接到 PICHORDOKE 服务器。
标题"本仓库包含上海交通大学IPADS实验室设计的操作系统课程系列实验。每个实验放在独立分支。.zip"表明这是一个与操作系统课程相关的学习资源包,来源于上海交通大学的IPADS实验室。"每个实验放在独立分支"意味着...
With a drag-and-drop interface that runs in any web browser, and on devices from iPads to PCs to Macs to Microsoft Surface tablets, Scratch is an easily accessible way to enter the world of computer ...
它免费适用于iPads和iPhones,也有付费版本提供更多信息。 5. HappyCow app:专为素食者和纯素者设计,用户可以搜索全球的素食餐厅和商店。HappyCow有免费的Android版本,但包含广告且需要网络连接。 6. LocalEats...
Cocos2D is a powerful 2D game development framework designed specifically for iOS devices such as iPhones and iPads. The framework simplifies the process of creating engaging and interactive 2D games ...