You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by mem <me...@gmail.com> on 2012/03/22 15:33:54 UTC

MarkupWriter + HTML (5) Validation

I'm not quite sure about the issue here as i'm not too familiar with all the
standards possibly involved (SGML, HTML X.X, XHTML, ....).
When i'm using an Action- or EventLink on my page by defining it in the Java
class and then referencing it in the tml in the follwing manner:

someText 

Tapestry renders the following:

someUrl someText 

When using any other tag instead of 'a', for example:

<p t:id="myLink">someText</p>

it gets rendered correctly without the shape attribute:

someUrl someText 

I've no clue what's the benefit of rendering this attribute, in HTML 5 it's
deprecated and i've never seen this attribute being used for an anchor tag.

Is there a way to get rid of this attribute without using 'wrong' tags?

Pretty much the same problem we got with the br tag which is used in the tml
like this:

<br/>

but Tapestry renders to:

<br clear="none" />

I couldn't figure out any way how to get rid of the clear attribute,
obviously this attribute shouldn't be set there, if anywhere it should be
set through css and what's worse it shouldn't be set at all.

Is there any way to get rid of those attributes and secondly, why are they
there by default anyways?

kind regards
Matt


--
View this message in context: http://tapestry.1045711.n5.nabble.com/MarkupWriter-HTML-5-Validation-tp5586070p5586070.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: MarkupWriter + HTML (5) Validation

Posted by mem <me...@gmail.com>.
@Steve: 
Yes, it seems like the same issue to me, the attributes are taken out from
the dtd's.


@Thiago:
Thanks for the response, i've taken a look at those classes and many more
while debugging this behavior and investigating where those attributes come
from. The model in use is the htmlModel/DefaultMarkupModel which pretty much
only allows some abbreviated tags but doesn't tell me anything about the
informal parameters which are used subsequently (the attributes shape and
clear)

Should i open a new bug report for this issue (according to Massimo
Lusetti's comment:Please open a new one for 5.3 if this still applicable),
we're using 5.3.2?

To see both behaviors in action just take a look at jumpstart:
http://jumpstart.doublenegative.com.au/jumpstart/examples/input/eventlinks/0

--
View this message in context: http://tapestry.1045711.n5.nabble.com/MarkupWriter-HTML-5-Validation-tp5586070p5588736.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: MarkupWriter + HTML (5) Validation

Posted by Steve Eynon <st...@alienfactory.co.uk>.
Sounds like this Jira:

Filter out attributes with default value (from DTD) when parsing templates
https://issues.apache.org/jira/browse/TAP5-171

--
Steve Eynon
-------------------------------
"If at first you don't succeed,
   so much for skydiving!"


On 23 March 2012 05:28, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> Hi!
>
> Take a look at the MarkupWriterFactoryImpl, DefaultMarkupModel, and
> XMLMarkupModel classes in the Tapestry sources.
>
> --
> Thiago H. de Paula Figueiredo
> Independent Java, Apache Tapestry 5 and Hibernate consultant, developer, and
> instructor
> Owner, Ars Machina Tecnologia da Informação Ltda.
> http://www.arsmachina.com.br
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org


Re: MarkupWriter + HTML (5) Validation

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Hi!

Take a look at the MarkupWriterFactoryImpl, DefaultMarkupModel, and  
XMLMarkupModel classes in the Tapestry sources.

-- 
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor
Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
For additional commands, e-mail: users-help@tapestry.apache.org