labs-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From simo...@apache.org
Subject svn commit: r747439 - /labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java
Date Tue, 24 Feb 2009 17:06:18 GMT
Author: simoneg
Date: Tue Feb 24 17:06:14 2009
New Revision: 747439

URL: http://svn.apache.org/viewvc?rev=747439&view=rev
Log:
LABS-302 : use CDATA to escape inlined CSS and script, ported back to 0.0.1

Modified:
    labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java

Modified: labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java
URL: http://svn.apache.org/viewvc/labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java?rev=747439&r1=747438&r2=747439&view=diff
==============================================================================
--- labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java
(original)
+++ labs/magma/branches/0.0.1/website-production-optimizer/src/main/java/org/apache/magma/website/optimization/InliningHtmlHead.java
Tue Feb 24 17:06:14 2009
@@ -42,7 +42,7 @@
 				if (locname.equals(name)) {
 					super.addCss(name);
 				} else {
-					inline("<style type=\"text/css\">", locname, "</style>", true);
+					inline("<style type=\"text/css\">/*<![CDATA[*/\n", locname, "\n/*]]>*/</style>",
true);
 					added(name);
 				}
 			} else {
@@ -59,7 +59,7 @@
 				if (locname.equals(name)) {
 					super.addExternalScript(name, mimeType);
 				} else {
-					inline("<script type=\"" + mimeType + "\">", locname, "</script>", false);
+					inline("<script type=\"" + mimeType + "\">//<![CDATA[\n", locname, "\n//]]></script>",
false);
 					added(name);
 				}
 			} else {



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@labs.apache.org
For additional commands, e-mail: commits-help@labs.apache.org


Mime
View raw message