You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Barry Books <tr...@gmail.com> on 2013/04/11 14:47:20 UTC

Dynamic Template vs t:container

I'm trying to create a dynamic template with something like this

<t:container xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd">

<h2><span id="param:title"></span></h2>

<div class="row">

<span id="param:blog"></span>

</div>

</t:container>


but I end up with a container tag wrapping my content. Is there a way to
wrap a dynamic template and have the outer tag ignored?

Re: Dynamic Template vs t:container

Posted by Barry Books <tr...@gmail.com>.
It is an exact copy and here is the page. If I change container to span I
get a span tag.

<html t:type="layout" title="${blog.title}"

xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd"

xmlns:p="tapestry:parameter">

 <t:dynamic template="asset:BlogViewTemplate.tml">

<p:title>

<t:tb.contentEditable enable="true" event="savetitle" content="blog.title">test
content</t:tb.contentEditable>

</p:title>

<p:blog>

<t:tb.contentEditable class="span6" enable="true" event="save" content=
"blog.body" uploadurl="literal:/studio/blog/upload">test content</
t:tb.contentEditable>

</p:blog>

</t:dynamic>


</html>





On Thu, Apr 11, 2013 at 10:55 AM, Howard Lewis Ship <hl...@gmail.com>wrote:

> Seems odd; is that an exact copy of your template?  Could the <container>
> tag be coming from the containing page or component instead?
>
>
> On Thu, Apr 11, 2013 at 5:47 AM, Barry Books <tr...@gmail.com> wrote:
>
> > I'm trying to create a dynamic template with something like this
> >
> > <t:container xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd
> ">
> >
> > <h2><span id="param:title"></span></h2>
> >
> > <div class="row">
> >
> > <span id="param:blog"></span>
> >
> > </div>
> >
> > </t:container>
> >
> >
> > but I end up with a container tag wrapping my content. Is there a way to
> > wrap a dynamic template and have the outer tag ignored?
> >
>
>
>
> --
> Howard M. Lewis Ship
>
> Creator of Apache Tapestry
>
> The source for Tapestry training, mentoring and support. Contact me to
> learn how I can get you up and productive in Tapestry fast!
>
> (971) 678-5210
> http://howardlewisship.com
>

Re: Dynamic Template vs t:container

Posted by Howard Lewis Ship <hl...@gmail.com>.
Seems odd; is that an exact copy of your template?  Could the <container>
tag be coming from the containing page or component instead?


On Thu, Apr 11, 2013 at 5:47 AM, Barry Books <tr...@gmail.com> wrote:

> I'm trying to create a dynamic template with something like this
>
> <t:container xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd">
>
> <h2><span id="param:title"></span></h2>
>
> <div class="row">
>
> <span id="param:blog"></span>
>
> </div>
>
> </t:container>
>
>
> but I end up with a container tag wrapping my content. Is there a way to
> wrap a dynamic template and have the outer tag ignored?
>



-- 
Howard M. Lewis Ship

Creator of Apache Tapestry

The source for Tapestry training, mentoring and support. Contact me to
learn how I can get you up and productive in Tapestry fast!

(971) 678-5210
http://howardlewisship.com

Re: Dynamic Template vs t:container

Posted by Barry Books <tr...@gmail.com>.
Yes I'm using dynamic and I did try without it and that results in an invalid XML document. I'll create a jira. 

On Apr 11, 2013, at 8:40 AM, "Thiago H de Paula Figueiredo" <th...@gmail.com> wrote:

> On Thu, 11 Apr 2013 09:47:20 -0300, Barry Books <tr...@gmail.com> wrote:
> 
>> I'm trying to create a dynamic template with something like this
> 
> As in using the Dynamic component?
> 
>> <t:container xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd">
>> 
>> <h2><span id="param:title"></span></h2>
>> 
>> <div class="row">
>> 
>> <span id="param:blog"></span>
>> 
>> </div>
>> 
>> </t:container>
>> 
>> but I end up with a container tag wrapping my content. Is there a way to
>> wrap a dynamic template and have the outer tag ignored?
> 
> Have you tried without <t:container> and without a root element? I don't think it would work, but I'd try that anyway. :)  It seems you've found a bug here. Please file a JIRA about it if you don't find a solution.
> 
> -- 
> Thiago H. de Paula Figueiredo
> 
> ---------------------------------------------------------------------
> 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: Dynamic Template vs t:container

Posted by Thiago H de Paula Figueiredo <th...@gmail.com>.
On Thu, 11 Apr 2013 09:47:20 -0300, Barry Books <tr...@gmail.com> wrote:

> I'm trying to create a dynamic template with something like this

As in using the Dynamic component?

> <t:container  
> xmlns:t="http://tapestry.apache.org/schema/tapestry_5_3.xsd">
>
> <h2><span id="param:title"></span></h2>
>
> <div class="row">
>
> <span id="param:blog"></span>
>
> </div>
>
> </t:container>
>
> but I end up with a container tag wrapping my content. Is there a way to
> wrap a dynamic template and have the outer tag ignored?

Have you tried without <t:container> and without a root element? I don't  
think it would work, but I'd try that anyway. :)  It seems you've found a  
bug here. Please file a JIRA about it if you don't find a solution.

-- 
Thiago H. de Paula Figueiredo

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