media-queries

IE 10 on WP8 ignores media queries?

蓝咒 提交于 2019-12-22 08:24:01
问题 I'm working on a site that uses media queries. I can see in my desktop browser that they are working correctly, but when I navigate to the site on my WP8 device, no CSS is loaded. I've created a very simple HTML page to replicate the problem and show what solution I tried, but couldn't get to work. Here is the entire code: <html> <head> <title>WP8 Test</title> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" /> <script src="http://ajax

Is it redundant using jQuery Mobile and a responsive layout /CSS media queries?

妖精的绣舞 提交于 2019-12-22 08:01:13
问题 I was checking out http://mediaqueri.es/ today and found out that the websites adapt fantastically to mobile devices. So i wondered if using jQuery Mobile and a response/adaptive layout with media queries together would be redundant, since by using only media queries seems to be a good approach. Is it really redundant or am i tripping on caffeine? EDIT Example: I don't see how this website would benefit from using jQuery Mobile, since it's very well done using media queries. And to be fair, i

How do breakpoints work on modern high resolution devices?

冷暖自知 提交于 2019-12-22 06:54:02
问题 Modern phones and tablets have very high resolutions. My Galaxy S7 Edge, for example, has a resolution of 1440 x 2560 pixels. Common breakpoints for mobile devices seems to be around 768 pixels, such as in bootstrap. Example from bootstrap.css: @media (min-width: 768px) { .container { width: 750px; } } @media (min-width: 992px) { .container { width: 970px; } } @media (min-width: 1200px) { .container { width: 1170px; } } How is it that my phone displays the "responsive" version of websites

Get native screen resolution using jQuery

我是研究僧i 提交于 2019-12-22 06:38:13
问题 I'd like to get the native screen width on a device to append scripts in the DOM. Is it possible using jQuery ? Thanks 回答1: window.screen.width ? Source: https://developer.mozilla.org/en-US/docs/DOM/window.screen 回答2: Sure. You can get the basic width and height using: screen.width; screen.height; If required, you can also get the pixel ratio (useful if you need to also detect retina displays) by using: window.devicePixelRatio 回答3: You can set the width to device width with a css property:

CSS @media Check if not Webkit

亡梦爱人 提交于 2019-12-22 05:40:33
问题 I'm trying to create a single CSS file that applies one style if the browser is using webkit, and another if not. I read how to check if it is using Webkit with: @media (-webkit-min-device-pixel-ratio:0) However, I can't figure out how to check if it's not using Webkit. I tried adding not in front of the media query, but it doesn't seem to work. Anyone have a solution or a better way to do it? Thanks. 回答1: I still stand by my comments, but this was the best I could come up with. Once again,

jQuery change media query width value

丶灬走出姿态 提交于 2019-12-22 04:33:29
问题 Is it possible with jQuery or anything else to change width value of @media query css while page is running? So for example if in style.css I've got @media screen and (min-width: 400px) { /*whatever*/ } to change it to 500px after website is loaded 回答1: This is not possible through traditional method. You have to insert the full css through jQuery. For e.g : $('body').append("<style type='text/css'>@media screen and (min-width: 500px) { /*whatever*/ }</style>"); 来源: https://stackoverflow.com

Can you set medium columns on Zurb Foundation 4?

帅比萌擦擦* 提交于 2019-12-21 20:24:29
问题 NB: This has been asked but not really answered here: How do I make use of breakpoints in Zurb foundation 4? The small and large columns on Foundation 4 are really handy, but small activates perhaps a little earlier than I'd like - is there any way of setting a medium-columns setting for smallish but not tiny resolutions, e.g. 800 * 600? In my specific case, I'd like the following setup: <div class="small-12 medium-6 large-4 columns">First column</div> <div class="small-12 medium-6 large-8

Do Media Queries work in MediaWiki?

北慕城南 提交于 2019-12-21 15:02:02
问题 I'm trying to get a responsive skin working in MediaWiki with media queries, and I'm troubleshooting some weird behavior. If I add a test div to a wiki page: <div id="testing">TESTING</div> And then add a media query: @media screen { #testing {background-color: green;} } ...to various places, the style only applies in certain browsers. For example: If I add it to the active skin's "screen.css" file, where all the other working styles live: iPad: NO iPhone4: NO Chrome 20.0 XP+Mac: NO Firefox

iPhone 5 is not displaying the responsive mode of the website correctly

不问归期 提交于 2019-12-21 12:41:36
问题 I have created this website, and so far I have not been able to find out why only on certain iPhone phones, the website is not displayed in its responsive mode. (it shows correctly on most iPhone phones). Here is what I have done so far: Checked the website on Android devices: it looks good Check the responsive website on different browsers: it works Use online iphone simulators to see how the website looks: Shows fine Cleared browser cache and cookies on iPhone devices that have problem

CSS color property not working correctly on @media print

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-21 12:30:19
问题 I'm building a web app which basically consists of a large form which can then be printed after submission. However, the text on my print document seems to never be affected by both color and font-weight CSS properties. Here is a small section of the document as it looks like on screen: However, when printing, it ends up looking like this: The font is the same but for some reason no styles are applied to it. I have NO overriding CSS settings for @media print , so shouldn't it just look