You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by Jiang Hua <hu...@samsung.com> on 2009/03/13 03:46:13 UTC

[t5.0.18] Is it possible to use a filter name other than "app"?

It seems that the module builder classes are ignored (non method of these
methods are executed), when the web app is started, if a filter name
different from "app" is used in web.xml. Is it mandatory to use "app"? Or is
it a bug?
-- 
View this message in context: http://www.nabble.com/-t5.0.18--Is-it-possible-to-use-a-filter-name-other-than-%22app%22--tp22489217p22489217.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: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Jonathan O'Connor <ni...@eircom.net>.
Zenberg,
I added Tap5 pages to an existing struts 1 application. The trick is to 
reimplement a login page (I presume you have a login page) as a T5 page, 
and then you can initialize the JSP session variables you need for 
working together. You will also have to be careful generating links from 
JSP to T5 and vice versa. If you do make changes to your layout, then 
you will need to reimplement them in a JSP as well.

Search this list for integrating struts with T5 (also look for Kent 
Tong, who came up with the original solution for T4).
Ciao,
Jonathan

On 13/03/2009 04:48, Zenberg Ding wrote:
>
> But that's only put them together without runtime error. each of them 
> is working standalone, so it's not really working together...
>
>>
>> As far as I know, you can have Tapestry pages and JSP pages and 
>> Struts actions in the same application working together, but you 
>> cannot have JSP and Tapestry templates in the same page. They're 
>> completely different.
>>
>
> ---------------------------------------------------------------------
> 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: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Zenberg Ding <ze...@gmail.com>.
But that's only put them together without runtime error. each of them is  
working standalone, so it's not really working together...

>
> As far as I know, you can have Tapestry pages and JSP pages and Struts  
> actions in the same application working together, but you cannot have  
> JSP and Tapestry templates in the same page. They're completely  
> different.
>

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


Re: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Em Fri, 13 Mar 2009 01:06:08 -0300, Zenberg Ding <ze...@gmail.com>  
escreveu:

> really sorry about that.

It's ok. :)

> I know tapestry's template engine, that's why we try to using it.
> but there are a big amount of leaving code useing struts 1.xx.
> so if there is a way can mixing those code into t5 framework. I can  
> wrote a dispatcher to recognize '*.do' url and give it to one  
> ActionRequestHandler.

Tapestry is not a servlet, it is a servlet filter, so Struts and Tapestry  
can coexist in the same application with no problems. Take a look at the  
"Ignored Paths" of this page:  
http://tapestry.apache.org/tapestry5/guide/conf.html.

> and is it possible nest the response content into one layout components'  
> content region in this ActionRequestHandler?

As far as I know, you can have Tapestry pages and JSP pages and Struts  
actions in the same application working together, but you cannot have JSP  
and Tapestry templates in the same page. They're completely different.

-- 
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

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


Re: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Zenberg Ding <ze...@gmail.com>.
really sorry about that.

I know tapestry's template engine, that's why we try to using it.

but there are a big amount of leaving code useing struts 1.xx.

so if there is a way can mixing those code into t5 framework. I can wrote  
a dispatcher to recognize '*.do' url and give it to one  
ActionRequestHandler.

and is it possible nest the response content into one layout components'  
content region in this ActionRequestHandler?

thanks.



> Em Fri, 13 Mar 2009 00:43:45 -0300, Zenberg Ding  
> <ze...@gmail.com> escreveu:
>
>> If it possible, how to do it? any idea or suggestion is appreciate.
>
> Please start new topics in new threads, not replying to old ones.
>
> Tapestry has its own template engine, so you cannot embedded JSP there.
> Layout is just an ordinary component in Tapestry, so you can write any  
> HTML you want inside it.
>



-- 
使用 Opera 革命性的电子邮件客户程序: http://www.opera.com/mail/

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


Re: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Em Fri, 13 Mar 2009 00:43:45 -0300, 丁振波 <ze...@gmail.com>  
escreveu:

> If it possible, how to do it? any idea or suggestion is appreciate.

Please start new topics in new threads, not replying to old ones.

Tapestry has its own template engine, so you cannot embedded JSP there.
Layout is just an ordinary component in Tapestry, so you can write any  
HTML you want inside it.

-- 
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

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


