Re: [S2] Display Tag? (2.0.11)

2007-11-02 Thread MLENEVEUT
Or you can use Decorators : display:table name=list decorator=mypackage.decorator.MyDecorator display:column titleKey=colName property=attrNameNotInBean/ /display:table public class MyDecorator extends TableDecorator { public

Struts Type Conversion Problem

2007-11-02 Thread jignesh(india)
Hello, I have read your conversion here, I am having a strange problem in my converter. case 1:- JSP s:textfield name=myDate/ classname-conversion.properties myDate = tutorial.MyTypeConverter case 2:- JSP s:textfield name=user.myDate/

Re: struts2 portlet support

2007-11-02 Thread Nils-Helge Garli Hegvik
Seems like the 2.1.1-SNAPSHOT portlet app bundles servlet-api-2.3.jar. Try removing it and see if that helps. Nils-H On 11/1/07, Brian Relph [EMAIL PROTECTED] wrote: this is the sample webapp downloaded from

Struts 2, file tag, accept attribute not working?

2007-11-02 Thread Anton Pussep
Hello, I am using the following tag for uploading text files: s:file name=myDoc accept=text/plain / I expected it to recognise wrong content types, but it accepts any files I upload. What might be the problem here? I tried this with Struts 2.0.9 and 2.0.11. Best, Anton

Re: [s2] templating approach / own tag?

2007-11-02 Thread Antonio Petrelli
2007/11/2, lbastil [EMAIL PROTECTED]: Thank you for this hint, but in this case I don't think so. I am already use tiles for the overall page structure, but for this minor substructures I don't want to use a kind of tiles sub-hierarchy. Ok I think I understood: so you want a piece of code

Re: [s2] templating approach / own tag?

2007-11-02 Thread Dave Newton
You can still create custom tags in Java if you're dead-set on it. Or you can use JSP 2.0 tags, where your tag implementation is in JSP. There are a lot of ways of doing what you're trying to do. I don't know why you're opposed to using tiles, particularly if you're already invested in it. d.

Re: [s2] templating approach / own tag?

2007-11-02 Thread lbastil
Thank you for this hint, but in this case I don't think so. I am already use tiles for the overall page structure, but for this minor substructures I don't want to use a kind of tiles sub-hierarchy. Is there no equivalence to former custom tag? Something like a ftl-script I can apply

Re: [s2] templating approach / own tag?

2007-11-02 Thread Antonio Petrelli
Thinking on it a bit, Basti, I think that your best friend would be Sitemesh: http://www.opensymphony.com/sitemesh/ If you have the same structure (or a small number of structures) across all the application, this is the easier approach. Struts 2 has a Sitemesh plugin too:

Re: [s2] templating approach / own tag?

2007-11-02 Thread Antonio Petrelli
2007/11/2, Rod Bollinger [EMAIL PROTECTED]: Tiles (and in Struts 1? Tiles) :-) And for the newcoming Struts 1.4, Tiles 2 :-) Sorry for the advertisement :-P Antonio

RE: [s2] templating approach / own tag?

2007-11-02 Thread Rod Bollinger
Tiles (and in Struts 1? Tiles) :-) http://struts.apache.org/1.x/struts-tiles/ -Rod -Original Message- From: lbastil [mailto:[EMAIL PROTECTED] Sent: Friday, November 02, 2007 10:43 To: user@struts.apache.org Subject: [s2] templating approach / own tag? Hi, I want to archive the

Re: [s2] templating approach / own tag?

2007-11-02 Thread Antonio Petrelli
2007/11/2, lbastil [EMAIL PROTECTED]: Hi, I want to archive the following: I noticed in my page code often this redundant structure: (dynamic parts in []) div id=headerTitle [Header Section Name] /div div id=headerContent [ ... various different content, tables, ... and so on ]

[s2] templating approach / own tag?

2007-11-02 Thread lbastil
Hi, I want to archive the following: I noticed in my page code often this redundant structure: (dynamic parts in []) div id=headerTitle [Header Section Name] /div div id=headerContent [ ... various different content, tables, ... and so on ] /div Now I would like to create some parameterized

Re: struts2 portlet support

2007-11-02 Thread Brian Relph
unfortunately that does not solve the problems. the readme states that the app is not ready to run because there are portal-container specific configurations that are required - it comes packaged with jboss and liferay configurations. i find it odd that previous versions of the app can run

