CSS - content property use special char
on 2017-05-04
CSS - content property use special char
If you want use special char like © in CSS content
property
You must use ASCII and show on HEX
And it is ©
So CSS need
div;before {
content: "\00A9";
}
This page can help us trans to hex
JavaScript - get CSS style
on 2016-01-27
JavaScript - get CSS style
Sometimes i want to use JavaScript get dom CSS style.
Use DOM.currentStyle
and window.getComputedStyle(DOM)
For IE use DOM.currentStyle
Other use window.getComputedStyle(DOM)
var dom = document.getElementById("target"),
style = dom.currentStyle || window.getComputedStyle(dom);
console.log(style.marginTop);