You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tapestry.apache.org by hl...@apache.org on 2011/10/18 01:22:06 UTC
svn commit: r1185431 - in /tapestry/tapestry5/trunk/tapestry-core/src:
main/java/org/apache/tapestry5/dom/
test/resources/org/apache/tapestry5/internal/services/
Author: hlship
Date: Mon Oct 17 23:22:06 2011
New Revision: 1185431
URL: http://svn.apache.org/viewvc?rev=1185431&view=rev
Log:
TAP5-724: Tapestry generates invalid HTML (for strict and transitional doctypes)
Modified:
tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/dom/DefaultMarkupModel.java
tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/added_scripts_go_before_existing_script.txt
tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/ie_conditional_stylesheet.txt
tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/immediate_initialization.txt
tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/other_initialization.txt
tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/pretty_print_initialization.txt
Modified: tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/dom/DefaultMarkupModel.java
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/dom/DefaultMarkupModel.java?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/dom/DefaultMarkupModel.java (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/main/java/org/apache/tapestry5/dom/DefaultMarkupModel.java Mon Oct 17 23:22:06 2011
@@ -22,11 +22,11 @@ import java.util.Set;
* Default implementation of {@link org.apache.tapestry5.dom.MarkupModel} that is appropriate for traditional (X)HTML
* markup. Assumes that all tags are lower-case. The majority of elements will be "expanded" (meaning a complete start
* and end tag); this is for compatibility with web browsers, especially when the content type of a response indicates
- * HTML, not true XML. Only the "hr" and "br" and "img" tags will be rendered abbreviated (i.e., "lt;img/>").
+ * HTML, not true XML. Only the "hr", "br","img", "link", and "meta" tags will be rendered abbreviated (i.e., "lt;img/>").
*/
public class DefaultMarkupModel extends AbstractMarkupModel
{
- private final Set<String> ALWAYS_EMPTY = CollectionFactory.newSet("hr", "br", "img");
+ private final Set<String> ALWAYS_EMPTY = CollectionFactory.newSet("hr", "br", "img", "link", "meta");
public DefaultMarkupModel()
{
Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/added_scripts_go_before_existing_script.txt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/added_scripts_go_before_existing_script.txt?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/added_scripts_go_before_existing_script.txt (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/added_scripts_go_before_existing_script.txt Mon Oct 17 23:22:06 2011
@@ -1 +1 @@
-<html><head><meta></meta><script src="/foo.js" type="text/javascript"></script><script></script></head></html>
\ No newline at end of file
+<html><head><meta/><script src="/foo.js" type="text/javascript"></script><script></script></head></html>
\ No newline at end of file
Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/ie_conditional_stylesheet.txt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/ie_conditional_stylesheet.txt?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/ie_conditional_stylesheet.txt (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/ie_conditional_stylesheet.txt Mon Oct 17 23:22:06 2011
@@ -1,5 +1,5 @@
-<html><head><link type="text/css" rel="stylesheet" href="everybody.css"></link>
+<html><head><link type="text/css" rel="stylesheet" href="everybody.css"/>
<!--[if IE]>
-<link type="text/css" rel="stylesheet" href="just_ie.css"></link>
+<link type="text/css" rel="stylesheet" href="just_ie.css"/>
<![endif]-->
</head></html>
\ No newline at end of file
Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/immediate_initialization.txt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/immediate_initialization.txt?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/immediate_initialization.txt (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/immediate_initialization.txt Mon Oct 17 23:22:06 2011
@@ -1,2 +1,2 @@
-<html><head><meta></meta><script></script></head><body><script type="text/javascript">Tapestry.init({"fred":"barney"});
+<html><head><meta/><script></script></head><body><script type="text/javascript">Tapestry.init({"fred":"barney"});
</script></body></html>
\ No newline at end of file
Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/other_initialization.txt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/other_initialization.txt?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/other_initialization.txt (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/other_initialization.txt Mon Oct 17 23:22:06 2011
@@ -1,4 +1,4 @@
-<html><head><meta></meta><script></script></head><body><script type="text/javascript">Tapestry.onDOMLoaded(function() {
+<html><head><meta/><script></script></head><body><script type="text/javascript">Tapestry.onDOMLoaded(function() {
Tapestry.init({"fred":"barney"});
});
</script></body></html>
\ No newline at end of file
Modified: tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/pretty_print_initialization.txt
URL: http://svn.apache.org/viewvc/tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/pretty_print_initialization.txt?rev=1185431&r1=1185430&r2=1185431&view=diff
==============================================================================
--- tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/pretty_print_initialization.txt (original)
+++ tapestry/tapestry5/trunk/tapestry-core/src/test/resources/org/apache/tapestry5/internal/services/pretty_print_initialization.txt Mon Oct 17 23:22:06 2011
@@ -1,4 +1,4 @@
-<html><head><meta></meta><script></script></head><body><script type="text/javascript">Tapestry.init({
+<html><head><meta/><script></script></head><body><script type="text/javascript">Tapestry.init({
"fred" : [
"barney",
"wilma",