I've discovered quite by accident that the Struts templating framework
allows me to eliminate duplication of my JSP pages by simply including the
body page inline to the template definition page. By this I mean I combine
both pages into one as follows:
template:insert ...
template:put
Alan!
I'm up and running on 3.5.3. I used the xerxes.jar, before importing it to
the workspace I had to remove the omg classes from the IBM XML Parser
project.
Regards
/Erik
From: [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Subject: Re: IBM
Hi All,
I am trying to define a redirecting forward in the struts-config.xml. But I
need some parameters that are on the form to redirect the action. Is there a
way to add parameters to the redirecting request?
An example:
action path=/postTopic
I'm having problems running a sample application that a basic JSP with
struts tags that causes a POST to the actionservlet, using an ActionForm
subclass and an Action subclass. What I'm getting is a NoClassDefFoundError
saying basically that it can't find org.apache.Struts.action.ActionForm
Ted, your response caught my attention. I haven't noticed problems, but
I also haven't got down to serious debugging so maybe I just haven't
noticed it yet... Anyway, are you supposed to call setServlet() whey you
instantiate a Form yourself and put it on the session (say from within
some
I last worked with Weblogic at v5.2 so bear that in mind with my comments.
WL has 2 classpaths... one for itself, the application server, and one for
the applications it runs. My guess is that you DO need to include struts.jar
in the classpath for WL since the servlet is installed before WL
You can create new ActionForwards within the Action, and paste on your
parameters.
Personally, I would put another Action in front of viewForum.jsp, so
that it expects whatever dyndamic data it needs to be passed in a bean
through the request, rather taken from a dynamic (and possibily
This was intended to work this way and, like you, did not see it as a
possibility in the documentation. Not satisfied with putting things into
separate files I searched the e-mail list for template:put and saw an
example someone had posted using it in-line and have used that method ever
since.
I still have not got any answers for the problem described below.
Is there some problems with struts custom img-tag?
Why it is generating tags like this?
img src=/images/blue.gif;jsessionid=0001CEAAQCTISJFXCZWNZLC2WNA
Where does this ';' came from and why there it is not '?' instead?
Do I
Hi
I am trying to use Validator in my application and can not get it to work. I
have a single test form that I would like to use the Validator for
client-side and server-side validation. If I add the following
%@ taglib uri=/WEB-INF/struts-validator.tld prefix=validator %
reference to the
No... should I be? Ted could you enlighten us a bit on how to do this? :) Am I
missing some thing? My code to do this consists of a few lines to do this. I figure
the problem is probably something pretty small.
Ex.
ActionForm frm = new ActionForm();
frm.setSomething(Something);
Use the source, Luke, use the source.
Cameron Ingram wrote:
No... should I be? Ted could you enlighten us a bit on how to do this? :) Am I
missing some thing? My code to do this consists of a few lines to do this. I figure
the problem is probably something pretty small.
Ex.
I am trying to design an application using the Struts framework, however, I have come
across some contradicting information in the
documentation and was wondering what is the right way of implementing my design.
Suppose I have a Action object that calls a JavaBean to perform some business logic
Hi All,
I have a button, which is an image. I want to be able to submit my form
when the image is clicked. How can achieve this by using the image I
already have. I have some text which is displayed on the button but is not
part of the image itself. I know how to do this using the html
Hi everybody!
This is to announce I'have released an article about Struts configuration
(specifically struts-config.xml) titled: The Struts Framework's Action
Mappings Configuration File on InformIT!
http://www.informit.com/content/index.asp?session_id={5820D5CC-C434-47A5-8E16
Hi all,
I am running into some trouble mapping between form beans and entity
beans.
Looking through the mailarchives I found out that the best way to use
ejbs with stuts is to load and unload ejbs in the struts actions. So
that's exactly what I did.
However when trying to map the contents of the
Hi Murlidhar,
We have and are building new projects using struts for a large American
insurance company (internal app) and for a major Canadian bank (external
app).
Cheers,
Bryan
--
Bryan Mallinson
Software Developer
Toronto Global Development Centre
Infosys Technologies Ltd.
Tel: (416)
search the archives for more postings, but I have
heard different approaches when I posted the same
problem.
1. Check to see that you are using the latest Struts
nightly build.
2. If not using hte latest nightly build, this may
work if you use Tomcat 4.0
3. Remove Jaxp, crimson and parser.jar
I believe there is a limitation to the size of the
file that can be used like this.
I don't know about performance.
There are other benefits of using tiles -- at least
for me these include dynamically creating the ui in
the controller for hierarchical input forms (forms
that are similar but
Tiles allows you to do this as well.
btw: I have replied to another reply in this same
thread about other things I like about tiles. In my
usual haste I deleted the original message when I
realized there was something more I wanted to say.
- sandeep
--- Darryl Pentz [EMAIL PROTECTED] wrote:
man i suck, i did it again.
finish the thought, than send the mail.
ok -- what I meant was that unlike what your initial
e-implies: that tiles works exactly like
template-tags, what I meant was that you can create
the duplicate definition in the xml file and than
reference this layout
Sandeep,
Can you post an example of a struts-config mapping using Tiles. I tried to
use Tiles but couldn't get it to run a page twice. In other words, I had a
search function which worked fine the first time with Tiles, but when I
changed the search criteria and resubmitted, the Action class
When I tested it (a very simple test) I used the
following in the struts-config.xml file:
action path=/test/sandeepTestAction
type=org.apache.struts.example.tiles.test.SandeepTestAction
forward name=success path=doc.mainLayout/
/action
Here was the tiles definition for the path attribute
http://community.borland.com/article/0,1410,27646,00.html
At 12:15 PM 10/08/2023 -0400, you wrote:
Help, I can't get struts to work with Jbuilder.
I have downloaded the Struts 1.0 archive. I have created a library called Struts
which points to the Struts and JDBC. jar files. I have unzipped
Is struts framework used in any of the financial firms ?
Been there done that.
--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]
No you do not need struts.jar in the classpath for WLS 5.1, 6.0 or 6.1.
Struts.jar should only be in the WEB-INF/lib directory of your web app.
-Original Message-
From: Darryl Pentz [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 01, 2001 5:51 AM
To: Struts Users Mailing List
If you have struts.jar in your WEB-INF/lib dir you should be ok. It should
definitely not be in your system classpath.
It sounds like you have it set up ok. Can you send me your
startWeblogic.cmd and the war file you are testing?
Brett
-Original Message-
From: Jeff Mikres
Cool. That's interesting. And you mentioned something about being able to
manipulate placement of tiles from within the Action class. How is that
done?
- Darryl
-Original Message-
From: Sandeep Takhar [mailto:[EMAIL PROTECTED]]
Sent: 01 November 2001 18:23
To: Struts Users Mailing
Here you need to understand the api of tiles. It is
quite powerful.
I wrote something about this for internal use. I will
paste it here:
// Read definition from factory, but we can create it
here.
ComponentDefinition definition =
I'm sure I'm missing something obvious, but after a day of trying to solve
this, I'm quite tired of beating my head against the wall. For some reason
it seems that ActionServlet isn't able to load the message resources for my
application. I have the following lines in my web.xml file:
It's looking for ApplicationResources.properties in your WEB-INF/classes
directory
-Original Message-
From: Justin Piper [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 01, 2001 10:43 AM
To: Struts Users Mailing List
Subject: Message resources
I'm sure I'm missing something
...try adding a property value to your html:errors property=whatever
-Original Message-
From: Justin Piper [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 01, 2001 10:43 AM
To: Struts Users Mailing List
Subject: Message resources
I'm sure I'm missing something obvious, but
It is not in the 1.0 release. It is available in the nightly builds, which will
eventually become 1.1.
Cheers,
Dave
Curt Peterson [EMAIL PROTECTED] on 10/31/2001
03:25:12 AM
Please respond to Struts Users Mailing List
[EMAIL PROTECTED]
To: [EMAIL PROTECTED]
cc:(bcc: David
Sorry, I should have included that. I'm using Tomcat 4.0. I have
log4j.jar, poolman.jar, and struts.jar in my application's /WEB-INF/lib, and
jasper-runtime.jar and naming-factory.jar in $TOMCAT_HOME/lib.
-Original Message-
From: Drozdowski, Terry [mailto:[EMAIL PROTECTED]]
Sent:
Hi All,
I'm populating a FormBean from action class so that I can open the
form(jsp)in edit mode with all values for updating purpose but the
problem is, I'm having checkbox or radio button, It's not showing me
selected radio or checked chech box if it is checked or selected before.
Can
I tried adding
errors.header=font color=red
errors.footer=/font
to ApplicationResources.properties, and
html:errors property=error.login.password.required/
html:errors property=password/
to login.jsp. I wasn't sure whether the property attribute referred to a
key in the message
Scott,
In your Action object, get your DataSource using the call to
servlet.getServletContext()..., and then pass the DataSource to your
JavaBean object where you allocate your connection. This way you avoid
tying your JavaBean to the web application, and also remove the business
logic from
Cp1252 is not a valid XML encoding by W3C standards. This is an
(undesirable) extension provided by some Microsoft XML tools.
Try using ISO-8859-1, it will probably be enough to handle most
european languages.
*Saran
Gerry Chike wrote:
The property element in html:errors refers to the error you return from a
form's validate method (you can also do this from an Action class, but you
have to add something extra)
the action mapping section of struts-config.xml file:
.
action-mappings
action path=/login
If we had a form bean with more than 16 fields, after submit, action ran and
IE 5.5 croaked with 404 error when doing a forward success to another
*.do. NS 6.1 did not have the same problem.
Error from IE 5.5:
The page cannot be displayed
The page you are looking for is currently unavailable.
lo,
I'm a new Struts user (not new on MVC tho). Before starting my own
Struts-based webapp, I thought it would be wise to study some tutorials
first. One of these is
http://www.jspinsider.com/tutorials/jsp/struts/strutsintro.view . It is
the common logon.jsp/homepage.jsp example.
However,
Interesting question, because this is what Struts is
strong at.
If you really need to add the code, than custom tags
are a better way to go
Here is one way I have seen it done using Struts (note
the forward is to a pre-defined alias of a jsp page so
the path of the jsp is hidden):
%@ page
Marc,
I think your discomfort is well placed, this clearly mixes the C V at
the very least ;-). Check out the samples distributed with Struts, they
show how to do this using custom taglibs, which is a cleaner way to do
it, IMHO.
regards,
Stephen Owens
Corner Software
-Original
Sandeep Takhar wrote:
If you really need to add the code, than custom tags
are a better way to go
Here is one way I have seen it done using Struts (note
the forward is to a pre-defined alias of a jsp page so
the path of the jsp is hidden):
%@ page language=java %
%@ taglib
Why do you need the index for checkbox?? if it is to create a dynamic
checkbox in an iterate, use
multibox...
-Original Message-
From: Curt Peterson [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 31, 2001 3:25 AM
To: [EMAIL PROTECTED]
Subject: indexed checkboxes
Somewhere in the
Hi Lisa,
I used JavaScript to submit the form. Here is what I have in my page:
a href=javascript:document.yourFormName.submit()
img src=/jsp/images/buttons/continue.gif width=55
height=14 border=0
/a
HTH,
Long B. Nguyen
-Original Message-
Thanks for your help. I've (finally) tracked down the source of my problem,
and, as I originally predicted, I'd missed something very obvious. Instead
of naming my file ApplicationResources.properties as I should have, I had
named it ApplicationResources.Properties. Now the question is whether
We looked at the browser src and it did use the Post.
html:form action=/jsp/group_mtrx_headers
We also noticed that if we clicked on Refresh on the 404 page, the real
page would appear correctly. We also have this situation when just doing a
forward to a *.do.
Thinh
-Original
Struts does this with it's logic custom tag libraries.
May have to change the data representation in order
to use the logic tags though.
check out the docs:
http://jakarta.apache.org/struts/struts-logic.html
- Sandeep
--- Marc L. de Bruin [EMAIL PROTECTED] wrote:
Sandeep Takhar wrote:
If
Under Tools Menu in the IE, go to the Internet Options and
Uncheck the Show Friendly Http Error Messages in the advanced tab under the
Browsing section.
This step will show the exact error messages.
Rao
-Original Message-
From: Thinh Doan [mailto:[EMAIL PROTECTED]]
Sent: Thursday,
Hello,
I have a question with regards to the html tag library. We would like to
have the ability to set the size, format and other attributes for the html
tags dynamically. The attributes would be set in the action form by the
action class as it queries the database and would use the meta data
I was wondering how to digest content that contains additional
elements.
For example, I have two tags text and date. I want to parse
the following:
textI want to remember this date, date/, forever!/text
Ultimately I want to end up with three objects as follows
(I hope you get what I am
Hi,
What's the recommended approach in struts for implementing a go back to
previous page button, in the situation when you may have arrived at that
page from more than one path???
Eg. View may be a Show Items page, which you can get to say -:
(a) from the main page - in which all items are
This is all off the top of my head, not sure if you had already thought of
this. But, I'd imagine that you could use an Action class that chose the
appropriate forward base on an object in the HttpRequest/Session. This
object could be built by the action that brought you the page you're already
I noticed that the struts html form tag supports most of the attributes
of a normal form tag, but not everything. Is that by design, an oversight,
or am I missing something? I needed to use the onkeypress attribute
but it is not supported. I ended up registering an event handler on the
Is it possible to capture the html page that is generated by a jsp page
before it is sent to the client who requested it?
Brandon Goodin
Phase Communications
P (406)862-2245
F (406)862-0354
http://www.phase.ws
--
To unsubscribe, e-mail: mailto:[EMAIL PROTECTED]
For additional commands,
I use log4j for debugging purposes. My PO number and
other po header info do contain edited values, except
for the po details (a vector of param) which turned
out null even though there are values retrieved from
the database. I've been debugging this for about 2
days. I'm currently using
You might want to take a look at WebDebug:
http://www.cyberclip.com/webdebug/
--
Martin Cooper
- Original Message -
From: Brandon Goodin [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Thursday, November 01, 2001 6:34 PM
Subject: Capturing an outgoing
I just can't seem to get the html:errors tag to display the errors passed
through via my ActionForm object's validate() method. I have confirmed that
the validate() method is working correctly -- as I'm getting a forward to
the input page as configured. Simply nothing appears with:
body
I need it to capture the returning html/page on the server side. For
example, a client makes a request to a jsp page on my website and an an html
page is returned. Is there a way to capture the html being returned to a
file on the server side before it is sent to the client or as it is heading
HI all
I've encountered a situation as follows
1. I have a 'UserInfoContainer' form bean which contains a Vector of individual
'UserInfo' objects.
2. Each UserInfo object is iterated through using the 'iterate' tag in the JSP.
3. Some 'UserInfo' data (say 'NickName' ) is displayed in a text
There are probably numerous ways this can be done. If you just want to
easily capture the output from a single page, you could simply make that
page an included page and use the bean:include tag to capture it's
output. i.e. make the requested page include the real page via the
bean:include tag.
62 matches
Mail list logo