diff options
author | Christian Schneider | 2023-07-31 14:29:42 +0200 |
---|---|---|
committer | Christian Schneider | 2023-07-31 14:29:42 +0200 |
commit | c7da6f7683cac617afc201b48b0b1c4268b38d05 (patch) | |
tree | a84a7722948fa8d49c482d7b572f1181855e601e | |
parent | 2cca98b6c889fda20b949b7ce2faad29b2104c3e (diff) | |
download | itools-c7da6f7683cac617afc201b48b0b1c4268b38d05.tar.gz itools-c7da6f7683cac617afc201b48b0b1c4268b38d05.tar.bz2 itools-c7da6f7683cac617afc201b48b0b1c4268b38d05.zip |
Stylesheets: Pass url(...) through U() for normalization/OneDomain
-rw-r--r-- | itjs.php | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -44,6 +44,7 @@ if (it::match('\.gif$', $lastfile)) else if (it::match('\.css', $lastfile)) { header("Content-Type: text/css"); + $data = preg_replace_callback('/\burl\(["\']?([^"\'\)]+)["\']?\s*\)/', fn($v) => 'url(' . U($v[1]) . ')', $data); # Pass url(...) through U() for normalization/OneDomain if (!it::match('^devel', $GLOBALS['ULTRASERVERTYPE'])) $data = it::replace(array('[ \t]*([{};])[ \t]*' => '$1', ($nostrip ? '_LEAVE_COMMENTS_' : '/\*.*?\*/') => ""), $data); if (it::match('W3C_CSS_Validator', $_SERVER['HTTP_USER_AGENT']) || $_GET['w3c']) |