[t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by 丁振波 <ze...@gmail.com>.
If it possible, how to do it? any idea or suggestion is appreciate.

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


Re: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Zenberg Ding <ze...@gmail.com>.
Thanks for your advise. I'll try that.


> On Thu, Mar 12, 2009 at 8:53 PM, Zenberg Ding <ze...@gmail.com>  
> wrote:
>>
>> Is it possible to nested normal jsp/html content into one layout  
>> component
>> region?
>
> No.  Not possible.  Completely incompatible approaches to ... everthing.
>
>
> You might be able to cobble something together using Ajax and/or an
> <iframe> to spawn a second request that renders using the JSP.
>

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


Re: [t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Howard Lewis Ship <hl...@gmail.com>.
On Thu, Mar 12, 2009 at 8:53 PM, Zenberg Ding <ze...@gmail.com> wrote:
>
> Is it possible to nested normal jsp/html content into one layout component
> region?

No.  Not possible.  Completely incompatible approaches to ... everthing.


You might be able to cobble something together using Ajax and/or an
<iframe> to spawn a second request that renders using the JSP.

>
> for example, replace "content" region with jsp content when one jsp request
> is lanched.
>
> <body>
> <table id="main" width="100%" height="100%" border="0">
>  <tr>
>    <td id="header" height="94" colspan="3">
>        <div t:type="header"/>
>    </td>
>  </tr>
>  <tr>
>    <td id="navigator">
>        <div t:id="treebox" t:type="t5/SidePanel" style="height:600px">
>                <div t:type="xtree"/>
>        </div>
>    </td>
>    <td width="2">
>        <div id="split"/>
>    </td>
>    <td id="content">
>        <t:body/>
>    </td>
>  </tr>
>  <tr>
>    <td id ="footer"  height="90" colspan="3">
>        <div t:type="footer"/>
>    </td>
>  </tr>
> </table>
> </body>
>
> If it possible, how to do it? any idea or suggestion is appreciate.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

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


[t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Zenberg Ding <ze...@gmail.com>.
Is it possible to nested normal jsp/html content into one layout component  
region?

for example, replace "content" region with jsp content when one jsp  
request is lanched.

<body>
<table id="main" width="100%" height="100%" border="0">
   <tr>
     <td id="header" height="94" colspan="3">
     	<div t:type="header"/>
     </td>
   </tr>
   <tr>
     <td id="navigator">
     	<div t:id="treebox" t:type="t5/SidePanel" style="height:600px">
	    	<div t:type="xtree"/>	    	
     	</div>
     </td>
     <td width="2">
     	<div id="split"/>
     </td>
     <td id="content">
     	<t:body/>
     </td>
   </tr>
   <tr>
     <td id ="footer"  height="90" colspan="3">
     	<div t:type="footer"/>
     </td>
   </tr>
</table>
</body>

If it possible, how to do it? any idea or suggestion is appreciate.

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


Re: [t5.0.18] Is it possible to use a filter name other than "app"?

Posted by Howard Lewis Ship <hl...@gmail.com>.
On Thu, Mar 12, 2009 at 7:51 PM, Thiago H. de Paula Figueiredo
<th...@gmail.com> wrote:
> Em Thu, 12 Mar 2009 23:46:13 -0300, Jiang Hua <hu...@samsung.com>
> escreveu:
>
>> It seems that the module builder classes are ignored (non method of these
>> methods are executed), when the web app is started, if a filter name
>> different from "app" is used in web.xml. Is it mandatory to use "app"?
>
> No.
>
>> Or is it a bug?
>
> No too. If your filter name is tapestryfilter, your module class will be
> TapestryFilterModule and your properties files will be
> tapestryfiltermodule.properties.


Almost correct.  The filter name is used for the global application
properties file, so a filter name of "tapestryfilter" would look for
WEB-INF/tapestryfilter.properties.

The capitalized name is used for the module, thus
somepackage.service.TapestryfilterModule.  Tapestry doesn't know how
to captialize two word names ... it just capitalizes the first letter.

>
> --
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> http://www.arsmachina.com.br/thiago
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
>
>



-- 
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

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


[t5.0.18] Is it possible to nested normal jsp/html content into one layout component region?

Posted by Zenberg Ding <ze...@gmail.com>.
If it possible, how to do it? any idea or suggestion is appreciate.

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


Re: [t5.0.18] Is it possible to use a filter name other than "app"?

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
On Fri, Mar 13, 2009 at 1:41 AM, Jiang Hua <hu...@samsung.com> wrote:

> Thank you, Thiago. And what if there are spaces in the filter name?

Why would you have spaces in the filter name? Maybe it's not even
correct according to the servlet spec.s

> Where can
> I find a full document about all the tapestry naming conventions?

There isn't one, but each feature that has naming conventions have
them documented in their docs.

-- 
Thiago

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


Re: [t5.0.18] Is it possible to use a filter name other than "app"?

Posted by Jiang Hua <hu...@samsung.com>.
Thank you, Thiago. And what if there are spaces in the filter name? Where can
I find a full document about all the tapestry naming conventions?


Thiago H. de Paula Figueiredo wrote:
> 
> Em Thu, 12 Mar 2009 23:46:13 -0300, Jiang Hua <hu...@samsung.com>  
> escreveu:
> 
>> It seems that the module builder classes are ignored (non method of these
>> methods are executed), when the web app is started, if a filter name
>> different from "app" is used in web.xml. Is it mandatory to use "app"?
> 
> No.
> 
>> Or is it a bug?
> 
> No too. If your filter name is tapestryfilter, your module class will be  
> TapestryFilterModule and your properties files will be  
> tapestryfiltermodule.properties.
> 
> -- 
> Thiago H. de Paula Figueiredo
> Independent Java consultant, developer, and instructor
> http://www.arsmachina.com.br/thiago
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tapestry.apache.org
> For additional commands, e-mail: users-help@tapestry.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/-t5.0.18--Is-it-possible-to-use-a-filter-name-other-than-%22app%22--tp22489217p22490133.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: [t5.0.18] Is it possible to use a filter name other than "app"?

Posted by "Thiago H. de Paula Figueiredo" <th...@gmail.com>.
Em Thu, 12 Mar 2009 23:46:13 -0300, Jiang Hua <hu...@samsung.com>  
escreveu:

> It seems that the module builder classes are ignored (non method of these
> methods are executed), when the web app is started, if a filter name
> different from "app" is used in web.xml. Is it mandatory to use "app"?

No.

> Or is it a bug?

No too. If your filter name is tapestryfilter, your module class will be  
TapestryFilterModule and your properties files will be  
tapestryfiltermodule.properties.

-- 
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

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