css-hack

IE10 CSS hack for animation property?

孤人 提交于 2019-12-13 14:04:28
问题 Is it possible to create an IE10 hack for the CSS animation property? I was using this: height: 70px\9; However this doesn't work for animation . The following will stop animations working for all browsers: animation: none\9; I want to do this in my existing stylesheet, without using JavaScript or conditional stylesheets. 回答1: This has got to be one of the most peculiar edge cases in CSS I've seen yet. I have to say, hats off to you for finding — well, stumbling across — this. The reason why

Weird CSS hack for sharpening images (Chrome 59 and 60 only)

橙三吉。 提交于 2019-12-13 02:04:34
问题 I encountered strange behavior in Chrome v60.0 when I placed a downscaled image on top of itself and set the CSS image-rendering parameter to pixelated : #container { position: relative; width: 160px } .image { width: 100% } .overlay { width: 100%; position: absolute; left: 0px; top: 0px; image-rendering: pixelated } <div id="container"> <img class="image" src="http://www.publicdomaintreasurehunter.com/wp-content/uploads/2011/01/muscle.jpg"> <img class="overlay" src="http://www

Which css hacks for IE 6 and 7 are future proof?

两盒软妹~` 提交于 2019-12-12 13:34:04
问题 Which css hacks for IE 6 and 7 are future proof? i mean if i use then then they would never create any problem and their patch will never be implemented? manage 2 css one for all and one for IE is time consuming and it adds one extra style sheet also. and if any hack can solve problem within main css then it's a timesaver and when multiple people work on same project then most of time we forgot to make change in conditional css too. i'm not asking about condition stylesheet 回答1: none. Use IE

How to blur an image using CSS3 without cropping or fading the edges?

喜你入骨 提交于 2019-12-10 12:19:31
问题 How can you properly blur an image using CSS3 without fading the edges or cropping the image? DEMO The issue the green BG show thru: HTML: <div id="bg_img" classid="blink_me"></div> CSS: /*regular way of doing it*/ body{ background-color: #0F0; margin: 0; padding: 0; } #bg_img{ filter: blur(50px); /*Set amount of blur, px units are bad when re-scaling the window size */ -webkit-filter: blur(50px); /*Set amount of blur, px units are bad when re-scaling the window size */ position:absolute;

What CSS hacks are these?

空扰寡人 提交于 2019-12-07 03:56:32
问题 I found this in a CSS declaration code I am now partially responsible for: margin: 0 0 0 10px; *+margin: 4px 0 0 10px; margin: 3px 0 0 10px\0/; ... the *+ and \0/ are what I'm looking at in particular. What are the hacks being employed here? And is there a standard place I can look at to look at current and past CSS hacks that also lists their applicability and usefulness? I want to be able at a glance to see a difference between an on-purpose hack and simple code errors. 回答1: margin: 3px 0 0

forward slash in CSS? Is this some browser specific thing?

偶尔善良 提交于 2019-12-05 09:23:16
I inherited a CSS stylesheet and in a few places it does things like: margin:7px 0 0 0; /margin-top:9px; or background: url(../images/list-hover.png) 0 0 no-repeat; /background:url(../images/lists-hover.png) 0 2px no-repeat; anyone know what that forward slash is doing? Nathaniel B It's to target LTE IE7. This hack isn't known as much as the IE6 underscore one. #myelement { background:red; /*Should show as red in all browsers, expect IE6 and IE7 because...*/ /background:yellow; /*IE7 should have yellow*/ _background:green; /*IE6 should have green*/ } You can make the backslash almost anything

What CSS hacks are these?

*爱你&永不变心* 提交于 2019-12-05 08:19:45
I found this in a CSS declaration code I am now partially responsible for: margin: 0 0 0 10px; *+margin: 4px 0 0 10px; margin: 3px 0 0 10px\0/; ... the *+ and \0/ are what I'm looking at in particular. What are the hacks being employed here? And is there a standard place I can look at to look at current and past CSS hacks that also lists their applicability and usefulness? I want to be able at a glance to see a difference between an on-purpose hack and simple code errors. margin: 3px 0 0 10px\0/; That one is a CSS hack to specify Internet Explorer 8. *+margin: 4px 0 0 10px; This one is for

CSS specific rule for Opera 12? [duplicate]

孤者浪人 提交于 2019-12-03 08:28:27
Possible Duplicate: How to make CSS visible only for Opera Many times I need to use browser specific CSS rules to make the design look alike in every browser. Generally I need them for IE 7-8, but this time is for Opera, specifically Opera 12 and on. I found some solutions for Opera: Make CSS apply only for Opera 11? How to make CSS visible only for Opera But these only work for 11 or below... Is there a solution for Opera 12? c69 Here is an officially recommended hack for Opera (in case everything else fails): doesnotexist:-o-prefocus, .example { color: red; } http://www.opera.com/docs/specs

What does the smiley face “:)” mean in CSS?

拜拜、爱过 提交于 2019-12-03 00:01:59
问题 I spotted this CSS code in a project: html, body { :)width: 640px;} I have been around with CSS for a long time now but I never saw this ":)" code before. Does it mean anything or is it just a typo? 回答1: From an article at javascriptkit.com, that's applied for IE 7 and earlier versions: if you add a non-alphanumeric character such as an asterisk ( * ) immediately before a property name, the property will be applied in IE and not in other browsers. Also there's a hack for <= IE 8 : div { color

Is there any way to apply CSS for specific chrome version?

て烟熏妆下的殇ゞ 提交于 2019-12-02 19:25:47
问题 I'm facing a problem in Chrome 59 version alone . to sort that I need a css hack to target that chrome version alone. I saw an article with this example code says its working, but in my case it doesn't work. example 1 @media screen and (-webkit-min-device-pixel-ratio:0) { .logotext-n { .chrome59.margin-left: -10px; /* update for Chrome 59 issue */ } } example 2 @media screen and (-webkit-min-device-pixel-ratio:0) { .chrome59.logotext-n { margin-left: -10px; /* update for Chrome 59 issue */ }