Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

css less unrecognized statement

Tags:

css

less

I'm trying to add gradients through css.

I have this line for gradients in older versions of ie.

filter: progid:DXImageTransform.Microsoft.gradient(startColorstr=#e4da9d, endColorstr=#c1b676);

However the javascript interpreter for less css is giving me a syntax error for that line. Is there a way to skip that line from parsing and just output it the way it is.

like image 259
dardub Avatar asked Nov 14 '11 19:11

dardub


1 Answers

Use

filter: ~"progid:DXImageTransform.Microsoft.gradient(startColorstr=#e4da9d, endColorstr=#c1b676)";

More about 'escaping' in LESS - String Functions - CSS Escaping

like image 70
fliptheweb Avatar answered Sep 23 '22 05:09

fliptheweb