JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
fixed css so prioritize links don't make a horizontal scroll bar
[contractor-progress.git] / css_mangler.php
1 <?php
2
3 require_once('code/wfpl/file.php');
4 require_once('code/ie_detect.php');
5
6 # this file is meant to act as a filter for .css files. it removes all lines
7 # containing "remove this line for IE 5.5 and 6"
8
9 # see also: .htaccess style.css
10
11 function css_mangler() {
12         $file = $_SERVER['REDIRECT_URL'];
13
14         $file = substr($file, 1);
15
16         header('Content-Type: text/css');
17
18         if(ie5or6()) {
19                 echo(ereg_replace("\n[^\n]*remove this line for IE 5.5 and 6[^\n]*\n", "\n", read_whole_file($file)));
20         } else {
21                 readfile($file);
22         }
23 }
24
25 css_mangler();
26
27 ?>