$content = gzencode( file_get_contents($fn) , 9);
header('Content-Encoding: gzip');
- header('Vary: Accept-Encoding');
-
+ header('Vary: Accept-Encoding');
header('Content-Length: '. strlen($content));
echo $content;
die('invalid');
}
-
+ static function getCompileDir($type)
+ {
+ if(empty($type)) {
+ return false;
+ }
+
+ $ui = posix_getpwuid(posix_geteuid());
+
+ $compiledir = session_save_path() . '/' .
+ $ui['name'] . '-' . $ff->project . '-' . $ff->version . '-jscompile';
+
+ if (!file_exists($compiledir)) {
+ mkdir($compiledir,0700,true);
+ }
+ }
}