Jen,
The question is are you trying to catch mistyped Struts URLS OR regular URL
resources such as JSPs, HTML, CSS, Javascript includes, Images, etc.?
For the former, you're barking up the wrong tree (see below). For the
latter, your error-page code should work UNLESS those file types are NOT
bei
Hi
I have not used Struts with Jtidy but I've used the two technologies in
different projects. The way I see it you create a servlet filter that uses
the Tidy.parse method to parse the JSP output. Then you map the filter to
the main JSPs that includes the rest of the content. Everytime the
control
Has anybody integrated JTidy or any of the other HTML-prettifiers with
Struts? I find Tidy does a good job of cleaning up JSPs, which tend to get
pretty spaced out particularly when there are lots of includes, but I don't
have a clear idea of where it would plug in. Would it make sense to put it
Thanks Niall.
The problem is, some stuff is served out of Apache's doc root, while
other stuff is served by Tomcat. I am hoping to find a central place to
install the IP restriction.
The valve won't restrict what is in Apache's doc root, and the .htaccess
file won't restrict what is dispatched
Don't know about Apache, but what about configuring Tomcat - doc say there
are remote filters which looks like they would do what you want:
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/config/valve.html
Niall
- Original Message -
From: "Erik Weber" <[EMAIL PROTECTED]>
To: "Struts Us
Robert,
Thanks for the feedback. I took a look at Spring. It seems interesting but
I decided to pass on it right now rather than take the time to get up to
speed on yet another framework.
I did take a look at ThreadLocal, however, and I think this will be perfect
for what I need. In fact I f
You could take a look at the Spring framework - very cool!
|-+>
| | "Sean Schofield" |
| | <[EMAIL PROTECTED]|
| | chof.com>|
| ||
| | 09/17/20
Hi,
After reading the email archives and the documentation, it is clear that
the tag cannot be used with a module attribute and a page
attribute at the same time. I was just wondering why this is? Is there a
strong reason this was not implemented, or is it just a piece of missing
functionality?
I have a site running on a third-party box that uses Apache in front of
Tomcat. I need to restrict the entire site to a series of IP addresses.
Using the Deny, Order and Allow commands in a .htaccess file works for
whatever is in Apache's public document root. However, it doesn't
prevent reques
what about using the crossContext feature of tomcat? (and here i go out
on a limb without checking how sturdy it is, but I can't find much docs
on this) Could I set up a servlet that was just a bunch of JSP's that I
use in all the apps?
too many questions ;)
On Fri, 2004-09-17 at 08:32, josh
hihi all,
has anyone encountered a SAX xml parsing error due to some
property/attribute of a physical file?
i'm getting that right now. an xml file created by a legacy VMS system
is causing SAX parsing exceptions. BUT, if i copy and paste the
contents of that file into my own file, i don't get
We use option one - separate packages for actions, forms, dao, services,
util, etc.
Rick Reumann
<[EMAIL PROTECTED]
Why can't you call the init() method from inside the execute() method (at the
beginning of it )?
Anna
From: Caroline Jen [mailto:[EMAIL PROTECTED]
Sent: Fri 17/09/2004 2:06 PM
To: [EMAIL PROTECTED]
Subject: No Way to Put the init() Method Inside the ActionForwa
You summed it up perfectly. And that test case works for me too. As does
my own now. I've no idea what I changed between last night and now, but
everything's now fine! I'm glad of that but I hate mystery bugs...
L.
Kris Schneider wrote:
This worked on TC 5.0.28:
/WEB-INF/tags/tag1.tag:
-
Why not write an InitServlet that is set to initialize prior to the struts
ActionServlet in web.xml? This could override the init() method and provide
the services you need.
>From web.xml
init
com.xxx.xxx.servlet.InitServlet
log4jProperties
conf/log4
Sean, have you looked at Spring? It uses AOP and you can set up transactions
declaratively.
I'm just starting to investigate using Spring and I'm really impressed.
Like you I had a requirement to demarcate transactions at a high level so that
all business objects within the transaction were subj
Yep. I usually bunch all action type stuff in the action package.
Like forms, action utils, value objects used in actions, etc...
I guess it more or less represents the presentation part of the package
and the service represents the business part. I only see a need to dissect
it into these two beca
I had thought about this but it involves duplicating each DAO method. Also
if I ever wanted to switch to EJB I would have to undo all of the methods
again. Its definitely an option though. I was just hoping for something
that would involve less changes to my DAO's.
Thanks for the feedback.
s
Robert Taylor wrote the following on 9/17/2004 2:58 PM:
com.acme.applications.web.foo.account.action
com.acme.applications.web.foo.account.service
Yea that was my option 2 I posted. I'm still debating about this one as
well. I can see both approaches being decent:
com.acme.applications.web.foo.ac
Yes, that's exactly what happens. I understand your approach, even like
it! :)
I think what it comes down to is do you break things up in an
object-oriented way or a functional way?
It can be argued that done as you say, you are breaking it up based on
objects, which mimics how we generally dev
Rick,
I have been using the following package layout for a while and it seems to make sense.
For example, let's say the foo web application consists of various sub applications
like
account, store, product download, etc
com.acme.applications.web.foo.account.action
com.acme.applications.we
Frank W. Zammetti (MLists) wrote the following on 9/17/2004 2:54 PM:
I personally use #3.
com.company.project
|
*---actionforms
|
*---actions
|
Won't you end up with a TON of Actions though in one package?
EmployeeUpdateAction
EmployeeDeleteAction
EmployeeSearchSetUpAction
EmployeeSearchGe
Forgot to mention, although you probably guessed... Any other class
specific to the app that doesn't fit any of the categories (things like
helper classes used in may different Actions) are in com.company.project.
--
Frank W. Zammetti
Founder and Chief Software Architect
Omnytex Technologies
http
I personally use #3. In fact, all my projects have a pretty
internally-standard packaging scheme (my own creation)...
com.company.project
|
*---actionforms
|
*---actions
|
*---business
|
*---config
|
*---daemonthreads
|
*---exceptions
|
*---listeners
|
*---plugins
|
*---webservi
Overload each existing DAO method with a secondary method that accepts
the Connection as a parameter instead of getting it on its own. Then let
your service layer object obtain the Connection, set autocommit to
false, invoke all the DAO methods you need, passing the customized
Connection to eac
I have a problem and a proposed solution. I would greatly appreciate any feedback
about the proposed solution.
Problem:
===
I'm currently using a Struts application with a connection pool (using DBCP as
supplied by Tomat). When a database update is needed, the Struts actions will call
the
I would write a Struts Plug-In (very easy) and initialize the
"smtpServer" variable (and similar variables) there, making the
configured value available to the rest of the application (including
your Actions) by setting an Application scope attribute (this also
abstracts the configuration so th
After thinking about the flavors of Dispatch actions I use, and after
having used them as my primary type of Actions for the past 3+ years,
I've decided to go back to just using regular Actions. I like the
modular self contained Actions.
My question is more of design practice for those that jus
Isn't an Action's 'input' parameter supposed to be context relative?
I thought that it was supposed to be, but I'm seeing otherwise when
my form, which is in a module, fails its validation test.
Instead of returning to the input form, it is forwarding to the input
form prefixed with the module
We cannot put a method inside another method.
When using the Struts, we start with:
public final class MyClass extends Action
{
public ActionForward execute( ActionMapping
mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response )
If you want to have a default value, simply set the default value in the form bean.
Eg :
XYZForm{
String name = "Ryan";
public String getName(){
return name;
}
public String setName(String name){
this.name = name;
}
}
-Original Message-
From: Asleson, Ryan [mailto:[EMAIL PROTEC
FYI
Regards,
Matthias
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of
Takashi Okamoto
Sent: Friday, September 17, 2004 6:23 PM
To: [EMAIL PROTECTED]
Subject: [Myfaces-develop] [FYI] Nirvana - HTML2JSF converter
Hi,
I would like you to inform Nirvana w
Martin Schaefer wrote:
Can you set the
value somewhere in the session and pick it up again in the second
form's reset method? Maybe I didn't understand your problem entirely...
Thanks, that worked perfectly :) But, the JavaDoc states that the
reset() method should not be used for initialisation. S
As per the Tiles Definition file syntax
In the tiles definition we can specify the role
(Role to be checked when definition will be inserted in a page.)
Similarly, It is possible to associate a role with tiles: put attribute.
I'm intending to allow the definition to be used based on the role
This it test mail. Kindly ignore it.
[EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
Seyhan Basmaci wrote:
Hi,
We have upgraded to Struts 1.2.2 , but we have encountered a problem. Embedded
JavaScript validators use the following code
function validateRequired(form) {
var isValid = true;
var focusField = null;
var i = 0;
var fields = new Array()
On radio buttons
http://www.jguru.com/faq/view.jsp?EID=1028442
has helped me. With the special problem you described. Can you set the
value somewhere in the session and pick it up again in the second
form's reset method? Maybe I didn't understand your problem entirely...
Ricardo Gladwell <[EMAIL
Dave,
On Fri, 17 Sep 2004 10:20:53 -0500, Dave Bender <[EMAIL PROTECTED]> wrote:
> I'm concluding that if I have multiple modules, I need the Plug-Ins plugged into
> each module, correct? The benefit being I can keep validation rules contained in
> different files for different modules if I
Fixed.
It needs to use the ${ } notation in c:set like shown below:
Thanks to everybody for their help.
-Original Message-
From: Asleson, Ryan
Sent: Friday, September 17, 2004 10:05 AM
To: 'Struts Users Mailing List'
Subject: RE: Struts Taglib Question
I tried the following:
Clarification: I have this in my struts-config.xml file, but I have a modular
application and the plug was not in the module's config file, profile-config.xml.
I've added it an now I'm getting past the "Resources not defined..." exception.
Instead, I'm getting "java.lang.NoSuchMethodException
Hi All,
I'm trying to set the initial value on a set of elements.
Unlike other html tags, I notice there is no way to specify the initial
value unless you specify the value in the form bean constructor/reset
method itself.
I am forwarding to a page containing and html:form with radio buttons
I tried the following:
and got this exception:
[ServletException in:/jsp/registration/register.jsp] Invalid property in
: "event.date"' javax.servlet.jsp.JspTagException: Invalid property in
: "event.date" at
org.apache.taglibs.standard.tag.common.core.SetSupport.doEndTag(SetSupport.j
ava
Dave,
On Fri, 17 Sep 2004 09:26:18 -0500, Dave Bender <[EMAIL PROTECTED]> wrote:
> When I call up my action, I'm getting a "Resources not defined for Validator"
> exception. My logs say:
>
> 87406 DEBUG [HttpProcessor[8080][2]] org.apache.struts.action.RequestProcessor -
> Validating
Yes, I have:
...
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Friday, September 17, 2004 9:37 AM
To: Struts Users Mailing List
Subject: Re: "Resources not defined for Validator"
Do you have the plug-in set in the struts-config.xml?
Do you have the plug-in set in the struts-config.xml?
"Dave Bender"
<[EMAIL PROTECTED]>
I experienced this last week, had to rebuild my projects and update WSAD to
5.1. Just out of interest are you working for IBM, I know they are doing
some work there.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional co
I use WSAD 5.0 for dev and out of nowhere it started using up all my
machine's memory (1G). There's not much in the log which is below. While
I'm waiting for support to call I was wondering if anybody has ever seen
anything like this? This is happening when all I'm doing is editing a file
i
I'm having a challenge getting the Validator plug-in to work. It's my first crack at
it, so forgive if I'm missing something obvious. Better yet, if I am missing
something obvious, tell me what it is.
When I call up my action, I'm getting a "Resources not defined for Validator"
exception. M
> By dot notation I just mean the dot notation for properties,
> like event.date really means getEvent().getDate().
Of course JSTL honors that convention.
--
Tim Slattery
[EMAIL PROTECTED]
-
To unsubscribe, e-mail: [EMAIL P
By dot notation I just mean the dot notation for properties, like event.date
really means getEvent().getDate().
Thank you very much for your help!
-Original Message-
From: Slattery, Tim - BLS [mailto:[EMAIL PROTECTED]
Sent: Friday, September 17, 2004 9:08 AM
To: 'Struts Users Mailing
> I was hoping for something like this. Does JSTL understand
> the dot notation like Struts tags do?
Not quite sure what you mean. Certainly JSTL's EL (expression language) is
the same as that used by the Struts-el tags.
--
Tim Slattery
[EMAIL PROTECTED]
I was hoping for something like this. Does JSTL understand the dot notation
like Struts tags do?
==
==
Try JSTL:
Note: this code has not been tested
--
Tim Slattery
[EMAIL PROTECTED]
-
> Is there some sort of Struts tag that I can use to set the
> property of a bean?
>
> I have a small fragment that I want to look like this:
>
>
> <%-- Set the event.date property on formBean to a default
> value --%> property="event.date">
Try JSTL:
Note: this code has no
JSTL :
Nico.
>
> Hello,
>
> Is there some sort of Struts tag that I can use to set the property of a
> bean?
>
> I have a small fragment that I want to look like this:
>
>
> <%-- Set the event.date property on formBean to a default value --%>
>
>
>
>
>
> It says that "if the event
Is there a reason you can't do this in the action which precedes your jsp?
Anyway, from JSTL does this for you.
Paul
> -Original Message-
> From: Asleson, Ryan [mailto:[EMAIL PROTECTED]
> Sent: Friday, September 17, 2004 2:57 PM
> To: '[EMAIL PROTECTED]'
> Subject: Struts Taglib Questio
Hello,
Is there some sort of Struts tag that I can use to set the property of a
bean?
I have a small fragment that I want to look like this:
<%-- Set the event.date property on formBean to a default value --%>
It says that "if the event.date property on formBean is an empty String
Still interested to hear if anyone has any ideas about this...
On Wed, 2004-09-15 at 10:47, josh wrote:
> Hi all,
>
> I am writing multiple apps (~20) that all share the same sidebar
> navigation.
>
> Is there a way to make multiple applications use a central library of
> tiles so that I would b
Ok, how do you plan to manage your connection pool?
--
James Mitchell
Software Engineer / Open Source Evangelist
EdgeTech, Inc.
678.910.8017
AIM: jmitchtx
- Original Message -
From: "liooil " <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 8:50 AM
Subject: Re:
not quite .. when i arrive initially at the view governed by somePage.jsp yes, there
are a bunch of request attributes set up. on this page is my form. as a hidden
variable to the form I copy the existing page id because this must be present for our
SecuredBaseAction to know what properties to l
yes, please. I would appreciate your help
so let's go...
Where i can i fin such a JDBC connector ?
And how i configure/use it ?
Thx,
___[ Pub ]
Inscrivez-vous gratuitement sur Tandaime, Le site de rencontres !
http://rencontre.rencontre
when i submit my form to the action, the action maps my form to a DynaActionForm and
binds the values.
now, along with my form, i actually do submit something called PID (page id) which is
the current page at time of submission. therefore, my dyna form will have the page id
for which i need to
Hello,
You can create filter for the login page.
That filter should disconnect the user of the web application (if exists).
All users that access login page, will be forced to be authenticates again.
If problem persist, it could be web cache.
Luis Urueña Frías Oficina 101 - Edificio Galileo,
This worked on TC 5.0.28:
/WEB-INF/tags/tag1.tag:
---
<%@ tag body-content="empty" %>
<%@ taglib prefix="tags" tagdir="/WEB-INF/tags/" %>
/WEB-INF/tags/tag2.tag:
---
<%@ tag body-content="empty" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/c
You can put JavaScript on every page that will attempt to send the browser
to a specific url when the browser is closing, but that would be browser
specific and it is VERY likely that your action will never get called for
most users. This is the web, if you want that feature you will need to go
ri
You would need a JDBC driver that supports file based storage. You are
better off using HSSQLDB. I can help you with that.
--
James Mitchell
Software Engineer / Open Source Evangelist
EdgeTech, Inc.
678.910.8017
AIM: jmitchtx
- Original Message -
From: "liooil " <[EMAIL PROTECTED]>
To
> managing a request attribute in the session by setting it and then making sure we
> pop it out at the view is messing and defies the semantic use of the request scope.
>
> that's why it is bad practice.
>
Don't shoot me if I'm wrong but HTTP is stateless so without any of:
cookie, session, bro
Hello world,
Maybe, it's not designed for that, but i wonder if i can
use struts conf to access a local
file system (file://...) ?
I know this request is a bit strange, but it's for a very
temporary solution. No sql server available for the moment ...
Is it possible?
If so, where should i get
fine... n one more thing is.. if the user login to the system..from
the login page then the welcome page is displayed.. then if the user
clicks the back button from the browser he will visit the login page
...but if the user clicks the forward button session should be
invalid..how to do that?
On
Use javascript to load a function on window event close. Let that
javascript pass a request to an action (like InvalidateSessionAction that
holds the logic to manage the same). thats it.
Jitender Kumar C.V.
how to invalidate the session when user clicks the close(cross) button
which will display at the right side of the browser when we open a
page..
--
Kranti Kiran Kumar Parisa
Software Engineer [ e-Biz ],
Patni Computer Systems Ltd.,
India
Mobile: +91 98504 45977
---
how to invalidate the session when user clicks the close(cross) button
which will display at the right side of the browser when we open a
page..
On Fri, 17 Sep 2004 08:01:45 -0400, James Mitchell <[EMAIL PROTECTED]> wrote:
> What is 'bad practice'?
>
> --
> James Mitchell
> Software Engineer /
what I have already described in some detail. the use of base actions is a good
pattern to use as one can group common behaviour into them, such as authentication or
ensuring other properties. in our case we do both, security AND ensuring some session
lists for user (i.e those things that make s
I am really sorry abt that...next time i wont repeat that
On Fri, 17 Sep 2004 17:27:58 +0530, Jitender K Chukkavenkata
<[EMAIL PROTECTED]> wrote:
> Let us respect group values...No personals pleasesend a personal mail
> if curious of knowing...
>
> Jitender Kumar C.V.
>
>
--
Kranti Kir
What is 'bad practice'?
--
James Mitchell
Software Engineer / Open Source Evangelist
EdgeTech, Inc.
678.910.8017
AIM: jmitchtx
- Original Message -
From: "Allistair Crossley" <[EMAIL PROTECTED]>
To: "Struts Users Mailing List" <[EMAIL PROTECTED]>
Sent: Friday, September 17, 2004 7:58 AM
Let us respect group values...No personals pleasesend a personal mail
if curious of knowing...
Jitender Kumar C.V.
Hi Jitender,
Thanx for ur warm welcome...
Hey r u from A.P.??
'coz ur names look like that..
iam from A.P., VIJAYAWADA
anyways it doesnt matter..nice to meet u ...
--
Kranti
On Fri, 17 Sep 2004 17:23:38 +0530, Jitender K Chukkavenkata
<[EMAIL PROTECTED]> wrote:
> Waaarm welcome Kranti...Have
but that's bad practice. very bad.
> -Original Message-
> From: Jitender K Chukkavenkata [mailto:[EMAIL PROTECTED]
> Sent: 17 September 2004 12:51
> To: Struts Users Mailing List
> Subject: Re: DynaActionForm and previous request attributes (no answer
> found in archives for similar proble
Waaarm welcome Kranti...Have funn...
Jitender Kumar C.V.
I would agree with him. I can suggest you the same.
Jitender Kumar C.V.
Hello Friends,
This is Kranti Parisa, Software Engineer.
I am working with Patni Computer Systems Ltd.
Our Project is using the Struts Framework.
So I will be in this mailing list from 2day onwards...
Have a nice time..
Bye for now
Kranti Parisa
Return Receipt
Your suggestion needed.
document
:
Return Receipt
Your problem in db access
document
:
> Now, my understanding was that DynaActionForm manages to populate a map of
> form fields, match them up against validation rules, and if it fails, it
> would KEEP the previous request but add errors into it and FORWARD back to
> the view, therefore KEEPING all the request attributes. It does not
Now it works
Thank you very much!!
Jitender K Chukkavenkata schrieb:
hei
just check this :+
Are you setting attribute message="true" ?
Thanks.
Jitender Kumar C.V.
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additi
hei
just check this :+
Are you setting attribute message="true" ?
Thanks.
Jitender Kumar C.V.
Please tell me Y are you using the shaded code when the classes being used
are depricated.
If i use this:
i get no message in my jsp file.
Once Again my Actionclass says:
ActionMessages messages = new ActionMessages();
errors.a
Hi All,
I am coming up against a limitation of using DynaActionForm that I wonder if someone
can confirm or deny.
All our Action classes extend a SecuredBaseAction. This SecuredBaseAction does a few
important things per request like making sure the user is validated and also loading
page prop
If i use this:
i get no message in my jsp file.
Once Again my Actionclass says:
ActionMessages messages = new ActionMessages();
errors.add(ActionErrors.GLOBAL_ERROR, new
ActionError("error.mitarbeiter.anlegen"));
saveErro
U can use
First method:
Or, you can place specific messages at different locations
Jitender K Chukkavenkata schrieb:
use tag or tag for accessing messages in the
same way as you use tag.
Jitender Kumar C.V.
Hi!
Can you give me an example how i use in this case?
-
To unsubscribe, e-mail: [EMAIL PROTECTED
I would try this:
<%= actionMessages.getMessage(...) %>
I dont know if it works, since I have no way now to test it...
You have to find somewhere value of GLOBAL_ERROR and then it is easy, i
think.
-- Honza
Manuel Wissmann wrote:
> Hi Everbody!
>
> I've got the following problem:
>
> In my
use tag or tag for accessing messages in the
same way as you use tag.
Jitender Kumar C.V.
Hi Everbody!
I've got the following problem:
In my MitarbeiterAction.java I've got the following Code:
...
public ActionForward execute(ActionMapping mapping,
ActionForm form, HttpServletRequest req,
HttpServletResponse res) throws Exception
{
ActionMessages m
The code snippet below uses JDOM but should easily be adaptable to
anything else. Hope it helps. On the server side read the data from the
request's inputStream. If however you want to use multipart messages
things get slightly more tricky.
URLConnection conn = ...
// configure t
I've found it out! So simply and It wasnot clear to me!
I'm sorry for this question, since it is so easy:
When You specify additional resources, such
so You can sipmly access whole MessageResources class by for example in JSP:
So the key to access the whole class equals (is the same) as the b
In the action class, just call request.getInputStream().
On Fri, 17 Sep 2004 08:57:56 +, Mark Benussi
<[EMAIL PROTECTED]> wrote:
> Has anyone got an example of posting an XML message via the web to a sruts
> action on an external site and how I should handle that request in the
> struts acti
you can do this in several ways but you always need to reload the JSP
page and use a bit of javascript.
If you fill your combobox in the JSP, then simply reload the page with
an additional request parameter containing the selected option. In your
JSP code you must check the presence of this par
Has anyone got an example of posting an XML message via the web to a sruts
action on an external site and how I should handle that request in the
struts action?
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional command
Sachin Bhutada wrote:
> hi Honza Spurný ,
>
> Try this out ..
>
> RequestUtils.message(pageContext,"countries","locale",
> "country.usa.label", null);
> It will return u the appropriate string. It may work.
Hi there,
thanks for hint. This should work, there's no problem probably in it. Only
think
hi vineesh ,
go to java.sun.com and search for tutorial they hv wonderfully designed
tutorials for the beginners .
sachin
xoriant, mumbai
-Original Message-
From: vineesh . kumar [mailto:[EMAIL PROTECTED]
Sent: Friday, September 17, 2004 1:19 PM
To: Struts Users Mailing List
Subject: Re
1 - 100 of 107 matches
Mail list logo