Re: Problems with Number Format

2007-11-02 Thread Moacir Cardoso
Hi everyone, I've found the source off my problem. It seams that if you want to format a value in s:textfield tag you have to: s:text id=myFieldValueID name=format.numbers:param name=value value=myFieldValue //s:text s:textfield id=txtmyFieldValue name=myFieldValue value=%{myFieldValueID}/

RE: Struts Type Conversion Problem

2007-11-02 Thread Shannon, Andrew
I also submitted an email yesterday related to type conversion and your observation below was very helpful. The fact that your case 2 doesn't work also describes my problem (submitted as interceptor and converter cycle). For now I guess I'll go with case 1 at the Action class level in order to

ModelDriven vs OGNL assignment?

2007-11-02 Thread Gary Affonso
In our previous WebWork app we were not using ModelDriven and just relying on OGNL assignment... * We ensure our action provides a getter for the domain object private Account account; public Account getAccount(); * We ensure html fieldnames include both the domain object name and the

Re: ModelDriven vs OGNL assignment?

2007-11-02 Thread Dave Newton
--- Gary Affonso [EMAIL PROTECTED] wrote: And that does it. Direct model injection. Easy. Technically, no, it's indirected by one level. *All* ModelDriven does is push the model on to the stack so it's available at the top level. AFAIK there's no compelling reason to do that other than saving

Re: Struts 2, file tag, accept attribute not working?

2007-11-02 Thread Martin Gainty
Hi Anton which theme is specified in your s:head tag? Martin- - Original Message - From: Anton Pussep [EMAIL PROTECTED] To: Struts Users Mailing List user@struts.apache.org Sent: Friday, November 02, 2007 6:03 AM Subject: Struts 2, file tag, accept attribute not working? Hello, I

Re: Struts 2, file tag, accept attribute not working?

2007-11-02 Thread Anton Pussep
There is no s:head tag, since I am not using Ajax. Thus it should be the default xhtml. Best, Anton Martin Gainty wrote: Hi Anton which theme is specified in your s:head tag? Martin- - Original Message - From: Anton Pussep [EMAIL PROTECTED] To: Struts Users Mailing List

Re: ModelDriven vs OGNL assignment?

2007-11-02 Thread Jon Wilmoth
Besides the simplified view references, I've used the level of indirection to allow for a dynamic model on a single action class that implements a number of related actions. In my case the action configuration sets a static property that defines the model property. The getModel implemenation

Redirect a form

2007-11-02 Thread Jeff Bowes
We are currently using Struts 1.2.7. In our application if a user attempts to access an interface that they need to be logged into to use but are not currently logged in they are redirected to a login interface. The url for the original interface they were trying to access is passed as a

Re: ModelDriven vs OGNL assignment?

2007-11-02 Thread Gary Affonso
Jon Wilmoth wrote: Besides the simplified view references, I've used the level of indirection to allow for a dynamic model on a single action class that implements a number of related actions. In my case the action configuration sets a static property that defines the model property. The

Re: ModelDriven vs OGNL assignment?

2007-11-02 Thread Gary Affonso
Dave Newton wrote: --- Gary Affonso [EMAIL PROTECTED] wrote: And that does it. Direct model injection. Easy. Technically, no, it's indirected by one level. *All* ModelDriven does is push the model on to the stack so it's available at the top level. AFAIK there's no compelling reason to do

Extending the FreemarkerManager

2007-11-02 Thread ARakesh
I am extending to FreemarkerManager to customize the tempalte: @Override protected Configuration createConfiguration(ServletContext servletContext) throws TemplateException { Configuration config = super.createConfiguration(servletContext); ClassTemplateLoader ctl = new

RE: Struts Type Conversion Problem

2007-11-02 Thread jignesh(india)
For the conversion to work with user.myDate, we need to create a properties file named User-conversion.properties and locate it in the directory where the user class resides (assuming your User class is an org.appfuse.model.User). Then inside that file, we have to put: mydate =

Re: Redirect a form

2007-11-02 Thread Paul Benedict
I refer you to the Acegi Security project which does this. They have a SavedRequest class which contains a copy of the request parameters and such of the original request. This object is stored in the session. When the login succeeds, the SavedRequest is then extracted into a new request object