Improvements to the script loader: allows plugins to queue scripts for the front end head and footer, adds hooks for server side caching of compressed scripts, adds support for ENFORCE_GZIP constant (deflate is used by default since it's faster), see #8628, fixes #8884

git-svn-id: https://develop.svn.wordpress.org/trunk@10442 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Andrew Ozz
2009-01-26 12:59:10 +00:00
parent ecd158c24b
commit 4d58681aa4
7 changed files with 137 additions and 65 deletions
+2 -2
View File
@@ -3395,7 +3395,7 @@ function screen_icon($name = '') {
}
/**
* Test support for compressed JavaScript and CSS
* Test support for compressing JavaScript from PHP
*
* Outputs JavaScript that tests if compression from PHP works as expected
* and sets an option with the result. Has no effect when the current user
@@ -3406,7 +3406,7 @@ function screen_icon($name = '') {
*/
function compression_test() {
?>
<script type="text/javascript" src="load-scripts.php?test=1"></script>
<script type="text/javascript" src="load-scripts.php?test=1<?php echo ( defined('ENFORCE_GZIP') && ENFORCE_GZIP ) ? '&c=gzip' : ''; ?>"></script>
<script type="text/javascript">
/* <![CDATA[ */
(function() {