I'm trying to remove include statements from a css file. So given a css file like
@import url("css1.css");
@import url("css2.css");
@import url("css3.css");
.myfirstclass {color:red}
after I run the command I want to be
.myfirstclass {color:red}
This is the command I am using but it isn't working. Is there a way to do this?
$css_file = preg_replace("/^@import url(.*)$/", "", $css_file);
mmodifier$css_file = preg_replace("/^\s*@import url.*/m", "", $css_file);(to;. The faulty component is the$. Either add themflag or remove the$. Or best, use revo's second method.