Chris Pratt ha scritto:
I'm seeing some weird behavior with my tiles definitions that I can't
explain and I was hoping someone smarter than me could lend an eye.
Here's
an excerpt from my tiles-defs.xml:
Err... tags
Andreas, the second method is definitely better from the perspective of
long-term maintainence. You really need just 1 jsp to achieve the task at
hand. Also, using tags should not make the code unreadable since tags were
developed for exactly that purpose. They embed nicely with markup. If you
Hello!
I have to restrict some of my sites according to the role the logged in user
has. There will be a role of admin or user and possibly some more.
How could it be done best?
1. Implementing an own jsp-file for each existing jsp with the reduced roles:
each role would have its own jsp-file.
Hi Group,
In our struts application we have couple of forms. When ever there is
failure in Create form the same page is shown to the user with the data
filled by him. But in one particular form the data is not been shown to
the user. All the forms in the application extend one super form which
Hi all:
I need to put some disabled form fields into my page. When I fill the
components with the server data, not problem, everything goes well. But, when I
submit the form the values of those components are not mapped to the ActionForm
(it's value is the default one).
What can I do to solve
Ah, you are right - looks like a couple poms weren't changed to
2.0.2-SNAPSHOT. Fixed.
Don
David H. DeWolf wrote:
Are you sure it's not just a matter of updating the parent pom's
version? Currently it's still set back to 2.0.1. I think it should
be 2.0.2-SNAPSHOT in the trunk.
Once that'
Hi all:
I need to put some disabled form fields into my page. When I fill the
components with the server data, not problem, everything goes well. But, when I
submit the form the values of those components are not mapped to the ActionForm
(it's value is the default one).
What can I do to solve
Unfortunately, unless I'm missing something, that would lose the extension
to site.layout and the whole chain would be broken. I guess I didn't
include enough of the tiles-defs.xml the first time. Here it is:
http://struts.apache.org/dtds/tiles-config_1_1.dtd";>
It appears like you are extending default.pane with login.error, but the
default.pane is putting the default.layout back in (overidding login.error)
when you call:
Try extending default.layout with login.error and see if that works...
-Original Message-
From: Chris Pratt [mailto:[EMAIL
I'm seeing some weird behavior with my tiles definitions that I can't
explain and I was hoping someone smarter than me could lend an eye. Here's
an excerpt from my tiles-defs.xml:
I have a simple JSP that starts building
Hi there,
Nutshell version:
The problem is that I cannot seem to get access to the session from within
my MessageResources, so I cannot call my 'myWebSession.getLanguageId()'
method.
Explanation:
I need a MessageResources handler too solve two issues: 1) Pulling messages
from a DB table, and 2) P
Hi All,
I have a page with multiple submit buttons. I am
using LookupDispathAction. If I use
button, then everything is working fine. Look at code1
below, which works fine. But, my application requires
to use images instead of standard submit button for
submitting the form. So, if i use the code
fea jabi wrote:
Need to check if the value entered is greater than zero.
Tried the below using the validwhen
test
(*this* > "0.00")
validation seams to be working right when entered 0,0.00,a
Vishal Seth wrote:
Hi,
I need to know what could be the suitable way of proving custom
implementation for the MessageResourceFactory. I have tried with 2 ways:
1) By Overriding ActionServlet and providing implementation for
initModuleMessageResources() and setting my own factory class rather
JCO wrote:
Hello,
I'm trying to pass a variable to a javascript function within a onclick
attribute of html:submit tag, but it doesn't resolve the value of the
varieble. This is the code I'm using:
<%String ent = (String)request.getAttribute("entidad"); %>
Puneet Lakhina wrote:
Hi,
I have the following key value pair in ApplicationResource.properties
required = {0} is required.
I used this when I was doing only server side validation, to display a list
of error messages when some validation failed.
Now Im using the to do the same thing on clien
You could always rig your setters/getters to check the size and create a new
array and copy over to them if the size becomes full. Say start with 10 and
increase by 10 "FormFile"s every time your JSP needs the 11th, 21st, 31st,
etc. Who knows if you will ever actually go over 10? It might work
Ok. Thank you David.
I already have tried this, and it works.
The problem is: FormFile need to be created with correct size. If I
have, for example, 3 files, I need to initialize my arquivo variable
like this: FormFile[] arquivo = new FormFile[3]. Then in JSP I use
indexes like your example.
Are you sure it's not just a matter of updating the parent pom's
version? Currently it's still set back to 2.0.1. I think it should be
2.0.2-SNAPSHOT in the trunk.
Once that's corrected, maven's built-in hierarchy and dependency
resolution will make the build work out of the box.
David
Do
Why do you want to upload multiple files?
How would you determine which files to upload
I want 1,2 and 4
next iteration I want 3 and 5?
What happens in production environments (such as Tomcat)
a concatenation of files is assembled
EAR = WAR + RAR
WebService AAR or JAR
WAR = All jars and All classes
Ok... ok... Thank you.
But your example is very simple. Upload one single file is an easy job.
The problem is how to upload many files (undefined number of files)
using same name field in JSP page.
This works fine with simple fields like String, but not with FormFile.
Martin Gainty escreveu:
Actually I see something else. You are trying to upload files using an
array of FormFiles named arquivo. However, your notation is treating them as
one item instead of indexed. Like so:
private FormFile[] arquivo;
So you see this code in your JSP:
Is not the same as an indexed item or array
Walter-
You need to identify an ActionForm and work up from there
heres a link to get you started
http://www.roseindia.net/struts/strutsfileupload.shtml
your
To: "Struts Users Mailing List"
Sent: Monday, October 16, 2006 3:01 PM
Subject: Why this does not work?
> In Struts 1.1 I used somethin
In Struts 1.1 I used something like that to Upload multiple files
(undefined number of files).
Why does't this work anymore?
public class ConcatenarForm extends ActionForm {
private FormFile[] arquivo;
public FormFile[] getArquivo() {
return arquivo;
}
public void setArq
This issue is expected. The problem, as I see it, is you are trying to
build the latest 'core' trunk, but you don't have its dependency, the
struts2-parent POM version 2.0.2-SNAPSHOT, in your repository. To fix
this, run 'mvn -N install' from the struts2/ directory, which will
install the POM
Need to check if the value entered is greater than zero.
Tried the below using the validwhen
test
(*this* > "0.00")
validation seams to be working right when entered 0,0.00,any string, any
It says that you missed key"userRegistration.firstName", but in your
propertiy file, there is no such key ... :)
On 10/17/06, ram001 <[EMAIL PROTECTED]> wrote:
Hi
In my Struts application the problem is like below
javax.servlet.ServletException: Missing message for key
"userRegistration.firs
Thank you Ted, I want just asking me exactly what you answered. Perfect! I
will try this...
On 10/16/06, Ted Husted <[EMAIL PROTECTED]> wrote:
In Struts 2, the Interceptors are designed to do all the work. There
shouldn't be any token code in an Action class at all. There are three
flavors, t
Hi
In my Struts application the problem is like below
javax.servlet.ServletException: Missing message for key
"userRegistration.firstName" in bundle "(default bundle)" for locale en_US
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:682)
org.apache.jsp.user
Let me try that and check if it works. Thanks Ted
Cesar
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ted Husted
Sent: Monday, October 16, 2006 9:24 AM
To: Struts Developers List
Cc: Struts Users Mailing List
Subject: Re: Struts2 - FATAL ERROR while run
Asunto:
Re: Static objects in Struts Application ..
De:
"Craig McClanahan" <[EMAIL PROTECTED]>
Fecha:
Sat, 14 Oct 2006 17:05:03 -0700
Para:
"Struts Users Mailing List"
Para:
"Struts Users Mailing List"
On 10/13/06, Chris Pratt <[EMAIL PROTECTED]> wrote:
Each Web Application within the co
Me too. Evidentally, I managed to break something in the Maven build
whilst running the Struts 2.0.1 distribution. I'll forward this to
[EMAIL PROTECTED]
In the meantime, you should be able to reference Struts 2.0.1
development build from your POM, if the snapshot repostiory is
referenced.
If you missed the Struts presentations at ApacheCon US 2006 last week,
don't despair, slides and other materials are still available
download.
Migrating to Struts 2 - A tutorial for Struts 1 developers
[Ted Husted] Leverage your hard-earned Struts experience in this
three-hour hands-on tuto
maya ha scritto:
hi,
how do you load tiles dynamically in response to user input..
I have classic setting of nav on the left and main content to the
right of nav tile.. how do I load tiles dynamically in main-content
tile in response to what link user clicks in left nav? (I mean same
princip
> In this action i need to redirect the user to a new page.
> Does anybody know if and how can i do that ?
Response.sendRedirect? Forward with redirect='true'?
Dave
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional comm
In Struts 2, the Interceptors are designed to do all the work. There
shouldn't be any token code in an Action class at all. There are three
flavors, the Token Interceptor, the Token Session Interceptor, and the
Execute and Wait Interceptor.
The Token Interceptor is most like the Struts 1 approac
You can write a controller class for your tiles definition and
accordingly you can set the attribute value as per your requirement for
attribute you want to modify.
-Original Message-
From: maya [mailto:[EMAIL PROTECTED]
Sent: Monday, October 16, 2006 7:12 PM
To: user@struts.apache.org
Su
hi,
how do you load tiles dynamically in response to user input..
I have classic setting of nav on the left and main content to the right
of nav tile.. how do I load tiles dynamically in main-content tile in
response to what link user clicks in left nav? (I mean same principle as
when you loa
The user press a submit botton.
A proper action exist in a LookupDispatchAction.
In this action i need to redirect the user to a new page.
Does anybody know if and how can i do that ?
Any help will be greatly appreciated.
Thanks in advance
Ciao, marcello
-
Hi,
I need to know what could be the suitable way of proving custom
implementation for the MessageResourceFactory. I have tried with 2 ways:
1) By Overriding ActionServlet and providing implementation for
initModuleMessageResources() and setting my own factory class rather
than the default one.
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
> On 10/13/06, Chris Pratt <[EMAIL PROTECTED]> wrote:
> > Each Web Application within the container is loaded within it's own
> > Context (and ClassLoader) which effectively keeps the static's
> > separate.
> In that case, the statics
Bill Milbratz ha scritto:
Hi Antonio,
Thanks for responding.
Short answer: no. But the question is: what do you want it for?
Yes. I should have clarified.
Basically we want to leverage tiles to create a 'poor man's portal'
(i.e. something simple w/o going full-blown jsr 168).
We en
42 matches
Mail list logo