Stuts-simple doesn't work (husted.com)

2001-11-15 Thread tw . richter

Hi out there!

I want to run the struts-simple example for wizards found in husted.com. But it 
doesn't work. It did not find /do/... There is no struts-config in /web-inf/, only a 
struts.xml in /web-inf/conf/. Is this example for another struts version?

Regards
Thomas

:-) As sceptical as one can be! (-:



--
Get a free, personalised email address at http://another.com
TXT ALRT! Stop wasting money now. Send FREE, personalised txt
from http://another.com


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


RE: Reading Session Size.

2001-11-15 Thread Alexander Jesse

Hi,

looking for something similar ourselves...because we were already burned badly
by big session-objects (crashing JVM's...).

Let us know when you find something.

thanks 
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 7:10 PM
To: [EMAIL PROTECTED]
Subject: Reading Session Size.




I know this is not specifically about struts but,

There is much talk about keeping your session size small.

For debug purposes I would like to know..

Is there any way to be able to capture the memory size of an  httpsession (or
rather the objects I have put into the session) ?

Through my research I think I have a couple of idea's but would welcome any
advice from anyone with insight into this..

Thanks
Jeff Mychasiw



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: request scope and forms

2001-11-15 Thread Alexander Jesse

nothin to do with bean-magic just pure http.

work-arounds:
- session
  - either the form-bean or the vector
- Renauds serialized form-bean

regards
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 6:57 PM
To: [EMAIL PROTECTED]
Subject: Re: request scope and forms


so much for magic beans...

Thanks all for your replies!

Rob



|+--
||  Andy Noble|
||  andy.noble@data-wor|
||  kshop.com  |
||  |
||  14/11/2001 17:35|
||  Please respond to   |
||  Struts Users   |
||  Mailing List   |
||  |
|+--
  
---|
  |
   |
  |  To: Struts Users Mailing List [EMAIL PROTECTED]  
   |
  |  cc:   
   |
  |  Subject: Re: request scope and forms  
   |
  |
   |
  |
   |
  
---|




I had this very problem. You want the best of both worlds like I did - the
formbean somehow lives between two requests but doesn't clog up memory like
a session bean could. I chose the request only option in the end. All the
data in the bean gets sent to the client, and a new formbean is created and
populated when that form is reposted by the user. In effect, the lifetime
of
the data is held with the client, rather than the server. The processing
cost in terms of creating new formbeans and repopulating them with HTML
data
is negligible compared with the potential for session beans to clog up the
system holding data that may never be reused.

Andy

- Original Message -
From: Rob Breeds [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday, November 14, 2001 5:12 PM
Subject: RE: request scope and forms


 Robert

 OK, so even if I forward to a JSP with a form bean in the request, and
the
 JSP displays data from that form bean, as soon as I submit the form
again,
 the original form bean is lost. Hmmm, I was hoping I could somehow keep
the
 forward chain going and Struts would magically keep my ActionForm alive.

 Thanks

 Rob





 Robert
 Nocera  To: 'Struts Users Mailing
List' [EMAIL PROTECTED]
 rnocera@neosl   cc:
 lc.com  Subject: RE: request scope
and forms

 14/11/2001
 16:19
 Please respond
 to Struts
 Users Mailing
 List






 If I understood your question correction, you probably want to use a
 session scope bean.  In your case when the JSP is submitted each time a
 new form bean is created because at that point it is a new request, not
 a forward.

 Robert Nocera
 New England Open Solutions
 www.neosllc.com
 You supply the vision, we'll do the rest.


 -Original Message-
 From: Rob Breeds [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, November 14, 2001 11:03 AM
 To: Struts Users Mailing List
 Subject: request scope and forms


 I'm getting stuck with request scope and ActionForm objects not sticking
 around across requests.

 If I have a jsp that has an input text field called name that populates
 a
 corresponding field in an ActionForm called name, then that field gets
 populated.

 If the Action associated with this ActionForm then takes that name value
 and adds it a different property in the ActionForm (say to a Vector) and
 then forwards to the SAME input jsp again, why is it that a new
 ActionForm
 object is instantiated every time (according to the log), such that
 theActionForm never gets more than one String added to the Vector?

 I was under the impression that if I forwarded, any ActionForm passed to
 the Action would be persisted in the request.

 Thanks

 Rob Breeds



 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]


 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]





 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For 

RE: properties file in action class

2001-11-15 Thread Alexander Jesse

In your first mail you write that you want to do it in ActionServlet...
then you must extend it...

In your action-class you could define a static property object, which
you lazy-initialize. When you need it, check for a null-value. If null:
read the property-file and populate the propety-object; if not null:
just use it.

hope this helps
Alexander

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 9:47 PM
To: [EMAIL PROTECTED]
Subject: RE: properties file in action class


but if I do not want to subclass ActionServlet

-Original Message-
From: Sobkowski, Andrej [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 3:19 PM
To: 'Struts Users Mailing List'
Subject: RE: properties file in action class


Hello,

I guess you could subclass ActionServlet and overwrite an existing initABC()
method:

public class MyActionServlet extends ActionServlet {
  ...
  protected void initOther throws ServletException {
super.initOther(); // don't forget this one.. :)
myInit();
  }

  protected void myInit() {
// Add here your servlet's init code and make it available 
// to your actions.
  }
}

Just an idea...

Andrej

PS. You'll also have to change the struts-config.xml to point to your
MyActionServlet.

-Original Message-
From: Dua, Amit [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 3:11 PM
To: 'Struts Users Mailing List'
Subject: properties file in action class



Hi
 if  I have to load a properties file in my action class.
I can do it in perform method.
But  I want to do it in init of Action Servlet , so that it does not get
loaded every time a call is made to the action class.How can I do this.

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Trying to understand the Action and Form paradigm

2001-11-15 Thread Marcel Andres

Hi Nicolas,

The perform is called when you invoke the .do. If you invoke the .jsp the action 
is not called. As much as I know, if you expect the value of password2 to be set when 
you forward to the register page, you should forward to the .do instead of the 
.jsp.

Hope this helps,

Marcel 



-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 5:16 AM
To: [EMAIL PROTECTED]
Subject: Trying to understand the Action and Form paradigm


Hi,

From the title of this email you probably can understand that I am a
newcomer to struts. I am very excited to try this out and use it in my
own projects.

However there is something that I don't quite understand after trying a
lot of the sample applications and reading the docs.

Currently I am trying to develop a login application as an exercise, and

I am getting this problem:

/register.jsp(60,46) Attribute password2 has no value

I have defined 2 pages for now. One page that is called login.jsp and is

associated with a LoginForm and LoginAction class, and a register.jsp
page that is associated with a RegisterAction and RegisterForm classes.

The login.jsp page has a form and a submit button to allow people to
login, and a link to the register.jsp page. This link looks like this:
html:link forward=registerRegister here/html:link

In my struts-config.xml file I have register defined as a
global-forward like this:
forward
 name=register
 path=/register.jsp/

And my actions in the struts-config.xml look like this:

action
  path=/login
  type=org.esterlingen.ui.actions.LoginAction
  name=loginForm
  scope=request
  validate=true
  input=/login.jsp
  forward
 name=continue
 path=/login.jsp/
/action
action
  path=/register
  type=org.esterlingen.ui.actions.RegisterAction
  name=registerForm
  scope=request
  validate=true
  input=/register.jsp
  forward
 name=continue
 path=/index.jsp/
/action

I checked and double checked, the attribute password2 is defined in my
RegisterForm class, as well as
in the register.jsp file.

What am I doing wrong? Is there something that I misunderstand in the
documentation?
When exactly are the perform methods from the Action classes called?
When I first load the .jsp file
associated to it, or when I submit the form that is on the jsp page?

Thanks for your help
Nicolas




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: problem with bean:write in an include

2001-11-15 Thread Marcel Andres

Hi Ken, 

are you sure, the value is set in the form? I think, this could be the same problem, 
which has been asked by Nicolas. See subject Trying to understand the Action and Form 
paradigm.

Marcel 

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 12:28 AM
To: [EMAIL PROTECTED]
Subject: problem with bean:write in an include


I'm using includes that have bean:write tags and custom link tags.  When
my page displays, I can see the custom link tags with no problem.  However,
the values for the bean:write aren't being displayed and I get a jasper
compiler error (I'm using iPlanet 6.0 SP3) like this:

2001-11-14 05:18:35 - error-the file '\jsp\retireResultFull.jsp' generated
the following parse exception: org.apache.jasper.compiler.ParseException:
D:\iplanet\ias6\ias\APPS\prototype\prototype\jsp\calc.jsp(17,138) Attribute
has no value

The text in the included jsp (calc.jsp) show up, just not the bean:write
values

Anyone else having similar problems?

Ken Fletcher
Teacher Retirement System of Texas

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Iterate tag

2001-11-15 Thread Daniel WAMARA

I need to use the iterate tag to display elements of 2 arrays but the 
problem is that I don't know if I can really use a nested iteration 
considering the fact that normally, in Java, it should for example be 
handled like this

for (int i=0; i=list.length-1, i++)
{
  System.out.println(a[i]);
  System.out.println(b[i]);
}

because the value of a[i] and b[i] should be displayed in table cells like

tr
  td(the value if A)/td
  td(the value if B)/td
/tr

od should I simply use a scriptlet for that.

Thanks for help.

Daniel WAMARA

_
Téléchargez MSN Explorer gratuitement à l'adresse 
http://explorer.msn.fr/intl.asp


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Error when forwarding from action to action

2001-11-15 Thread Anat Rozenzon

hi all,
 
I'm trying to forward from one action to another and get forward exception.
I have a LoginAction which checks all the login data and if it's ok it
should forward the request to HomeAction which prepare data for personal
home page.
 
I see in the logs that the LoginAction is processed succesfully until the
last line which is:
 
return (mapping.findForward(success));
 
It fails to go to the HomeAction. 
Here is the LoginAction code and struts-config.
 
 
=== LoginAction.java ===
 
package sis.web.action;
 
import java.io.IOException;
import java.util.Hashtable;
import java.util.Locale;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import javax.servlet.http.HttpServletResponse;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionServlet;
import org.apache.struts.util.MessageResources;
import org.apache.log4j.Category;
 
import sis.web.util.WebUtils;
import sis.web.util.WebKeys;
import sis.client.UserHandler;
import sis.core.SisFinderException;
 

 
public final class LoginAction extends Action {
 

static Category log = Category.getInstance(LoginAction.class);
// - Public
Methods
 
public ActionForward perform(ActionMapping mapping,
 ActionForm form,
 HttpServletRequest request,
 HttpServletResponse response)
 throws IOException, ServletException {
 
log.debug(starting);
 
 // Extract attributes we will need
 Locale locale = getLocale(request);
 MessageResources messages = getResources();
 HttpSession session = request.getSession();
 
// check for transaction token (if not exist this is first time, don't show
error
saveToken(request);


 // Validate the request parameters specified by the user
 ActionErrors errors = new ActionErrors();
 String username = ((LoginForm) form).getUsername();
 String formPassword = ((LoginForm) form).getPassword();
 
if (username == null) {
// check transaction condition
if (this.isTokenValid(request))
errors.add(user, new
ActionError(error.username.required));
else // first time, just go to jsp
return (new ActionForward(mapping.getInput()));
}
else {
// get signon handler
UserHandler userHandler = WebUtils.getUserHandler(session);

String password = null;
try {
password = userHandler.getPassword(username);
} catch (SisFinderException sfe) {
errors.add(user, new
ActionError(error.user.notfound,username));
}

if (password == null) {
errors.add(password, new
ActionError(error.password.required));
}
else if (!password.equals(formPassword))
errors.add(password, new
ActionError(error.password.mismatch));
}

 // Report any errors we have discovered back to the original form
 if (!errors.empty()) {
 saveErrors(request, errors);
 return (new ActionForward(mapping.getInput()));
 }
 
 // Save our logged-in user in the session
 session.setAttribute(WebKeys.USER_KEY, username);
 session.setAttribute(WebKeys.PASSWORD_KEY, formPassword);
log.info(User ' + username + ' logged on in session  +
session.getId());
 
// Remove the obsolete form bean
WebUtils.removeFormAttribute(mapping, request);
 
log.debug(Done removeFormAttribute);
 
// reset transaction token
resetToken(request);

log.debug(Done resetToken);

// Forward control to the specified success URI
 return (mapping.findForward(success));
 
}
}
 
=== struts-config.xml ===
?xml version=1.0 encoding=ISO-8859-1 ?
 
!DOCTYPE struts-config PUBLIC
  -//Apache Software Foundation//DTD Struts Configuration 1.0//EN
   http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd;
http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd 
 
struts-config
 
  !-- == Form Bean Definitions ===
--
  form-beans
!-- Logon form bean --
form-bean  name=loginForm
type=sis.web.action.LoginForm/
 
!-- Registration form bean --
form-bean  name=registrationForm
type=sis.web.action.RegistrationForm/
 
!-- Subscription form bean --
form-bean  name=subscriptionForm
type=sis.web.action.SubscriptionForm/
!--
   form-bean name=ProductForm
type=org.cayambe.web.action.ProductActionForm/
form-bean name=CategoryForm

Re: Trying to understand the Action and Form paradigm

2001-11-15 Thread Nicolas Sallembien

Hi Marcel,

I don't want anything to be set. My RegisterForm and RegisterAction are expected to be 
called
whenever I  submit on the register.jsp page. I just want to go to register.jsp when I 
hit the link from
login.jsp.

Thanks
Nicolas

Marcel Andres wrote:

 Hi Nicolas,

 The perform is called when you invoke the .do. If you invoke the .jsp the action 
is not called. As much as I know, if you expect the value of password2 to be set when 
you forward to the register page, you should forward to the .do instead of the 
.jsp.

 Hope this helps,

 Marcel

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 5:16 AM
 To: [EMAIL PROTECTED]
 Subject: Trying to understand the Action and Form paradigm

 Hi,

 From the title of this email you probably can understand that I am a
 newcomer to struts. I am very excited to try this out and use it in my
 own projects.

 However there is something that I don't quite understand after trying a
 lot of the sample applications and reading the docs.

 Currently I am trying to develop a login application as an exercise, and

 I am getting this problem:

 /register.jsp(60,46) Attribute password2 has no value

 I have defined 2 pages for now. One page that is called login.jsp and is

 associated with a LoginForm and LoginAction class, and a register.jsp
 page that is associated with a RegisterAction and RegisterForm classes.

 The login.jsp page has a form and a submit button to allow people to
 login, and a link to the register.jsp page. This link looks like this:
 html:link forward=registerRegister here/html:link

 In my struts-config.xml file I have register defined as a
 global-forward like this:
 forward
  name=register
  path=/register.jsp/

 And my actions in the struts-config.xml look like this:

 action
   path=/login
   type=org.esterlingen.ui.actions.LoginAction
   name=loginForm
   scope=request
   validate=true
   input=/login.jsp
   forward
  name=continue
  path=/login.jsp/
 /action
 action
   path=/register
   type=org.esterlingen.ui.actions.RegisterAction
   name=registerForm
   scope=request
   validate=true
   input=/register.jsp
   forward
  name=continue
  path=/index.jsp/
 /action

 I checked and double checked, the attribute password2 is defined in my
 RegisterForm class, as well as
 in the register.jsp file.

 What am I doing wrong? Is there something that I misunderstand in the
 documentation?
 When exactly are the perform methods from the Action classes called?
 When I first load the .jsp file
 associated to it, or when I submit the form that is on the jsp page?

 Thanks for your help
 Nicolas

 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: How to reuse HTML code?

2001-11-15 Thread Cedric Dumoulin


  Have you take a look at the Tiles framework ?
  It is design to do such things : it allows to call a component, passing it
some parameters (like a method). Component can then deal with parameters.
Parameters are only visible inside the component (like method parameters), so
you don't have to worry about parameter names if you include several components
in the same page.
  See after for a version using Tiles.

Cedric


// --- Calling page ---
%@ taglib uri=/beantaglib prefix=bean %
td class=formsinput colspan=3
  tiles:insert page=/util/datefieldwithcalendar.jsp
tiles:put name=dateField value=registrationDate /
  /tiles:insert
/td

// --- datefieldwithcalendar.jsp ---
%@ page language=java contentType=text/html %
%@ taglib uri=/htmltaglib prefix=html %
%@ taglib uri=/beantaglib prefix=bean %
%@ taglib uri=/WEB-INF/tiles.tld prefix=tiles %
tiles:useAttribute name=dateField /

script language=JavaScript src=/javascript/AnchorPosition.js/script
script language=JavaScript src=/javascript/PopupWindow.js/script
script language=JavaScript src=/javascript/CalendarPopup.js/script
script language=JavaScript
  var cal%= dateField % = new CalendarPopup();
  cal%= dateField %.setReturnFunction(%= dateField %showDate);
  cal%= dateField %.offsetX = 2;
  function %=dateField %showDate(y,m,d) {
document.forms[0].%= dateField %.value = y + - + m + - + d;
  }
/script

html:text property=%= dateField % size=10 maxlength=10 /
a href=# onClick=cal%= dateField %.showCalendar('%=
dateField%anchor'); return false; name=%= dateField%anchor id=%=
dateField%anchor
  img src=images/cct_cal.gif border=0
/a


Sobkowski, Andrej wrote:

 Hello,

 This may be OT but... I'm trying to find the best way to define reusable
 HTML components in Struts since we have a lot of pages with quite a few
 common pieces. For example, I'd like to reuse:
 - a date field with a popup Javascript calendar
 - a set of phone fields (regional code, number, extension, type) with
 dynamic addition/removal of phones.

 I initially thought about creating JSP tags for the above, but after some
 good-and-serious advice from the Struts lists (thanks guys :) !!) I
 considered using pure JSP files with Struts tags and simple JSP include:
 they can be changed way quicker and you can see the file you're working
 on. Now, I need to pass parameters to the included JSP page and the best
 way I've found is via bean:define.

 For the calendar, this would give something like the following:
 - the calling page defines via bean:define the various parameters needed
 by the JSP module (in the example below, the ActionForm property for
 registrationDate)
 - the JSP module uses the parameters passed to generate the specific HTML
 code via various %= parameterName %

 Does this make sense? Do you see any major problems in this approach? If
 that's the case, what's the proper solution?

 Thanks!

 Andrej



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re[2]: Trying to understand the Action and Form paradigm

2001-11-15 Thread Maciej Koodziej

Witam,

W Twoim mail'u z dnia 15 listopada 2001 mona przeczyta:

 I am getting this problem:

 /register.jsp(60,46) Attribute password2 has no value

I think this  is  a  parse  error  in line 60 column 46. In my application's
login.jsp definition of password field looks like that:

html:password property="pass" size="19" maxlength="19"
redisplay="false"/

Andof   course  it  needs  getPass()  and  setPass()  methods  in
LoginForm.java. You didn't include Your jsp, so I can't tell You more.

-- 
Pozdrawiam,
 Maciej Koodziej   
 mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Newsgroup

2001-11-15 Thread Vic Cekvenich

There is now another mirror of the Struts mail list at 
news.basebeans.com as a newsgroup forum.
It does not replicate post back to mail list yet ( it will in a week).

More good stuff comming 

HTH,
Vic



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: request scope and forms

2001-11-15 Thread twrichter

Hi Andy,

how exactly did you do that?

Many thanks in advance
twr

-Original Message-
From : Andy Noble [EMAIL PROTECTED]
To : Struts Users Mailing List [EMAIL PROTECTED]
Date : 14 November 2001 17:35:49
Subject : Re: request scope and forms
I had this very problem. You want the best of both worlds like I did - theformbean 
somehow lives between two requests but doesn't clog up memory like
a session bean could. I chose the request only option in the end. All the
data in the bean gets sent to the client, and a new formbean is created and
populated when that form is reposted by the user. In effect, the lifetime of
the data is held with the client, rather than the server. The processing
cost in terms of creating new formbeans and repopulating them with HTML data
is negligible compared with the potential for session beans to clog up the
system holding data that may never be reused.

Andy

- Original Message -
From: Rob Breeds [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday, November 14, 2001 5:12 PM
Subject: RE: request scope and forms


 Robert

 OK, so even if I forward to a JSP with a form bean in the request, and the
 JSP displays data from that form bean, as soon as I submit the form again,
 the original form bean is lost. Hmmm, I was hoping I could somehow keep
the
 forward chain going and Struts would magically keep my ActionForm alive.

 Thanks

 Rob





 “Robert
 Nocera“  To: “'Struts Users Mailing
List'“ [EMAIL PROTECTED]
 rnocera@neosl   cc:
 lc.com  Subject: RE: request scope
and forms

 14/11/2001
 16:19
 Please respond
 to “Struts
 Users Mailing
 List“






 If I understood your question correction, you probably want to use a
 session scope bean.  In your case when the JSP is submitted each time a
 new form bean is created because at that point it is a new request, not
 a forward.

 Robert Nocera
 New England Open Solutions
 www.neosllc.com
 “You supply the vision, we'll do the rest.“


 -Original Message-
 From: Rob Breeds [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, November 14, 2001 11:03 AM
 To: Struts Users Mailing List
 Subject: request scope and forms


 I'm getting stuck with request scope and ActionForm objects not sticking
 around across requests.

 If I have a jsp that has an input text field called name that populates
 a
 corresponding field in an ActionForm called name, then that field gets
 populated.

 If the Action associated with this ActionForm then takes that name value
 and adds it a different property in the ActionForm (say to a Vector) and
 then forwards to the SAME input jsp again, why is it that a new
 ActionForm
 object is instantiated every time (according to the log), such that
 theActionForm never gets more than one String added to the Vector?

 I was under the impression that if I forwarded, any ActionForm passed to
 the Action would be persisted in the request.

 Thanks

 Rob Breeds



 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]


 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]





 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



:-) As sceptical as one can be! (-:



--
Get a free, personalised email address at http://another.com
TXT ALRT! Stop wasting money now. Send FREE, personalised txt
from http://another.com


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


Re[3]: Trying to understand the Action and Form paradigm

2001-11-15 Thread Maciej Koodziej

Hi,

MK Witam,

MK W Twoim mail'u z dnia 15 listopada 2001 mona przeczyta:

Hmm Sorry for that. Forgot to change my template :)

-- 
Best regards,
 Maciej


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Stuts-simple doesn't work (husted.com)

2001-11-15 Thread Rob Breeds


Thomas

struts-simple does work! The struts config file does not have to be in the
WEB-INF dir - it's location is specified in web.xml. The struts.xml file is
the config file in this case.

Rob



   
  
tw.richter@scept   
  
ical.co.uk To: [EMAIL PROTECTED]  
  
   cc: 
  
15/11/2001 08:05   Subject: Stuts-simple doesn't work 
(husted.com)   
Please respond 
  
to Struts Users   
  
Mailing List  
  
   
  
   
  




Hi out there!

I want to run the struts-simple example for wizards found in husted.com.
But it doesn't work. It did not find /do/... There is no struts-config in
/web-inf/, only a struts.xml in /web-inf/conf/. Is this example for another
struts version?

Regards
Thomas

:-) As sceptical as one can be! (-:



--
Get a free, personalised email address at http://another.com
TXT ALRT! Stop wasting money now. Send FREE, personalised txt
from http://another.com

--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: request scope and forms

2001-11-15 Thread Andy Noble

Hi twr,

Well, in my original plan (using 'edit record' for example):

1. The user sends a request to edit a record
2. Retrieve data from db, populate ActionForm and store in session
3. Populate HTML form send to user for editing.
4. User edits, makes changes and posts data back
5. Action picks up session scoped ActionForm with original values
6. Compares original with submitted HTML and updates db with differences.

The problem was that session scoped objects last for the a timeout period
(usually 30 mins) after the session has ended unless explicitly removed from
the session which would only happen if the user posted the results back.
Potentially, there could be users flipping around the system (lots of forms)
without actually changing much, and therefore with many users (500+) the
memory could get clogged with session scoped objects that are essentially
useless.

Instead, I decided to:

1. The user sends a request to edit a record
2. Retrieve data from db, populate ActionForm and store in *request*
3. Populate HTML form send to user for editing BUT INCLUDE DATABASE UNIQUE
KEYS (after converting to strings) in hidden form fields.
4. After send to user, the ActionForm goes out of scope and gets cleared up
4. User edits, makes changes, taking as long as he wants and posts data
back, or maybe he doesn't
5. If he decides to post changes, Action creates (or reuses) request scoped
ActionForm and populates with posted values (after conversion from strings
for db keys)
6. Updates db with all values, regardless of whether or not it has changed.
(if it was critical to only post changes, I'd have to post original (hidden)
and 'user changeable' copies of data in HTML and compare when posted back.

Here, rather than storing data in my servers memory, I store it in the
client's HTML form - if they never post it back who cares? The downside I
guess is that there is a little extra processing on the server having to
create a request scoped bean every time (I suspect very tiny as we're only
creating one object here), and a little bit more hassle for the programmer.

Regards
Andy
- Original Message -
From: [EMAIL PROTECTED]
To: struts users mailing list [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 7:55 AM
Subject: Re: request scope and forms


Hi Andy,

how exactly did you do that?

Many thanks in advance
twr




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Trying to understand the Action and Form paradigm

2001-11-15 Thread Marcel Andres

O.k., it is not that you want to pre-set some values. Could you include your jsp. As 
Maciej wrote, it could be a problem on the jsp, too.

Marcel

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 11:07 AM
To: [EMAIL PROTECTED]
Subject: Re: Trying to understand the Action and Form paradigm


Hi Marcel,

I don't want anything to be set. My RegisterForm and RegisterAction are expected to be 
called
whenever I  submit on the register.jsp page. I just want to go to register.jsp when I 
hit the link from
login.jsp.

Thanks
Nicolas

Marcel Andres wrote:

 Hi Nicolas,

 The perform is called when you invoke the .do. If you invoke the .jsp the action 
is not called. As much as I know, if you expect the value of password2 to be set when 
you forward to the register page, you should forward to the .do instead of the 
.jsp.

 Hope this helps,

 Marcel

 -Original Message-
 From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 5:16 AM
 To: [EMAIL PROTECTED]
 Subject: Trying to understand the Action and Form paradigm

 Hi,

 From the title of this email you probably can understand that I am a
 newcomer to struts. I am very excited to try this out and use it in my
 own projects.

 However there is something that I don't quite understand after trying a
 lot of the sample applications and reading the docs.

 Currently I am trying to develop a login application as an exercise, and

 I am getting this problem:

 /register.jsp(60,46) Attribute password2 has no value

 I have defined 2 pages for now. One page that is called login.jsp and is

 associated with a LoginForm and LoginAction class, and a register.jsp
 page that is associated with a RegisterAction and RegisterForm classes.

 The login.jsp page has a form and a submit button to allow people to
 login, and a link to the register.jsp page. This link looks like this:
 html:link forward=registerRegister here/html:link

 In my struts-config.xml file I have register defined as a
 global-forward like this:
 forward
  name=register
  path=/register.jsp/

 And my actions in the struts-config.xml look like this:

 action
   path=/login
   type=org.esterlingen.ui.actions.LoginAction
   name=loginForm
   scope=request
   validate=true
   input=/login.jsp
   forward
  name=continue
  path=/login.jsp/
 /action
 action
   path=/register
   type=org.esterlingen.ui.actions.RegisterAction
   name=registerForm
   scope=request
   validate=true
   input=/register.jsp
   forward
  name=continue
  path=/index.jsp/
 /action

 I checked and double checked, the attribute password2 is defined in my
 RegisterForm class, as well as
 in the register.jsp file.

 What am I doing wrong? Is there something that I misunderstand in the
 documentation?
 When exactly are the perform methods from the Action classes called?
 When I first load the .jsp file
 associated to it, or when I submit the form that is on the jsp page?

 Thanks for your help
 Nicolas

 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]

 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Pool problem

2001-11-15 Thread Inés Pederiva

Hi everyone!
I have a problem with the pool of connectcions that struts provides.
I work with Microsoft SQL-Server and when I query my database (all through stored 
procedures) everything works fine. 
The problem is when I call a stored procedure to update or delete some data. It 
does not update it neither delete tthe data!!!
It´s a problem of the connection because if I call that stored procedure with a 
new connection that i create, everything works ok!
Thanks a lot!!
Bye!
Inés Pederiva



RE: Pool problem

2001-11-15 Thread Roumen Ganeff

check to see if you have the property of the datasource/connection
autocommit=true;
or you shoudl call after each update
connection.commit()

G.

-Original Message-
From: Inés Pederiva [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 1:36 PM
To: [EMAIL PROTECTED]
Subject: Pool problem


Hi everyone!
I have a problem with the pool of connectcions that struts provides.
I work with Microsoft SQL-Server and when I query my database (all
through stored procedures) everything works fine.
The problem is when I call a stored procedure to update or delete some
data. It does not update it neither delete tthe data!!!
It´s a problem of the connection because if I call that stored procedure
with a new connection that i create, everything works ok!
Thanks a lot!!
Bye!
Inés Pederiva


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Recursive loop through an object collection

2001-11-15 Thread Stephen . Thompson

Hello All,

I am looking for a way to loop through an object structure to retrieve some
information to populate a list box. The object structure looks similar to
the following:

Root
  Object 1
Object 2
Object 3
  Object 4
  Object 5
Object 6
Object 7

I need to retrieve the details and then create a list box containing them.
Does anyone have any suggestions?

Thanks.

Regards,

Stephen.



---

Copyright material and/or confidential and/or privileged information may be contained 
in this e-mail and any attached documents.  The material and information is intended 
for the use of the intended addressee only.  If you are not the intended addressee, or 
the person responsible for delivering it to the intended addressee, you may not copy, 
disclose, distribute, disseminate or deliver it to anyone else or use it in any 
unauthorised manner or take or omit to take any action in reliance on it. To do so is 
prohibited and may be unlawful.   The views expressed in this e-mail may not be 
official policy but the personal views of the originator.  If you receive this e-mail 
in error, please advise the sender immediately by using the reply facility in your 
e-mail software, or contact [EMAIL PROTECTED]  Please also delete this e-mail and 
all documents attached immediately.  
Many thanks for your co-operation.

BMW Financial Services (GB) Limited is registered in England and Wales under company 
number 01288537.
Registered Offices : Europa House, Bartley Way, Hook, Hants, RG27 9UF
--

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Recursive loop through an object collection

2001-11-15 Thread Rey Francois

Some ideas:
 - Struts/Jakarta Common BeanUtils and PropertyUtils: the nested property
feature allows you to write things like getProperty(bean,
object1.object2.object3.field), even in struts tag. Requires no changes to
the objects. Best if the structure is stable.
 - Visitor pattern, however requires some changes to the objects. Best if
structure is variable (in terms of hierarchy levels, number of objects, type
of objects in the structure.

Fr.

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
Sent: 15 November 2001 12:39
To: [EMAIL PROTECTED]
Subject: Recursive loop through an object collection


Hello All,

I am looking for a way to loop through an object structure to retrieve some
information to populate a list box. The object structure looks similar to
the following:

Root
  Object 1
Object 2
Object 3
  Object 4
  Object 5
Object 6
Object 7

I need to retrieve the details and then create a list box containing them.
Does anyone have any suggestions?

Thanks.

Regards,

Stephen.




---

Copyright material and/or confidential and/or privileged information may be
contained in this e-mail and any attached documents.  The material and
information is intended for the use of the intended addressee only.  If you
are not the intended addressee, or the person responsible for delivering it
to the intended addressee, you may not copy, disclose, distribute,
disseminate or deliver it to anyone else or use it in any unauthorised
manner or take or omit to take any action in reliance on it. To do so is
prohibited and may be unlawful.   The views expressed in this e-mail may not
be official policy but the personal views of the originator.  If you receive
this e-mail in error, please advise the sender immediately by using the
reply facility in your e-mail software, or contact [EMAIL PROTECTED]
Please also delete this e-mail and all documents attached immediately.  
Many thanks for your co-operation.

BMW Financial Services (GB) Limited is registered in England and Wales under
company number 01288537.
Registered Offices : Europa House, Bartley Way, Hook, Hants, RG27 9UF

--

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

The information in this email is confidential and is intended solely
for the addressee(s).
Access to this email by anyone else is unauthorised. If you are not
an intended recipient, please notify the sender of this email 
immediately. You should not copy, use or disseminate the 
information contained in the email.
Any views expressed in this message are those of the individual
sender, except where the sender specifically states them to be
the views of Capco.

http://www.capco.com
***


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Can anyone help on this?

2001-11-15 Thread Konstantina Stamopoulou

Hello,
I'm using a template for my application and for the main content I want to display a 
table from a database.
When I access the database.do using a URL I get all the data correctly.
When I use this database.do file in the .jsp that uses the template I get :

javax.servlet.ServletException: Servlet Exception
at 
org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:459)
at 
_0002fcompany_0002ejspcompany_jsp_3._jspService(_0002fcompany_0002ejspcompany_jsp_3.java:234)
at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)


How should I handle this error?

Thanx in advance.



urgent help needed with javascript

2001-11-15 Thread Sanjay Duggal

Hi,

I've got the following javascript function in my jsp [which uses
struts]:
script language=JavaScript
function funcShowHide() {
if(document.formSpl.rbtn[0].checked == true)
{
document.formSpl.hiddenField.value = 'show';
}
else
{
document.formSpl.hiddenField.value = 'hide';
}
document.formSpl.submit();
}
/script
i'm calling the above function on click of radio button.
when i click the radio,I get the following javascript error:

JavaScript Error: document.formSpl.submit is not a function 

can anyone please help?

thanks,
Sanjay

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




jsp:include problem

2001-11-15 Thread Roumen Ganeff

Sorry, this is not struts at all, but i trust this list :)...

I do a jsp:include and on JRun with IIS 5.0 on windows2000 it displays
correctly. On JRun with iPlanet on winnt, the included JSP displays at the
top of the page before any other content is displayed. I think I have seen
this before, but couldn't find anything on java.sun.com or in struts-user

Thanx
Ganeff


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Titles.dtd FileNotFoundExeption when starting tomcat

2001-11-15 Thread storck

Hi,

as I started my Tomcat today I got that following exception:

java.io.FileNotFoundException:
http://jakarta.apache.org/struts/dtds/tiles-config.dtd

Did the dtd move to another location?

many thanks!


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Titles.dtd FileNotFoundExeption when starting tomcat

2001-11-15 Thread Lawson, Rick

Browsing to the file gives a 403 (No permission) error.

 -Original Message-
From:   storck [mailto:[EMAIL PROTECTED]] 
Sent:   15 November 2001 13:08
To: User Struts (E-Mail)
Subject:Titles.dtd FileNotFoundExeption when starting tomcat

Hi,

as I started my Tomcat today I got that following exception:

java.io.FileNotFoundException:
http://jakarta.apache.org/struts/dtds/tiles-config.dtd

Did the dtd move to another location?

many thanks!


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


_
This message has been checked for all known viruses by UUNET delivered 
through the MessageLabs Virus Control Centre. For further information visit
http://www.uk.uu.net/products/security/virus/


___
CONFIDENTIALITY NOTICE

The information contained in this e-mail is intended only for the individual or entity 
to whom it is addressed.  It may contain confidential and privileged information and 
if you are not an intended recipient, you must not copy, distribute or take any action 
in reliance on it.  If you have received this e-mail in error, please notify the 
sender and destroy and delete the message from your computer.

_
This message has been checked for all known viruses by UUNET delivered 
through the MessageLabs Virus Control Centre. For further information visit
http://www.uk.uu.net/products/security/virus/

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




AW: Titles.dtd FileNotFoundExeption when starting tomcat

2001-11-15 Thread storck

Do you know the reason why?

-Ursprüngliche Nachricht-
Von: Lawson, Rick [mailto:[EMAIL PROTECTED]]
Gesendet: Donnerstag, 15. November 2001 14:05
An: 'Struts Users Mailing List'
Betreff: RE: Titles.dtd FileNotFoundExeption when starting tomcat


Browsing to the file gives a 403 (No permission) error.

 -Original Message-
From:   storck [mailto:[EMAIL PROTECTED]]
Sent:   15 November 2001 13:08
To: User Struts (E-Mail)
Subject:Titles.dtd FileNotFoundExeption when starting tomcat

Hi,

as I started my Tomcat today I got that following exception:

java.io.FileNotFoundException:
http://jakarta.apache.org/struts/dtds/tiles-config.dtd

Did the dtd move to another location?

many thanks!


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


_
This message has been checked for all known viruses by UUNET delivered
through the MessageLabs Virus Control Centre. For further information visit
http://www.uk.uu.net/products/security/virus/


___
CONFIDENTIALITY NOTICE

The information contained in this e-mail is intended only for the individual
or entity to whom it is addressed.  It may contain confidential and
privileged information and if you are not an intended recipient, you must
not copy, distribute or take any action in reliance on it.  If you have
received this e-mail in error, please notify the sender and destroy and
delete the message from your computer.

_
This message has been checked for all known viruses by UUNET delivered
through the MessageLabs Virus Control Centre. For further information visit
http://www.uk.uu.net/products/security/virus/

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Newsgroup

2001-11-15 Thread Matt Raible

Beautiful!  Thanks for setting this up!

Matt

--- Vic Cekvenich [EMAIL PROTECTED] wrote:
 There is now another mirror of the Struts mail list at 
 news.basebeans.com as a newsgroup forum.
 It does not replicate post back to mail list yet ( it will in a week).
 
 More good stuff comming 
 
 HTH,
 Vic
 
 
 
 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




services property in a bean

2001-11-15 Thread Tom Klaasen (TeleRelay)

Anybody encountered this yet?

I have a bean which exposes a services property. Everything works just
fine on w2k with jdk 1.3.1.01 and 1.2.2r8, BUT when I deploy the
(identical same!) app on sunos 5.7 on a jdk 1.2.2, the services
property is not found through introspection (using the PropertyUtils
class). When I simply rename the getters for the property, everything
works like a charm.

Is this a known bug? Should Sun be informed about this? Or did I simply
do something plain stupid?

tomK


OS:
SunOS sysman1 5.7 Generic_106541-16 sun4u sparc SUNW,Ultra-5_10

jdk:
java version 1.2.2
Solaris VM (build Solaris_JDK_1.2.2_05a, native threads, sunwjit)

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Can anyone help on this?

2001-11-15 Thread Tom Klaasen (TeleRelay)

look further down the stack trace, starting from the line Root cause.
This might give you something more to work with ...

hth,
tomK

 -Original Message-
 From: Konstantina Stamopoulou [mailto:[EMAIL PROTECTED]] 
 Sent: donderdag 15 november 2001 12:56
 To: Struts Users Mailing List
 Subject: Can anyone help on this?
 
 
 Hello,
 I'm using a template for my application and for the main 
 content I want to display a table from a database.
 When I access the database.do using a URL I get all the data 
 correctly.
 When I use this database.do file in the .jsp that uses the 
 template I get :
 
 javax.servlet.ServletException: Servlet Exception
   at 
 org.apache.jasper.runtime.PageContextImpl.handlePageException(
 PageContextImpl.java:459)
   at 
 _0002fcompany_0002ejspcompany_jsp_3._jspService(_0002fcompany_
 0002ejspcompany_jsp_3.java:234)
   at 
 org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
 
 
 How should I handle this error?
 
 Thanx in advance.
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: include problem

2001-11-15 Thread Tom Klaasen (TeleRelay)

Seen it happening when writing between table tags but not tr or
td. Maybe you should check that.

hth,
tomK

 -Original Message-
 From: Roumen Ganeff [mailto:[EMAIL PROTECTED]] 
 Sent: donderdag 15 november 2001 13:42
 To: 'Struts Users Mailing List'
 Subject: jsp:include problem
 
 
 Sorry, this is not struts at all, but i trust this list :)...
 
 I do a jsp:include and on JRun with IIS 5.0 on windows2000 
 it displays
 correctly. On JRun with iPlanet on winnt, the included JSP 
 displays at the
 top of the page before any other content is displayed. I 
 think I have seen
 this before, but couldn't find anything on java.sun.com or in 
 struts-user
 
 Thanx
 Ganeff
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For 
 additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 
 

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Pool problem

2001-11-15 Thread Jon.Ridgway

Hi Ines,

I have never used the pool stuff in Struts, but is it possible that your
connection has auto-commit set and that the pooled connections don't? Do you
have a commit in the stored proc? If not add one and see if this fixes the
problem. 

Jon.

-Original Message-
From: Inés Pederiva [mailto:[EMAIL PROTECTED]] 
Sent: 15 November 2001 11:36
To: [EMAIL PROTECTED]
Subject: Pool problem

Hi everyone!
I have a problem with the pool of connectcions that struts provides.
I work with Microsoft SQL-Server and when I query my database (all
through stored procedures) everything works fine. 
The problem is when I call a stored procedure to update or delete some
data. It does not update it neither delete tthe data!!!
It´s a problem of the connection because if I call that stored procedure
with a new connection that i create, everything works ok!
Thanks a lot!!
Bye!
Inés Pederiva

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Error when forwarding from action to action

2001-11-15 Thread Steve Bendiola

Struts is looking for a forward named success for the Action (doLogin) you are 
executing.

   !-- Process a user logon --
actionpath=/doLogin
   type=sis.web.action.LoginAction
   name=loginForm
  scope=request
  input=/index.jsp
 
  forward name=failure  path=/index.jsp/
 
/action
Anat Rozenzon [EMAIL PROTECTED] wrote:

hi all,
 
I'm trying to forward from one action to another and get forward exception.
I have a LoginAction which checks all the login data and if it's ok it
should forward the request to HomeAction which prepare data for personal
home page.
 
I see in the logs that the LoginAction is processed succesfully until the
last line which is:
 
return (mapping.findForward(success));
 
It fails to go to the HomeAction. 
Here is the LoginAction code and struts-config.
 
 
=== LoginAction.java ===
 
package sis.web.action;
 
import java.io.IOException;
import java.util.Hashtable;
import java.util.Locale;
import javax.servlet.RequestDispatcher;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import javax.servlet.http.HttpServletResponse;
import org.apache.struts.action.Action;
import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionForward;
import org.apache.struts.action.ActionMapping;
import org.apache.struts.action.ActionServlet;
import org.apache.struts.util.MessageResources;
import org.apache.log4j.Category;
 
import sis.web.util.WebUtils;
import sis.web.util.WebKeys;
import sis.client.UserHandler;
import sis.core.SisFinderException;
 

 
public final class LoginAction extends Action {
 

static Category log = Category.getInstance(LoginAction.class);
// - Public
Methods
 
public ActionForward perform(ActionMapping mapping,
 ActionForm form,
 HttpServletRequest request,
 HttpServletResponse response)
 throws IOException, ServletException {
 
log.debug(starting);
 
 // Extract attributes we will need
 Locale locale = getLocale(request);
 MessageResources messages = getResources();
 HttpSession session = request.getSession();
 
// check for transaction token (if not exist this is first time, don't show
error
saveToken(request);


 // Validate the request parameters specified by the user
 ActionErrors errors = new ActionErrors();
 String username = ((LoginForm) form).getUsername();
 String formPassword = ((LoginForm) form).getPassword();
 
if (username == null) {
// check transaction condition
if (this.isTokenValid(request))
errors.add(user, new
ActionError(error.username.required));
else // first time, just go to jsp
return (new ActionForward(mapping.getInput()));
}
else {
// get signon handler
UserHandler userHandler = WebUtils.getUserHandler(session);

String password = null;
try {
password = userHandler.getPassword(username);
} catch (SisFinderException sfe) {
errors.add(user, new
ActionError(error.user.notfound,username));
}

if (password == null) {
errors.add(password, new
ActionError(error.password.required));
}
else if (!password.equals(formPassword))
errors.add(password, new
ActionError(error.password.mismatch));
}

 // Report any errors we have discovered back to the original form
 if (!errors.empty()) {
 saveErrors(request, errors);
 return (new ActionForward(mapping.getInput()));
 }
 
 // Save our logged-in user in the session
 session.setAttribute(WebKeys.USER_KEY, username);
 session.setAttribute(WebKeys.PASSWORD_KEY, formPassword);
log.info(User ' + username + ' logged on in session  +
session.getId());
 
// Remove the obsolete form bean
WebUtils.removeFormAttribute(mapping, request);
 
log.debug(Done removeFormAttribute);
 
// reset transaction token
resetToken(request);

log.debug(Done resetToken);

// Forward control to the specified success URI
 return (mapping.findForward(success));
 
}
}
 
=== struts-config.xml ===
?xml version=1.0 encoding=ISO-8859-1 ?
 
!DOCTYPE struts-config PUBLIC
  -//Apache Software Foundation//DTD Struts Configuration 1.0//EN
   http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd;
http://jakarta.apache.org/struts/dtds/struts-config_1_0.dtd 
 
struts-config
 
  !-- == Form Bean Definitions ===
--
  form-beans
!-- Logon form bean --
form-bean  name=loginForm

Re: Stuts-simple doesn't work (husted.com)

2001-11-15 Thread twrichter

Sorry Rob,

but it does not work (at least in my environment). I took stuts-simple.war in 
/webapps; inserted the configuration in my mod_jk.conf (like with all other apps) and 
started index.jsp. When pressing the start button the browser says: Page not found 
http://localhost/struts-simple/do/start;jsessionid=6knsr97rw1;
I deployed struts-simple like all other examples (struts-example, struts-blank a.s.o). 
It does not work? Any reason available?

Thank you in advance
Thomas

-Original Message-
From : Rob Breeds [EMAIL PROTECTED]
To : Struts Users Mailing List [EMAIL PROTECTED]
Date : 15 November 2001 10:12:52
Subject : Re: Stuts-simple doesn't work (husted.com)
Thomas

struts-simple does work! The struts config file does not have to be in the
WEB-INF dir - it's location is specified in web.xml. The struts.xml file is
the config file in this case.

Rob



  
   
tw.richter@scept  
   
ical.co.uk To: [EMAIL PROTECTED] 
   
   cc:
   
15/11/2001 08:05   Subject: Stuts-simple doesn't work 
(husted.com)   
Please respond
   
to “Struts Users  
   
Mailing List“ 
   
  
   
  
   




Hi out there!

I want to run the struts-simple example for wizards found in husted.com.
But it doesn't work. It did not find /do/... There is no struts-config in
/web-inf/, only a struts.xml in /web-inf/conf/. Is this example for another
struts version?

Regards
Thomas

:-) As sceptical as one can be! (-:



--
Get a free, personalised email address at http://another.com
TXT ALRT! Stop wasting money now. Send FREE, personalised txt
from http://another.com

--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]



:-) As sceptical as one can be! (-:



--
Personalise your email address at http://another.com
THINK: your slogan or email address on a gorgeous mousemat
CLICK HERE http://another-shop.com


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]


Same Form, multiple JSP's

2001-11-15 Thread Bauer, John


I have a LogonForm that is in multiple JSP's.  For each form, the action
would be /action/logon, and there can be error messages displayed.

I assume the 'input' parameter for action mappings can be used here, but how
would I be able in the config file to have the same action be called for
each of these forms/pages, but route the errors back to the correct calling
page?   Do I duplicate the action mapping entry for each page with a
different input attribute?  The DTD is a little unclear on how this would be
done.

Thanks for any help.
John




___ 

Juniper Bank 
Rated #1 in Customer Confidence 
Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
www.juniper.com 
___ 

This e-mail and any files transmitted with it may contain confidential
and/or proprietary information. It is intended solely for the use of the
individual or entity who is the intended recipient. Unauthorized use of this
information is prohibited. If you have received this in error, please
contact the sender by replying to this message and delete this material from
any system it may be on.

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Same Form, multiple JSP's

2001-11-15 Thread Jon.Ridgway

Hi John,

You could try something like this:

return (new ActionForward(mapping.getInput()));

Not tried it so I don't know if it will work. But...

Jon.

-Original Message-
From: Bauer, John [mailto:[EMAIL PROTECTED]] 
Sent: 15 November 2001 15:00
To: '[EMAIL PROTECTED]'
Subject: Same Form, multiple JSP's


I have a LogonForm that is in multiple JSP's.  For each form, the action
would be /action/logon, and there can be error messages displayed.

I assume the 'input' parameter for action mappings can be used here, but how
would I be able in the config file to have the same action be called for
each of these forms/pages, but route the errors back to the correct calling
page?   Do I duplicate the action mapping entry for each page with a
different input attribute?  The DTD is a little unclear on how this would be
done.

Thanks for any help.
John




___ 

Juniper Bank 
Rated #1 in Customer Confidence 
Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
www.juniper.com 
___ 

This e-mail and any files transmitted with it may contain confidential
and/or proprietary information. It is intended solely for the use of the
individual or entity who is the intended recipient. Unauthorized use of this
information is prohibited. If you have received this in error, please
contact the sender by replying to this message and delete this material from
any system it may be on.

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread Samant, Sanjay STASCO-OTO/72

On which platform? Include directories which contains jar files not jar
files in classpath

best of luck

-sanjay 

-Original Message-
From: Jay Sissom [mailto:[EMAIL PROTECTED]]
Sent: 15 November 2001 15:25
To: Struts Users Mailing List
Subject: Websphere 4.0/IBM Web server configuration


Hello, I am trying to test a struts application in the Websphere 4.0 app
server using IBM's web server.  My application is in a jar file.  The jar
file runs fine within Tomcat 4.0.

When I deploy the application in Websphere 4.0, I can access the .jsp pages,
but when I try to access a .do page, I get a 404 error.  I've checked within
Websphere and it sees my web.xml file and that file maps *.do URL's to the
struts action servlet.

Is there somplace else I need to map *.do URL's?

Thanks
Jay



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread Jay Sissom

This is on a Windows 2000 platform.

I'm not having a problem with the classpath, I'm having problems with
accessing URL's that end in .do.  The web server is trying to service them
instead of passing the requests to the Websphere application server.  I
can't figure out how to make the web server pass the requests to the app
server.

Thanks
Jay

- Original Message -
From: Samant, Sanjay STASCO-OTO/72 [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 10:27 AM
Subject: RE: Websphere 4.0/IBM Web server configuration


 On which platform? Include directories which contains jar files not jar
 files in classpath

 best of luck

 -sanjay

 -Original Message-
 From: Jay Sissom [mailto:[EMAIL PROTECTED]]
 Sent: 15 November 2001 15:25
 To: Struts Users Mailing List
 Subject: Websphere 4.0/IBM Web server configuration


 Hello, I am trying to test a struts application in the Websphere 4.0 app
 server using IBM's web server.  My application is in a jar file.  The jar
 file runs fine within Tomcat 4.0.

 When I deploy the application in Websphere 4.0, I can access the .jsp
pages,
 but when I try to access a .do page, I get a 404 error.  I've checked
within
 Websphere and it sees my web.xml file and that file maps *.do URL's to the
 struts action servlet.

 Is there somplace else I need to map *.do URL's?

 Thanks
 Jay



 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]

 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread moritz petersen

I have no experience with WS, but there is a special WS 4 version of struts
available at http://jakarta.apache.org/struts/userGuide/resources.html

-moritz.

 -Original Message-
 From: Jay Sissom [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 4:25 PM
 To: Struts Users Mailing List
 Subject: Websphere 4.0/IBM Web server configuration


 Hello, I am trying to test a struts application in the Websphere 4.0 app
 server using IBM's web server.  My application is in a jar file.  The jar
 file runs fine within Tomcat 4.0.

 When I deploy the application in Websphere 4.0, I can access the
 .jsp pages,
 but when I try to access a .do page, I get a 404 error.  I've
 checked within
 Websphere and it sees my web.xml file and that file maps *.do URL's to the
 struts action servlet.

 Is there somplace else I need to map *.do URL's?

 Thanks
 Jay



 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread Jay Sissom

Thank you, but that's the jar file I am using.  I've tried both.  I would
like to know what the difference is between that one and the original
release if someone knows.  All the web pages that talk about struts with
Websphere talk about 3.5x and it looks like 4.0 is a complete different
beast.

Thanks
Jay

- Original Message -
From: moritz petersen [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 10:36 AM
Subject: RE: Websphere 4.0/IBM Web server configuration


 I have no experience with WS, but there is a special WS 4 version of
struts
 available at http://jakarta.apache.org/struts/userGuide/resources.html

 -moritz.

  -Original Message-
  From: Jay Sissom [mailto:[EMAIL PROTECTED]]
  Sent: Thursday, November 15, 2001 4:25 PM
  To: Struts Users Mailing List
  Subject: Websphere 4.0/IBM Web server configuration
 
 
  Hello, I am trying to test a struts application in the Websphere 4.0 app
  server using IBM's web server.  My application is in a jar file.  The
jar
  file runs fine within Tomcat 4.0.
 
  When I deploy the application in Websphere 4.0, I can access the
  .jsp pages,
  but when I try to access a .do page, I get a 404 error.  I've
  checked within
  Websphere and it sees my web.xml file and that file maps *.do URL's to
the
  struts action servlet.
 
  Is there somplace else I need to map *.do URL's?
 
  Thanks
  Jay
 
 
 
  --
  To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]



 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Same Form, multiple JSP's

2001-11-15 Thread Bauer, John


I was suspecting that that would be the way, but how do I set up the action
mappings so all the various JSP's can call the same action, but that action
returns to the JSP that called it?  Do you need to write several action
mapping entries, one for each JSP with a separate input attribute?

-Original Message-
From: Jon.Ridgway [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 10:10 AM
To: 'Struts Users Mailing List'
Subject: RE: Same Form, multiple JSP's


Hi John,

You could try something like this:

return (new ActionForward(mapping.getInput()));

Not tried it so I don't know if it will work. But...

Jon.

-Original Message-
From: Bauer, John [mailto:[EMAIL PROTECTED]] 
Sent: 15 November 2001 15:00
To: '[EMAIL PROTECTED]'
Subject: Same Form, multiple JSP's


I have a LogonForm that is in multiple JSP's.  For each form, the action
would be /action/logon, and there can be error messages displayed.

I assume the 'input' parameter for action mappings can be used here, but how
would I be able in the config file to have the same action be called for
each of these forms/pages, but route the errors back to the correct calling
page?   Do I duplicate the action mapping entry for each page with a
different input attribute?  The DTD is a little unclear on how this would be
done.

Thanks for any help.
John




___ 

Juniper Bank 
Rated #1 in Customer Confidence 
Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
www.juniper.com 
___ 

This e-mail and any files transmitted with it may contain confidential
and/or proprietary information. It is intended solely for the use of the
individual or entity who is the intended recipient. Unauthorized use of this
information is prohibited. If you have received this in error, please
contact the sender by replying to this message and delete this material from
any system it may be on.

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


___ 

Juniper Bank 
Rated #1 in Customer Confidence 
Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
www.juniper.com 
___ 

This e-mail and any files transmitted with it may contain confidential
and/or proprietary information. It is intended solely for the use of the
individual or entity who is the intended recipient. Unauthorized use of this
information is prohibited. If you have received this in error, please
contact the sender by replying to this message and delete this material from
any system it may be on.

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread ltorrence

the instructions pasted below (taken from this list in a post by Chris
Assenza) worked for me with the standard Struts 1.0 release (haven't tried
the nightly builds).


From: Assenza, Chris [[EMAIL PROTECTED]]
Sent: Monday, September 24, 2001 9:59 AM
To: '[EMAIL PROTECTED]'
Subject: RE: Struts installation on Websphere 4.0

Still haven't had time to formalize these directions, so they are likely to
change once I get time to remove extraeous steps or correct things. :)

rief Preliminary Deployment Instructions for WAS 4.0

·   Deploy Application
o   Install WebSphere 4.0
o   Once completed and system is restarted (if necessary): Start
the WebSphere service   (startServer.bat on NT, probably startServer.sh on
Unix)
o   After the server has started, log onto the web-based
Administration Console  (http://localhost:9090/admin).
o   Next, expand Nodes on the left.
o   Click on Enterprise Applications
o   Click on Install
o   Browse to the file Deployed_app.ear that you created with
the AA tool.
o   Select the file follow the steps the console takes you
through:
§   Click next on EJB deployment screen.
§   Click next on the Web Module deployment screen
(change your preference on  pre-compiling if you so
desire).
§   On the next screen, allow WebSphere to redeploy
YourApp-ejb.jar by leaving  the box checked and clicking
next. (ed: Not sure if this step is necessary)
§   Review the settings and click Finish when ready.
·   Once finished, begin JDBC configuration. (for Oracle)
o   Expand Resources in the left navigation area.
o   Click JDBC Drivers
o   Click New
§   The Server Class Path is the location of
classes12.zip (Oracle's JDBCdrivers) on the
server.
§   Name is: OracleJdbcDriver
§   Implementation Classname is:
oracle.jdbc.pool.OracleConnectionPoolDataSource
o   Click Ok to add the driver.
o   Expand the newly created OracleJdbcDriver in the
left navigation area.
o   Click on Data Sources
o   Click New
§   Name is: somePool
§   JNDI Name is: jdbc/somePool
§   Default Userid is: someId 
§   Defaults Password is: somePass 
§   All others left blank/default.
o   Click Ok to add the Data Source.
o   From the Data Source screen, click on somePool.
o   Click on Property Set (on the bottom).
o   Click Resource Properties
o   Click New
§   Name is: URL
§   Type is: java.lang.String
§   Value is: jdbc:oracle:thin:user/pass@host:port:sid 
Where:
·   user/pass are the username/password
respectively
·   host is the IP address of the Oracle
DB Server 
·   port is the port on which Oracle is
listening (ex. 1521).
·   sid is the Oracle SID or name for
the database
o   Click Ok until you've reached the Data Source Screen.
·   Complete Deployment
o   Click Save on the nav-bar at the top of the screen.
o   Select server-config.xml (or the top option) and click Ok.  
o   Stop and then restart the WebSphere AppServer.
·   Once started, go to http://someIpAddress/appname/file.jsp to test
the deployment.



Christopher Assenza 



Re: Stuts-simple doesn't work (husted.com)

2001-11-15 Thread Rob Breeds


Thomas

Sorry I didn't offer anything before. In the web.xml file you should have:

  servlet-mapping id=ServletMapping_2
 servlet-nameaction/servlet-name
 url-pattern/do/*/url-pattern
  /servlet-mapping
  welcome-file-list id=WelcomeFileList_1
 welcome-fileindex.jsp/welcome-file

I imagine you didn't change anything.

If you do a view source on the rendered start page what action do you see
for the form? I get:
action=/simple/do/start

(my base name is 'simple')

I'm not seeing any of the jsessionid stuff appended to paths in any page as
I use the app. Maybe that's a clue? Do you have cookies turned off?

Rob



   

twrichter@anot 

her.com  To: struts users mailing list 
[EMAIL PROTECTED]
 cc:   

15/11/2001   Subject: Re: Stuts-simple doesn't work 
(husted.com)   
13:29  

Please respond 

to Struts 

Users Mailing  

List  

   

   





Sorry Rob,

but it does not work (at least in my environment). I took stuts-simple.war
in /webapps; inserted the configuration in my mod_jk.conf (like with all
other apps) and started index.jsp. When pressing the start button the
browser says: Page not found
http://localhost/struts-simple/do/start;jsessionid=6knsr97rw1;
I deployed struts-simple like all other examples (struts-example,
struts-blank a.s.o). It does not work? Any reason available?

Thank you in advance
Thomas

-Original Message-
From : Rob Breeds [EMAIL PROTECTED]
To : Struts Users Mailing List [EMAIL PROTECTED]
Date : 15 November 2001 10:12:52
Subject : Re: Stuts-simple doesn't work (husted.com)
Thomas

struts-simple does work! The struts config file does not have to be in the
WEB-INF dir - it's location is specified in web.xml. The struts.xml file
is
the config file in this case.

Rob




tw.richter@scept
ical.co.uk To:
[EMAIL PROTECTED]
   cc:
15/11/2001 08:05   Subject: Stuts-simple
doesn't work (husted.com)
Please respond
to Struts Users
Mailing List






Hi out there!

I want to run the struts-simple example for wizards found in husted.com.
But it doesn't work. It did not find /do/... There is no struts-config in
/web-inf/, only a struts.xml in /web-inf/conf/. Is this example for
another
struts version?

Regards
Thomas

:-) As sceptical as one can be! (-:



--
Get a free, personalised email address at http://another.com
TXT ALRT! Stop wasting money now. Send FREE, personalised txt
from http://another.com

--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]



:-) As sceptical as one can be! (-:



--
Personalise your email address at http://another.com
THINK: your slogan or email address on a gorgeous mousemat
CLICK HERE http://another-shop.com
--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread Rob Breeds

That 'fixed' version of struts.jar would not cause this problem (you'd be
getting a 'missing attributes' type error message). WAS 4.01 doesn't need
the special struts.jar as the original bug in WebSphere is fixed.

Can you see your deployed application in the WAS admin console?

Rob Breeds




   

moritz

petersenTo: Struts Users Mailing List 
[EMAIL PROTECTED]  
moritzpeterse   cc:   

[EMAIL PROTECTED]   Subject: RE: Websphere 4.0/IBM Web server 
configuration   
   

15/11/2001 

15:36  

Please respond 

to Struts 

Users Mailing  

List  

   

   





I have no experience with WS, but there is a special WS 4 version of struts
available at http://jakarta.apache.org/struts/userGuide/resources.html

-moritz.

 -Original Message-
 From: Jay Sissom [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 4:25 PM
 To: Struts Users Mailing List
 Subject: Websphere 4.0/IBM Web server configuration


 Hello, I am trying to test a struts application in the Websphere 4.0 app
 server using IBM's web server.  My application is in a jar file.  The jar
 file runs fine within Tomcat 4.0.

 When I deploy the application in Websphere 4.0, I can access the
 .jsp pages,
 but when I try to access a .do page, I get a 404 error.  I've
 checked within
 Websphere and it sees my web.xml file and that file maps *.do URL's to
the
 struts action servlet.

 Is there somplace else I need to map *.do URL's?

 Thanks
 Jay



 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Same Form, multiple JSP's

2001-11-15 Thread Sean Owen

Yeah, I think you are right about how this is best done - this is how we
handled the same situation. However you would need two different paths for
the two pages:

action path=/action/logon1 type=project.LogonAction name=logonForm
input=/pageOne.jsp
...
/action

action path=/action/logon2 type=project.LogonAction name=logonForm
input=/pageTwo.jsp
...
/action

Two action mappings using the same action/form. I like the flexibility here.

Sean


- Original Message -
From: Bauer, John [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 2:59 PM
Subject: Same Form, multiple JSP's



 I have a LogonForm that is in multiple JSP's.  For each form, the action
 would be /action/logon, and there can be error messages displayed.

 I assume the 'input' parameter for action mappings can be used here, but
how
 would I be able in the config file to have the same action be called for
 each of these forms/pages, but route the errors back to the correct
calling
 page?   Do I duplicate the action mapping entry for each page with a
 different input attribute?  The DTD is a little unclear on how this would
be
 done.

 Thanks for any help.
 John




 ___

 Juniper Bank
 Rated #1 in Customer Confidence
 Gomez Inc., Summer 2001 Internet Credit Card Scorecard
 www.juniper.com
 ___

 This e-mail and any files transmitted with it may contain confidential
 and/or proprietary information. It is intended solely for the use of the
 individual or entity who is the intended recipient. Unauthorized use of
this
 information is prohibited. If you have received this in error, please
 contact the sender by replying to this message and delete this material
from
 any system it may be on.

 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]


_
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Forte Tomcat - standalone tomcat

2001-11-15 Thread Maciej Koodziej

Hi,

I've  a  problem  with  moving  my  application from Forte for Java to
standalone Tomcat server.
While  testing  under Forte everything works fine, but when I copy all
files  from  "Document Base" folder and all my classes (Actions, Forms,
etc.)  to  tomcat/webapps/  I  get  "Cannot  find  ActionMappings  or
ActionFormBeans collection" error.
I  know  this error was already talked about on this list, but this is
different  -  the  syntax  of  struts-config.xml  is  ok  (it works on
forte4j). So what's wrong?

-- 
Best regards,
Maciej


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Struts Vs Expresso 4

2001-11-15 Thread Robert J. Sanford, Jr.

is there a beta of webappwriter that we can download now that
expresso4 has been officially released?

rjsjr

 -Original Message-
 From: Pete Carapetyan [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, October 31, 2001 8:02 AM
 To: Struts Users Mailing List
 Subject: Re: Struts Vs Expresso 4
 
 
  What is 'webappwriter' - sounds like my kinda software!
 
  Any ideas where I can find out more about it, and when it might 
 be released?
 
 http://webAppWriter.com
 is currently providing the Expresso 3.11 or non-Struts version.
 vaporIt is a crude shadow of it's Struts version, which is 
 still a few weeks
 from release, but gives you the basic idea./vapor
 
 It has many benefits of course, but until it is open sourced it 
 is a bit of a
 pain to have to use is on someone elses site.
 
  snip
  There's a lot off 'guff' when writing a web app that I really 
 want to avoid
  - I just want to design the business logic and the view, and 
 leave most of
  the rest of it to some framework
 
 vaporThat was the basic idea, if you can wait the few weeks for 
 the Struts
 version to be available. /vapor
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Titles.dtd FileNotFoundExeption when starting tomcat

2001-11-15 Thread Cedric Dumoulin

  Hello,

  No, the dtd url haven't change. But I think that the url has never been set on
jakarta.
  This should not be a problem, as Digester is registered to look for the dtd in
the tiles.jar package (or in classes under org.apache.struts.tiles.resources).
  Do you have change something on your side ?

Cedric

storck wrote:

 Hi,

 as I started my Tomcat today I got that following exception:

 java.io.FileNotFoundException:
 http://jakarta.apache.org/struts/dtds/tiles-config.dtd

 Did the dtd move to another location?

 many thanks!

 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Struts and JBuilder

2001-11-15 Thread Mihails Gulajevs

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hello all!

Does anybody know how to build/debug struts-based applications in
JBuilder. Seems that I cannot add in the project struts.jar and
struts-bean.tld files.

Thanks in advance

Mihail
-BEGIN PGP SIGNATURE-
Version: PGPfreeware 6.0.2i

iQA/AwUBO/PWwI3AfpLTCnW4EQIGJQCeNr8EgT1qqBErhr4AoqwytuKOqqcAoJOs
wTLTYIC2EJc/XueZItRGd8hU
=fxWB
-END PGP SIGNATURE-


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Struts and JBuilder

2001-11-15 Thread Dave J Dandeneau

JBuilder won't let you see any of the files in the WEB-INF directory
except the web.xml. It can be pretty confusing at first. I have had
success adding these to the directory structure through the OS, and then
adding them to JBuilder by right clicking on the JBuilder project and
choosing New Folder, and naming it something like config, and then
adding the files manually to that folder by right clicking on it and
choosing Add Files / Packages. This way you can atleast see the files
like struts-config.xml and validation.xml if you have them in your
WEB-INF directory.

You will also want to get the nostrutstomcat32.jar and the
webinfextension.jar if you are going to run things from within JBuilder.
Add those to the jbuilder/lib/ext directory.

I hope that helps,
Dave

-Original Message-
From: Mihails Gulajevs [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 11:53 AM
To: Struts-User
Subject: Struts and JBuilder


-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

Hello all!

Does anybody know how to build/debug struts-based applications in
JBuilder. Seems that I cannot add in the project struts.jar and
struts-bean.tld files.

Thanks in advance

Mihail
-BEGIN PGP SIGNATURE-
Version: PGPfreeware 6.0.2i

iQA/AwUBO/PWwI3AfpLTCnW4EQIGJQCeNr8EgT1qqBErhr4AoqwytuKOqqcAoJOs
wTLTYIC2EJc/XueZItRGd8hU
=fxWB
-END PGP SIGNATURE-


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




RE: Download within a sturts-action brakes forward

2001-11-15 Thread Matthieu Maher

Hi all
Roland, could you tell me more about your Download object please, because
I need to do the same thing as you and your download method is what I need,
but I don't know how you made Download before calling Download.download

-Message d'origine-
De : Roland Berger [mailto:[EMAIL PROTECTED]]
Envoyé : jeudi 8 novembre 2001 08:59
À : Struts Mailinglist
Objet : Download within a sturts-action brakes forward


Hi all

I would like to download the content of a collection (in my case a
LinkedList) to the client within an action. This works fine until I want to
return from the action with *return mapping.findForward( success );*.
Struts is not forwarding to the success page. I think the problem is that I
close the OutputStream of the response but if I don't do that the collection
is not downloaded.
I could write the content of the collection to disk and then download a file
but this costs more time.
See code below.
Does somebody have an idea how to do a download within an action so that
forwarding to an other *.jsp/*.do still works?

Thank you
Roland

public ActionForward perform( ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response )
 throws IOException, ServletException {

LinkedList myDataSource = null;

.snippet

//** See method download below 
Download.download(myDataSource, response, errors);


return mapping.findForward( success );
} // End methode perform




public static synchronized void download(
Collection pCollection,
HttpServletResponse pResponse,
ActionErrors pErrors )
 throws IOException {

ServletOutputStream os = null;

try {
os = pResponse.getOutputStream();

Iterator myIterDataSource = pCollection.iterator();

pResponse.setContentType( application/octet-stream );
pResponse.setHeader( Content-Disposition, attachment;
filename=\ +
DataSource.txt + \; );

while ( myIterDataSource.hasNext() ) {
os.println( (String) myIterDataSource.next() );
}
// os.flush();
} catch ( Exception ex ) {
cat.debug( ex.toString() );
pErrors.add( Download, new ActionError(
error.exception.Download ) );
} finally {
// os.close();
}
// end finally
}
// end method download




Roland Berger
Software Ingenieur HTL


plenum Systems (Schweiz) AG
- Ein Unternehmen der plenum AG -

Lyssachstrasse 15
CH-3400 Burgdorf

Tel +41 34 424 17 70
Fax +41 34 424 17 74
WWW http://www.plenum-systems.ch



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Struts and JBuilder

2001-11-15 Thread Richard Reich

I've used JBuilder with Tomcat and Struts for many months, successfully (I
thought).  Never heard of either of these jars.  What problem do they solve?

-r

- Original Message -
From: Dave J Dandeneau [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 9:16 AM
Subject: RE: Struts and JBuilder


[...]

You will also want to get the nostrutstomcat32.jar and the
webinfextension.jar if you are going to run things from within JBuilder.
Add those to the jbuilder/lib/ext directory.



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Struts Vs Expresso 4

2001-11-15 Thread Pete Carapetyan

Robert J. Sanford, Jr. wrote:

 is there a beta of webappwriter that we can download now that
 expresso4 has been officially released?

webAppWriter for Struts/Expresso4.0 is currently functioning and serving up
Expresso applications (a struts implementation with many other features) at
http://webAppWriter.com

...HOWEVER...it is still an early release, the documentation and 30 or so sample
applications are still stuck at Expresso 3.11 level (no struts) and other
features are not yet tested. It will probably be Dec 1st before these are up to
date.

It will not be formally announced until then, but it will still whoop out a
pretty amazing meg or two worth of jsps, controllers, etc for you to use right
now, and I have installed entire secured custom web apps for a customer here in
Dallas with a couple dozen input/output forms, all per a spreadsheet typed in by
the company's receptionist. Took less than a day, from receiving the
receptionist's spreadsheet of the forms she wanted filled out over the web, to
deployment and testing.

Kind of begs credibility. The company's owner wasn't complaining though.

If you have never used Expresso it is a bit like old dBase or Microsoft Access
(gag) for J2EE, in that it does so much for you without any coding, table access,
security, many optional interfaces, etc etc. Unlike these, however, it is all
pure source code sitting on your box for you to use or not use, or customize,
each feature as you wish. Still, it is a hard pill to swallow for those who
insist on authoring every line of code in their entire web application. We just
seem to prefer the collaboration/components approach to doing things. Oh well.
Much of it is Apache code, but there are cool things that only Expresso has, as
well.

Whatever you do, if you decide to test out Expresso, don't make the mistake of
integrating it into your app server for the initial test. Download the complete
version that installs with it's own Tomcat, in a separate folder. That goes up in
10 minutes and won't interfere with your other J2EE work. That way, you can check
it out without having to configure anything, and if you like it, integrate al or
part of it into your app server and/or database after that. This will save you
much heartache, and allow you to make a reasoned decision based on what it does,
rather than based on whether or not you had time to configure all the initial
parameters.

webAppWriter is not opensourced yet, and won't be until I find more work. Until
then, it serves as a magnet  and embellishment to my otherwise unimpressive Java
resume.



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




how does this checkbox thing work?

2001-11-15 Thread Alex Colic

Hi,

can't seem to get this checkbox to work.
I have an app that reads the fields of a database and creates an array of
field objects. Then a jsp is produced allowing the user to input the new
data.

I have a checkbox that is tied to a field object that has a setValue(String)
and getValue() method. When I read the database and the checkbox should be
set I set the value to 1. This seems to have worked but when the screen is
produced and the checkbox is checked and I uncheck it I find that the
setValue() method is not being called and that the old value of 1 is being
set.

Any help is appreciated in understanding how to fix this.

Alex


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Struts and JBuilder

2001-11-15 Thread Dave J Dandeneau

Do you run tomcat from within JBuilder? Have you manually changed your
classpath?

nostrutstomcat32.jar removes the struts.jar from the classpath at
startup. At runtime it is included with the webapp. 

The webinfextension.jar just adds some tlds. 

You can find more info about the both of these on borland's opentool
site: 

http://codecentral.borland.com/codecentral/

I think that they call it The Struts Addin or Struts Support or
somethings like that.

dave dandeneau

-Original Message-
From: Richard Reich [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 1:34 PM
To: Struts Users Mailing List
Subject: Re: Struts and JBuilder


I've used JBuilder with Tomcat and Struts for many months, successfully
(I
thought).  Never heard of either of these jars.  What problem do they
solve?

-r

- Original Message -
From: Dave J Dandeneau [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 9:16 AM
Subject: RE: Struts and JBuilder


[...]

You will also want to get the nostrutstomcat32.jar and the
webinfextension.jar if you are going to run things from within JBuilder.
Add those to the jbuilder/lib/ext directory.



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




RE: Struts and JBuilder

2001-11-15 Thread Nekkalapudi, Viplava

nostrutstomcat32.jar
webinfextension.jar 

These are Struts Support Addin for JBuilder 5.0 
and not required for JB4.0/JB6.0. 
 


-Original Message-
From: Richard Reich [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 12:34 PM
To: Struts Users Mailing List
Subject: Re: Struts and JBuilder


I've used JBuilder with Tomcat and Struts for many months, successfully (I
thought).  Never heard of either of these jars.  What problem do they solve?

-r

- Original Message -
From: Dave J Dandeneau [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 9:16 AM
Subject: RE: Struts and JBuilder


[...]

You will also want to get the nostrutstomcat32.jar and the
webinfextension.jar if you are going to run things from within JBuilder.
Add those to the jbuilder/lib/ext directory.



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: how does this checkbox thing work?

2001-11-15 Thread dhay



Alex,

do you reset the checkbox in the reset() method?  You need to - see more info in
archives.

Cheers,

Dave





Alex Colic [EMAIL PROTECTED] on 11/15/2001
01:49:45 PM

Please respond to Struts Users Mailing List
  [EMAIL PROTECTED]

To:   Struts [EMAIL PROTECTED]
cc:(bcc: David Hay/Lex/Lexmark)
Subject:  how does this checkbox thing work?



Hi,

can't seem to get this checkbox to work.
I have an app that reads the fields of a database and creates an array of
field objects. Then a jsp is produced allowing the user to input the new
data.

I have a checkbox that is tied to a field object that has a setValue(String)
and getValue() method. When I read the database and the checkbox should be
set I set the value to 1. This seems to have worked but when the screen is
produced and the checkbox is checked and I uncheck it I find that the
setValue() method is not being called and that the old value of 1 is being
set.

Any help is appreciated in understanding how to fix this.

Alex


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]








--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




FW: Struts Support AddIn for JBuilder 5.0

2001-11-15 Thread Nekkalapudi, Viplava

I have already forwarded it, But this tells about JB6.0 also.

-Original Message-
From: Ken Sipe [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 07, 2001 2:40 PM
To: Nekkalapudi, Viplava
Subject: Re: Struts Support AddIn for JBuilder 5.0


You should be able to have struts work with jb4.  There was a large change 
in how webapps are created in jb5.  The opentool allows struts to work in 
jb5.

Specifically, jb5 puts webapp jars on the classpath of the webserver and in 
the lib directory which doesn't work with struts or may other tools for that

matter.

second, struts makes use of may custom tags, the support for them was 
limited in jb5.  This was fixed with the addon tool

Ken


btw,  you won't need the opentools for jb6 either.  
It is only a jb5 issue.  I just tested the beta jb6, it works great.




_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Same Form, multiple JSP's

2001-11-15 Thread Keith Bacon

John,
What about having a hidden field (called nextPlaceToGo) on each diff.
version of the form. Then loginAction can have:-

String nextPlaceToGo formBean.getNextPlaceToGo();
return forwardTo(mapping, nextPlaceToGo);

This means your login form can't be identical in each place which is
a shame. I think(?) it can be identical if you are using templates,
or JavaScript to set the hidden field from a value fetched from the
page that contains it.
I think it's a bit wasteful to have lots of nearly identical action
mappings - it depends how many there would be really.
hth - Keith.


--- Bauer, John [EMAIL PROTECTED] wrote:
 
 I was suspecting that that would be the way, but how do I set up
 the action
 mappings so all the various JSP's can call the same action, but
 that action
 returns to the JSP that called it?  Do you need to write several
 action
 mapping entries, one for each JSP with a separate input attribute?
 
 -Original Message-
 From: Jon.Ridgway [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 10:10 AM
 To: 'Struts Users Mailing List'
 Subject: RE: Same Form, multiple JSP's
 
 
 Hi John,
 
 You could try something like this:
 
   return (new ActionForward(mapping.getInput()));
 
 Not tried it so I don't know if it will work. But...
 
 Jon.
 
 -Original Message-
 From: Bauer, John [mailto:[EMAIL PROTECTED]] 
 Sent: 15 November 2001 15:00
 To: '[EMAIL PROTECTED]'
 Subject: Same Form, multiple JSP's
 
 
 I have a LogonForm that is in multiple JSP's.  For each form, the
 action
 would be /action/logon, and there can be error messages displayed.
 
 I assume the 'input' parameter for action mappings can be used
 here, but how
 would I be able in the config file to have the same action be
 called for
 each of these forms/pages, but route the errors back to the correct
 calling
 page?   Do I duplicate the action mapping entry for each page with
 a
 different input attribute?  The DTD is a little unclear on how this
 would be
 done.
 
 Thanks for any help.
 John
 
 
 
 
 ___ 
 
 Juniper Bank 
 Rated #1 in Customer Confidence 
 Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
 www.juniper.com 
 ___ 
 
 This e-mail and any files transmitted with it may contain
 confidential
 and/or proprietary information. It is intended solely for the use
 of the
 individual or entity who is the intended recipient. Unauthorized
 use of this
 information is prohibited. If you have received this in error,
 please
 contact the sender by replying to this message and delete this
 material from
 any system it may be on.
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 --
 To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 
 
 ___ 
 
 Juniper Bank 
 Rated #1 in Customer Confidence 
 Gomez Inc., Summer 2001 Internet Credit Card Scorecard 
 www.juniper.com 
 ___ 
 
 This e-mail and any files transmitted with it may contain
 confidential
 and/or proprietary information. It is intended solely for the use
 of the
 individual or entity who is the intended recipient. Unauthorized
 use of this
 information is prohibited. If you have received this in error,
 please
 contact the sender by replying to this message and delete this
 material from
 any system it may be on.
 
 --
 To unsubscribe, e-mail:  
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]
 


__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: how does this checkbox thing work?

2001-11-15 Thread SUPRIYA MISRA


html:checkbox property=vaAppt value=yes/
if getVaAppt() returns yes it is checked else not
From: Alex Colic [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts [EMAIL PROTECTED]
Subject: how does this checkbox thing work?
Date: Thu, 15 Nov 2001 13:49:45 -0500

Hi,

can't seem to get this checkbox to work.
I have an app that reads the fields of a database and creates an array of
field objects. Then a jsp is produced allowing the user to input the new
data.

I have a checkbox that is tied to a field object that has a 
setValue(String)
and getValue() method. When I read the database and the checkbox should be
set I set the value to 1. This seems to have worked but when the screen is
produced and the checkbox is checked and I uncheck it I find that the
setValue() method is not being called and that the old value of 1 is being
set.

Any help is appreciated in understanding how to fix this.

Alex


--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]



_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread Jay Sissom

Here was the solution to my problem:

When deploying the application there was a very small message that said I
had to regenerate the plugin configuration file.  I missed that message.
When you regenerate the plugin configuration file, it tells the web server
which URL's to pass to the app server.

Jay

- Original Message -
From: Rob Breeds [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 10:48 AM
Subject: RE: Websphere 4.0/IBM Web server configuration


 That 'fixed' version of struts.jar would not cause this problem (you'd be
 getting a 'missing attributes' type error message). WAS 4.01 doesn't need
 the special struts.jar as the original bug in WebSphere is fixed.

 Can you see your deployed application in the WAS admin console?

 Rob Breeds





 moritz
 petersenTo: Struts Users Mailing
List [EMAIL PROTECTED]
 moritzpeterse   cc:
 [EMAIL PROTECTED]   Subject: RE: Websphere
4.0/IBM Web server configuration

 15/11/2001
 15:36

 Please respond
 to Struts
 Users Mailing
 List






 I have no experience with WS, but there is a special WS 4 version of
struts
 available at http://jakarta.apache.org/struts/userGuide/resources.html

 -moritz.

  -Original Message-
  From: Jay Sissom [mailto:[EMAIL PROTECTED]]
  Sent: Thursday, November 15, 2001 4:25 PM
  To: Struts Users Mailing List
  Subject: Websphere 4.0/IBM Web server configuration
 
 
  Hello, I am trying to test a struts application in the Websphere 4.0 app
  server using IBM's web server.  My application is in a jar file.  The
jar
  file runs fine within Tomcat 4.0.
 
  When I deploy the application in Websphere 4.0, I can access the
  .jsp pages,
  but when I try to access a .do page, I get a 404 error.  I've
  checked within
  Websphere and it sees my web.xml file and that file maps *.do URL's to
 the
  struts action servlet.
 
  Is there somplace else I need to map *.do URL's?
 
  Thanks
  Jay
 
 
 
  --
  To unsubscribe, e-mail:
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
 mailto:[EMAIL PROTECTED]



 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]





 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: html checkbox tag

2001-11-15 Thread Nekkalapudi, Viplava

check here in the documentation.
http://jakarta.apache.org/struts/struts-html.html#checkbox

-Original Message-
From: Juan Alvarado [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 11:42 AM
To: Struts
Subject: html checkbox tag


Can anyone tell me why the following is happening.

I have a form with some textboxes, radio buttons, a drop-down and a single
checkbox control.

The checkbox control looks like: Sports: html:checkbox
property=categories value=sports /

I have implemented the validate method in my form to make the user enter a
value in one of my textboxes. Whenever a value is not entered, the user is
forwarded back to the form. However, the previous state of all the controls
in the form are kept with the exception of the checkbox. In other words, if
I check it and don't enter a name in the textfield for name and submit the
form, when I get redirected back to the form, the checkbox is not checked.

Thanks in advance

**
Juan Alvarado
Internet Developer -- Manduca Management
(786)552-0504
[EMAIL PROTECTED]
AOL Instant Messenger: [EMAIL PROTECTED]


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




If someone is interested

2001-11-15 Thread Yuriy Zubarev

Hello colleagues,

I've been developing a web app for myself and since
it's not the first app using Struts I attempted
to solve some general issues by providing some interfaces,
custom tag and generic actions. More specifically I'm talking
about tables, you know that questions about navigation,
sorting, formatting and so on...

To see what's done already, point your browser to
http://english.yuriy-zubarev.com

And if my work raises some interest among people,
I'll beautify the code (if there is no big load in the office) 
and share it (with one of the purposes to get feedbacks
and criticism).

Best of luck,
Yuriy Zubarev




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Struts WAP Devices: Kudos to Craig Struts Development Team

2001-11-15 Thread Rajan Gupta

I just completed a project using Struts where the initial implementation
was browser based. Then I changed the view to suit a WAP device  used WML
tags. Without changing a single line of code in the Controller  the
Model, the application was up  running in no time.

I just created new actions in struts-config.xml  I was on my way.

Kudos to Craig  the rest of the Struts Designers  Developers for
architecting a true Model 2 architecture. Also I would like to recognize
David Geary for the JSP template  for writing an excellent book.




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Help-URGENT!!

2001-11-15 Thread Ashoka Murthy

I have a vector object available in request. Now I want to check in the JSP 
whether its size is 0 or more, if it is 0 I want to print a message No Data 
available in the jsp. I want to know how to do this in Struts framework?

Thanks
Ashoka Murthy

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Help-URGENT!!

2001-11-15 Thread Francois Duchaussoy

Have a look to Struts Logic Tag logic:equal

-Original Message-
From: Ashoka Murthy [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 16, 2001 11:17 AM
To: [EMAIL PROTECTED]
Subject: Help-URGENT!!


I have a vector object available in request. Now I want to check in the JSP 
whether its size is 0 or more, if it is 0 I want to print a message No Data

available in the jsp. I want to know how to do this in Struts framework?

Thanks
Ashoka Murthy

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Help-URGENT!!

2001-11-15 Thread MacKellar, Kimberly

You can do a bean:size id=vectorSize... to the size of the vector.
Then do a logic:equal value=0 name=vectorSize  
I think this should work but haven't tried it.

-Original Message-
From: Francois Duchaussoy [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 4:13 PM
To: 'Struts Users Mailing List'
Subject: RE: Help-URGENT!!


Have a look to Struts Logic Tag logic:equal

-Original Message-
From: Ashoka Murthy [mailto:[EMAIL PROTECTED]]
Sent: Friday, November 16, 2001 11:17 AM
To: [EMAIL PROTECTED]
Subject: Help-URGENT!!


I have a vector object available in request. Now I want to check in the JSP 
whether its size is 0 or more, if it is 0 I want to print a message No Data

available in the jsp. I want to know how to do this in Struts framework?

Thanks
Ashoka Murthy

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Help-URGENT!!

2001-11-15 Thread Brian Cochran

There are a couple options.
One way is to define a context variable in the page and then use a scriptlet
to see if the size is zero.

bean:define id=myvector name=stashedVector scope=request
type=java.util.Vector /
Where stashedVector is the attribute name of the Vector you stashed
(presumably in your Action)

% if ( myvector != null  myvector.size()  0 ) { %
  stuff to include
% } else { %
  No Data Available
% } %

also there are predefined variables in the page request, session,
pageContext, and some others (i think)
so you can do the following.

% java.util.Vector myvector = (java.util.Vector)
request.getAttribute(stashedVector); %
and then do as above.

I don't think you can use the logic:* tags because Vector.size() does not
conform to a JavaBean specification
of getters and setters. (Somebody correct me if there is a nicer way of
doing this.)

Hope this helps,
Brian


-Original Message-
From: Ashoka Murthy [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 5:17 PM
To: [EMAIL PROTECTED]
Subject: Help-URGENT!!


I have a vector object available in request. Now I want to check in the JSP
whether its size is 0 or more, if it is 0 I want to print a message No Data
available in the jsp. I want to know how to do this in Struts framework?

Thanks
Ashoka Murthy

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: Help-URGENT!!

2001-11-15 Thread Ted Husted

I usually put things like this in a thin JavaBean wrapper, so properties
like size can be returned by a proper getSize() method call. 

Ashoka Murthy wrote:
 
 I have a vector object available in request. Now I want to check in the JSP
 whether its size is 0 or more, if it is 0 I want to print a message No Data
 available in the jsp. I want to know how to do this in Struts framework?
 
 Thanks
 Ashoka Murthy
 
 _
 Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp
 
 --
 To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: Help-URGENT!!

2001-11-15 Thread See Yam Lim

yes. the bean:size id=vectorSize... should works.

or you can try.

in JSP. do this.
%
  List myVector = (List)request.getAttribute(whatever_key_for_vector);
  pageContext.setAttribute(vectorSize, new Integer(myVector.size())); 
%

logic:equal name=vectorSize value=0
   bean:message name=NoData/
or
No Data available!  
/logic:equal

See-Yam Lim




 -Original Message-
 From: Ashoka Murthy [mailto:[EMAIL PROTECTED]]
 Sent: Thursday, November 15, 2001 5:17 PM
 To: [EMAIL PROTECTED]
 Subject: Help-URGENT!!
 
 
 I have a vector object available in request. Now I want to 
 check in the JSP 
 whether its size is 0 or more, if it is 0 I want to print a 
 message No Data 
 available in the jsp. I want to know how to do this in 
 Struts framework?
 
 Thanks
 Ashoka Murthy
 
 _
 Get your FREE download of MSN Explorer at 
 http://explorer.msn.com/intl.asp
 
 
 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]
 



links to javascript with index variables

2001-11-15 Thread Rob Breeds

In my ActionForm I have a collection of names which is added to
dynamically. If I want to give each name its own delete link I'm doing this
with iterate:

logic:iterate id=el name=reallySimpleForm property=names
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del');bean:message key
=link.delete//html:linkBR
/logic:iterate

(where subForm is a JavaScript function to submit the form, and set an
action, of 'del' in this case)

but how do I add an index value into the javascript call for the link? To
generate something like:

html:link href=javascript:subForm(document.forms[0],'del', 0) (last param
being the index)
html:link href=javascript:subForm(document.forms[0],'del', 1)
html:link href=javascript:subForm(document.forms[0],'del', 2)
.
.
.

Is the only way to do this using scriptlets?

Thanks

Rob Breeds




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: If someone is interested

2001-11-15 Thread Rob Breeds


Yuriy

I'm keen to see the source for this - all working examples are useful to
help me (and others) avoid what must be common pitfalls.

Thanks

Rob Breeds





   

Yuriy Zubarev  

yuriy_zubarev   To: [EMAIL PROTECTED]

@yahoo.ca   cc:   

 Subject: If someone is interested 

15/11/2001 

21:45  

Please respond 

to Struts 

Users Mailing  

List  

   

   





Hello colleagues,

I've been developing a web app for myself and since
it's not the first app using Struts I attempted
to solve some general issues by providing some interfaces,
custom tag and generic actions. More specifically I'm talking
about tables, you know that questions about navigation,
sorting, formatting and so on...

To see what's done already, point your browser to
http://english.yuriy-zubarev.com

And if my work raises some interest among people,
I'll beautify the code (if there is no big load in the office)
and share it (with one of the purposes to get feedbacks
and criticism).

Best of luck,
Yuriy Zubarev




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




multiple select

2001-11-15 Thread MacKellar, Kimberly

Hi All,
I have a JSP that contains 
  bean:define id=notAssociated name=editAssociationsForm
property=notAssociatedInsts/
  td
html:select size=10 property=newAssociations multiple=true
style=width=206;
 html:options collection=notAssociated property=value
labelProperty=label/
/html:select
  /td

notAssociated is an ArrayList of LabelValueBeans

when i submit the form containing this snippet it gets sent to an action
that contains  the following code
...
EditAssociationsForm assocForm = (EditAssociationsForm)form;
String[] blah = assocForm.getNewAssociations();
if(blah == null) {
cat.debug(blah is null);
}
else {
cat.debug(blah length= + blah.length);
for(int x=0; xblah.length; x++) {
cat.debug(blah[x]);
}
}


this is always printing blah length=0

the EditAssociationsForm contains the following
...
private String[] newAssociations;

public void reset(ActionMapping mapping, HttpServletRequest request) {

selectedAccount = null;
associatedInsts = null;
notAssociatedInsts = null; 
if(newAssociations != null) {
System.out.println(newAssoc length= + newAssociations.length);
for(int i=0; inewAssociations.length; i++) {
System.out.println(assoc= + newAssociations[i]);
}
}
else {
System.out.println(newAssociations is null);
}
newAssociations = new String[0];
}

public void setNewAssociations(String[] newAssociations) {
System.out.println(newAssociations= + newAssociations.length);
newAssociations = newAssociations;
}

public String[] getNewAssociations() {
return newAssociations;
}
...

This prints newAssociations is null and newAssociations=num selected in
jsp which means reset is being called then the value is being set.  I
don't see any other print outs from this code to indicate reset is being
called again.

and my struts config contains
...
action path=/saveAssociations
type=com.tfp.admintool.account.SaveAssociationsAction
name=editAssociationsForm
scope=request
validate=false
  forward name=success path=/main.jsp/
/action
...

Does anyone see why the reset appears to be getting called or why the length
of the array is always being set to 0?  

My head is starting to hurt from banging it against the wall...


Kimberly MacKellar
Thomson Financial Publishing
[EMAIL PROTECTED]


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Extending ActionMapping class

2001-11-15 Thread Brandon Goodin

Greetings,

I don't know if what I am doing can be done. I want to use set-property in
the struts-config.xml file in my action mapping to provide some custom
properties. The properties will share the same name, but have different
values. Here is my assumption. From what I have read of the Digester it
sounds to me like the addSetProperty will (in short) call the setter of a
particular Class (in this case my extended version of ActionMapping) and
pass the value to the setter that is defined for that property name. I am
collecting the passed values into a Vector in the setter (see below) that
can be called from an Action class using the mapping.getXXX() and do an
iteration and comparison. Anyways, please see my code and commentary below
and if you have the guru-age to enlighten me then I would sure appreciate
it.


--
In my struts-config.xml I have the following for an action mapping:
--
action parameter= path=/admin unknown=false
type=ws.phase.admin.action.AdminAction
set-property property=aproperty value=valuea /
set-property property=aproperty value=valueb /
forward name=login path=/phaseadmin/login.jsp redirect=false /
forward name=auth path=/phaseadmin/main.jsp redirect=false /
/action



--
I have extended to ActionMapping class with the following:
--
import org.apache.struts.action.*;
import org.apache.struts.util.*;

import javax.servlet.ServletException;
import javax.servlet.http.*;

import java.util.*;
/**
 *
 * @author  Administrator
 * @version
 */
public class ExtendedActionMapping extends ActionMapping{

protected Vector aproperty = new Vector();

public ExtendedActionMapping () {
super();
}

public void setAproperty(String aproperty){
this.aproperty.add(aproperty);
}

public Vector getAproperty(){
return aproperty;
}
}



--
I then want to get the vector from the mapping object. I assume it will go
something like so:
--
-- Previous Action stuff

//This is within the perform method
Vector vec = mapping.getRole();

-- Following Action stuff



--
I am not sure I set up my web.xml file properly to direct all mapping to the
extended mapping class.
I set up my web.xml file to use the exteded ActionMapping class like so:
--

  servlet
servlet-nameaction/servlet-name
servlet-classorg.apache.struts.action.ActionServlet/servlet-class
init-param
  param-nameapplication/param-name
  param-valueApplicationResources/param-value
/init-param
init-param
  param-nameconfig/param-name
  param-value/WEB-INF/struts-config.xml/param-value
/init-param
init-param
  param-namedebug/param-name
  param-value2/param-value
/init-param
init-param
  param-namedetail/param-name
  param-value2/param-value
/init-param
init-param
  param-namevalidate/param-name
  param-valuetrue/param-value
/init-param
!-- This is where I insert what I assume will override the default
ActionMapping class to use my extended class --
init-param
param-namemapping/param-name
param-valuecom.mycompany.ExtendedActionMapping/param-value
/init-param
!-- End of insertion --
load-on-startup2/load-on-startup
  /servlet

--

Thanks,
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, e-mail: mailto:[EMAIL PROTECTED]




Re: links to javascript with index variables

2001-11-15 Thread Rob Breeds


I tried this:

logic:iterate id=el name=reallySimpleForm property=names indexId
=i
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del','%= i.toString()
%');bean:message key=link.delete//html:linkBR
/logic:iterate

but that just generates links of:
javascript:subForm(document.forms[0],'del','%= i.toString() %');

instead of javascript:subForm(document.forms[0],'del','0');

How can I get scripting variables inside the html:link href attribute?

Thanks

Rob



   

Rob

Breeds/UK/IBM@   To: Struts Users Mailing List 
[EMAIL PROTECTED]  
IBMGBcc:   

 Subject: links to javascript with index 
variables 
15/11/2001 

22:58  

Please respond 

to Struts 

Users Mailing  

List  

   

   





In my ActionForm I have a collection of names which is added to
dynamically. If I want to give each name its own delete link I'm doing this
with iterate:

logic:iterate id=el name=reallySimpleForm property=names
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del');bean:message key
=link.delete//html:linkBR
/logic:iterate

(where subForm is a JavaScript function to submit the form, and set an
action, of 'del' in this case)

but how do I add an index value into the javascript call for the link? To
generate something like:

html:link href=javascript:subForm(document.forms[0],'del', 0) (last param
being the index)
html:link href=javascript:subForm(document.forms[0],'del', 1)
html:link href=javascript:subForm(document.forms[0],'del', 2)
.
.
.

Is the only way to do this using scriptlets?

Thanks

Rob Breeds




--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




(NEVERMIND) Extending ActionMapping class

2001-11-15 Thread Brandon Goodin



-Original Message-
From: Brandon Goodin [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 4:09 PM
To: 'Struts Users Mailing List'
Subject: Extending ActionMapping class


Greetings,

I don't know if what I am doing can be done. I want to use set-property in
the struts-config.xml file in my action mapping to provide some custom
properties. The properties will share the same name, but have different
values. Here is my assumption. From what I have read of the Digester it
sounds to me like the addSetProperty will (in short) call the setter of a
particular Class (in this case my extended version of ActionMapping) and
pass the value to the setter that is defined for that property name. I am
collecting the passed values into a Vector in the setter (see below) that
can be called from an Action class using the mapping.getXXX() and do an
iteration and comparison. Anyways, please see my code and commentary below
and if you have the guru-age to enlighten me then I would sure appreciate
it.


--
In my struts-config.xml I have the following for an action mapping:
--
action parameter= path=/admin unknown=false
type=ws.phase.admin.action.AdminAction
set-property property=aproperty value=valuea /
set-property property=aproperty value=valueb /
forward name=login path=/phaseadmin/login.jsp redirect=false /
forward name=auth path=/phaseadmin/main.jsp redirect=false /
/action



--
I have extended to ActionMapping class with the following:
--
import org.apache.struts.action.*;
import org.apache.struts.util.*;

import javax.servlet.ServletException;
import javax.servlet.http.*;

import java.util.*;
/**
 *
 * @author  Administrator
 * @version
 */
public class ExtendedActionMapping extends ActionMapping{

protected Vector aproperty = new Vector();

public ExtendedActionMapping () {
super();
}

public void setAproperty(String aproperty){
this.aproperty.add(aproperty);
}

public Vector getAproperty(){
return aproperty;
}
}



--
I then want to get the vector from the mapping object. I assume it will go
something like so:
--
-- Previous Action stuff

//This is within the perform method
Vector vec = mapping.getRole();

-- Following Action stuff



--
I am not sure I set up my web.xml file properly to direct all mapping to the
extended mapping class.
I set up my web.xml file to use the exteded ActionMapping class like so:
--

  servlet
servlet-nameaction/servlet-name
servlet-classorg.apache.struts.action.ActionServlet/servlet-class
init-param
  param-nameapplication/param-name
  param-valueApplicationResources/param-value
/init-param
init-param
  param-nameconfig/param-name
  param-value/WEB-INF/struts-config.xml/param-value
/init-param
init-param
  param-namedebug/param-name
  param-value2/param-value
/init-param
init-param
  param-namedetail/param-name
  param-value2/param-value
/init-param
init-param
  param-namevalidate/param-name
  param-valuetrue/param-value
/init-param
!-- This is where I insert what I assume will override the default
ActionMapping class to use my extended class --
init-param
param-namemapping/param-name
param-valuecom.mycompany.ExtendedActionMapping/param-value
/init-param
!-- End of insertion --
load-on-startup2/load-on-startup
  /servlet

--

Thanks,
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, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: links to javascript with index variables

2001-11-15 Thread Rob Breeds

And then I tried it without struts tags:

A HREF=javascript:subForm(document.forms[0],'del','%= i.toString()
%');try this/A

and it works! Why doesn't it work when the same code is put into the Struts
html:link href attribute ?

Rob



   

Rob

Breeds/UK/IBM@   To: Struts Users Mailing List 
[EMAIL PROTECTED]  
IBMGBcc:   

 Subject: Re: links to javascript with 
index variables 
15/11/2001 

23:39  

Please respond 

to Struts 

Users Mailing  

List  

   

   






I tried this:

logic:iterate id=el name=reallySimpleForm property=names indexId
=i
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del','%= i.toString()
%');bean:message key=link.delete//html:linkBR
/logic:iterate

but that just generates links of:
javascript:subForm(document.forms[0],'del','%= i.toString() %');

instead of javascript:subForm(document.forms[0],'del','0');

How can I get scripting variables inside the html:link href attribute?

Thanks

Rob




Rob
Breeds/UK/IBM@   To: Struts Users Mailing
List [EMAIL PROTECTED]
IBMGBcc:
 Subject: links to javascript
with index variables
15/11/2001
22:58
Please respond
to Struts
Users Mailing
List






In my ActionForm I have a collection of names which is added to
dynamically. If I want to give each name its own delete link I'm doing this
with iterate:

logic:iterate id=el name=reallySimpleForm property=names
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del');bean:message key
=link.delete//html:linkBR
/logic:iterate

(where subForm is a JavaScript function to submit the form, and set an
action, of 'del' in this case)

but how do I add an index value into the javascript call for the link? To
generate something like:

html:link href=javascript:subForm(document.forms[0],'del', 0) (last param
being the index)
html:link href=javascript:subForm(document.forms[0],'del', 1)
html:link href=javascript:subForm(document.forms[0],'del', 2)
.
.
.

Is the only way to do this using scriptlets?

Thanks

Rob Breeds




--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: If someone is interested

2001-11-15 Thread Brian . Duchouquette


Yuriy,

Yep, you have my interest.. Are you using multiple sets with different
Comparators (based on bean properties) to do that?

Thanks,
Brian



   

Yuriy Zubarev  

yuriy_zubarev   To: [EMAIL PROTECTED]

@yahoo.ca   cc:   

 Subject: If someone is interested 

11/15/2001 

03:45 PM   

Please respond 

to Struts 

Users Mailing  

List  

   

   





Hello colleagues,

I've been developing a web app for myself and since
it's not the first app using Struts I attempted
to solve some general issues by providing some interfaces,
custom tag and generic actions. More specifically I'm talking
about tables, you know that questions about navigation,
sorting, formatting and so on...

To see what's done already, point your browser to
http://english.yuriy-zubarev.com

And if my work raises some interest among people,
I'll beautify the code (if there is no big load in the office)
and share it (with one of the purposes to get feedbacks
and criticism).

Best of luck,
Yuriy Zubarev




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]






--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: links to javascript with index variables

2001-11-15 Thread Rob Breeds

I then tried this, using a scriptlet to create the javascript first:

% String tryit = javascript:subForm(document.forms[0],'del','+i+');;
%
Name: bean:write name=el/ html:link href=%= tryit %bean:message
key=link.delete//html:link

and that works too!

Now can someone clever please share with me how to do this elegantly
without reverting to scriptlets?

Thanks!

Rob



   

Rob

Breeds/UK/IBM@   To: Struts Users Mailing List 
[EMAIL PROTECTED]  
IBMGBcc:   

 Subject: Re: links to javascript with 
index variables 
15/11/2001 

23:47  

Please respond 

to Struts 

Users Mailing  

List  

   

   





And then I tried it without struts tags:

A HREF=javascript:subForm(document.forms[0],'del','%= i.toString()
%');try this/A

and it works! Why doesn't it work when the same code is put into the Struts
html:link href attribute ?

Rob




Rob
Breeds/UK/IBM@   To: Struts Users Mailing
List [EMAIL PROTECTED]
IBMGBcc:
 Subject: Re: links to
javascript with index variables
15/11/2001
23:39
Please respond
to Struts
Users Mailing
List







I tried this:

logic:iterate id=el name=reallySimpleForm property=names indexId
=i
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del','%= i.toString()
%');bean:message key=link.delete//html:linkBR
/logic:iterate

but that just generates links of:
javascript:subForm(document.forms[0],'del','%= i.toString() %');

instead of javascript:subForm(document.forms[0],'del','0');

How can I get scripting variables inside the html:link href attribute?

Thanks

Rob




Rob
Breeds/UK/IBM@   To: Struts Users Mailing
List [EMAIL PROTECTED]
IBMGBcc:
 Subject: links to javascript
with index variables
15/11/2001
22:58
Please respond
to Struts
Users Mailing
List






In my ActionForm I have a collection of names which is added to
dynamically. If I want to give each name its own delete link I'm doing this
with iterate:

logic:iterate id=el name=reallySimpleForm property=names
Name: bean:write name=el/ html:link href
=javascript:subForm(document.forms[0],'del');bean:message key
=link.delete//html:linkBR
/logic:iterate

(where subForm is a JavaScript function to submit the form, and set an
action, of 'del' in this case)

but how do I add an index value into the javascript call for the link? To
generate something like:

html:link href=javascript:subForm(document.forms[0],'del', 0) (last param
being the index)
html:link href=javascript:subForm(document.forms[0],'del', 1)
html:link href=javascript:subForm(document.forms[0],'del', 2)
.
.
.

Is the only way to do this using scriptlets?

Thanks

Rob Breeds




--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL PROTECTED]





--
To unsubscribe, e-mail:   
mailto:[EMAIL PROTECTED]
For additional commands, e-mail: 
mailto:[EMAIL 

RE: If someone is interested

2001-11-15 Thread Long Nguyen

Hi Yuriy,

How do you implement the pager tag?  Is it possible if you can share the
code with everyone?

Thanks,

Long B. Nguyen

-Original Message-
From: Yuriy Zubarev [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 1:45 PM
To: [EMAIL PROTECTED]
Subject: If someone is interested


Hello colleagues,

I've been developing a web app for myself and since
it's not the first app using Struts I attempted
to solve some general issues by providing some interfaces,
custom tag and generic actions. More specifically I'm talking
about tables, you know that questions about navigation,
sorting, formatting and so on...

To see what's done already, point your browser to
http://english.yuriy-zubarev.com

And if my work raises some interest among people,
I'll beautify the code (if there is no big load in the office) 
and share it (with one of the purposes to get feedbacks
and criticism).

Best of luck,
Yuriy Zubarev




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




RE: HOW TO: set up a pager with struts

2001-11-15 Thread Brian Cochran

Whereas this may be a little cross posted, I just submitted a proposal to
struts-dev on possibly developing a suite of
PageIterators that have support for various functionality including:
cacheing, JDBC 2.0 RecordSets, the Petstore way of requerying every time and
support for extending to different methods. Let me know if you are
interested on working on this.

Brian


-Original Message-
From: Long Nguyen [mailto:[EMAIL PROTECTED]]
Sent: Thursday, November 15, 2001 7:09 PM
To: 'Struts Users Mailing List'
Subject: RE: HOW TO: set up a pager with struts



Hi Oleg,

If it is not too much trouble, can you send me an example?

Thanks.

Long B. Nguyen

-Original Message-
From: Oleg V Alexeev [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, November 14, 2001 2:23 AM
To: Struts Users Mailing List; [EMAIL PROTECTED]
Subject: Re: HOW TO: set up a pager with struts


Hello storck,

I can suggest you my way. On base of query parameters, offset and page
length values generate container or array of objects from database and
store total value of records. Container or array you can display with
iterate tag. For purposes of page links generation I can suggest bean
and tag for you - I can send it for you.

Wednesday, November 14, 2001, 1:09:06 PM, you wrote:

s Hi,

s I am developing a webapp with struts and EJB's. In some cases I only have
to
s display a list of Items. The problem is, that I cant show the whole list
...
s sure to big ...
s For retrieving the list I will either use the Fast-Lane Reader Pattern
and
s the Page-by-Page Iterator Pattern. In the Pet Store Demo they
s implemented the Page-by-Page Iterator as a applicationspecific Tag, but
I
s think it should also be possible to implement it with struts (I am
right).
s Now I NEED your HELP. How must I set it up correct?

s Any suggestions and comments are welcome !!!


s --
s To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
s For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
Best regards,
 Olegmailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]

--
To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
For additional commands, e-mail:
mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: If someone is interested

2001-11-15 Thread Ho Chin Hwang


Yes. I m keen to see too.

Regards,
-Dave

- Original Message -
From: [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Friday, November 16, 2001 8:02 AM
Subject: Re: If someone is interested



 Yuriy,

 Yep, you have my interest.. Are you using multiple sets with different
 Comparators (based on bean properties) to do that?

 Thanks,
 Brian




 Yuriy Zubarev
 yuriy_zubarev   To:
[EMAIL PROTECTED]
 @yahoo.ca   cc:
  Subject: If someone is
interested
 11/15/2001
 03:45 PM
 Please respond
 to Struts
 Users Mailing
 List






 Hello colleagues,

 I've been developing a web app for myself and since
 it's not the first app using Struts I attempted
 to solve some general issues by providing some interfaces,
 custom tag and generic actions. More specifically I'm talking
 about tables, you know that questions about navigation,
 sorting, formatting and so on...

 To see what's done already, point your browser to
 http://english.yuriy-zubarev.com

 And if my work raises some interest among people,
 I'll beautify the code (if there is no big load in the office)
 and share it (with one of the purposes to get feedbacks
 and criticism).

 Best of luck,
 Yuriy Zubarev




 __
 Do You Yahoo!?
 Find the one for you at Yahoo! Personals
 http://personals.yahoo.com

 --
 To unsubscribe, e-mail:   
 mailto:[EMAIL PROTECTED]
 For additional commands, e-mail: 
 mailto:[EMAIL PROTECTED]






 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Fw: Websphere 4.0/IBM Web server configuration

2001-11-15 Thread dion

Do you have messages in the console/log showing the action mappings being 
loaded?

Are there any exceptions loading the web app?
--
dIon Gillard, Multitask Consulting
Work:  http://www.multitask.com.au
JavaNews: http://www.multitask.com.au/JavaNews
- Forwarded by dIon Gillard/Multitask Consulting/AU on 16/11/2001 01:06 PM -
Websphere 4.0/IBM Web server configuration

Hello, I am trying to test a struts application in the Websphere 4.0 app
server using IBM's web server.  My application is in a jar file.  The jar
file runs fine within Tomcat 4.0.

When I deploy the application in Websphere 4.0, I can access the .jsp 
pages,
but when I try to access a .do page, I get a 404 error.  I've checked 
within
Websphere and it sees my web.xml file and that file maps *.do URL's to the
struts action servlet.

Is there somplace else I need to map *.do URL's?

Thanks
Jay


populating an ActionForm with indexed properties

2001-11-15 Thread Fyodor Golos

I have an ActionForm with nested indexed propeties:

public class MyActionForm extends ActionForm {
private List nested;
...
}

where each nested element is:

public class Nested {
private String title;
private Double price;
...
}

Assume that my reset() looks like this:

public void reset(...) {
nested = new ArrayList();
}

I can display this form in a jsp (using latest html taglib, not 1.0
release) but I am stuck populating my ActionForm with submitted
parameters.

Property names, such as nested[0].title, etc., are created just fine
in my html pages.

Obviously, struts (or actually it's commons-beanutils) does not know
that I need a list of Nested objects, although it might have an idea of
how many. Is there anything that I can implement so that my form will
get a chance to go ahead and create a list of Nested objects so that
actual indexed properties can be set?

Right now, I end up with an empty list when all is said and done... :(

The code I provided is obviously just an example I used for
generalization.

Thanks!

--
Fyodor Golos
ResGen, Invitrogen Corporation
2130 Memorial Pkwy, SW
Huntsville, AL 35801
Phone: 800-533-4363
Direct: 256-327-4297
Fax: 256-536-9016




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Where do servlet debug log entries go to??

2001-11-15 Thread Greg Callaghan

Hi,

[1] Where do the servlet debug log messages go to in terms of file and path? 
  I can't seem to find them!  For example the struts example

if (servlet.getDebug() = 1)
   servlet.log(LogonAction: User ' + user.getUsername() +
   ' logged on in session  + session.getId());

[2] Is there something beyond setting the servlet debug parameter in the 
web.xml file for the app that is required to get debug happening.  That is 
-:

init-param
  param-namedebug/param-name
  param-value3/param-value
/init-param

[3] Any thoughts on whether there is benefit in going to Log4j above and 
beyond the struts servlet debug functionality?


Thanks in advance
Greg


_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp


--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




ActionForms lifecycle across multiple requests

2001-11-15 Thread Fyodor Golos

I am trying to save myself A LOT of repetitive coding by reusing my
business objects in my ActionForm objects. For example, this is how one
of them looks like:

public MyActionForm extends ActionForm {
private MyBusinessObject businessObject;
...
}

The HTML form that uses this object only represents a subset of various
properties (some indexed, some nested, i.e. all kinds). In html taglibs
I am referring to them as businessObject.nested[0].title, etc. The
HTML form represents a subset of all of the properties, therefore after
the form is submitted, only SOME of the properties come back as request
parameters.

If I do not implement validate() and leave my form alone, can I count on
the same business object to still be there? In other words, is my form
saved in the session context or is there a pool of MyActionForm objects
used by multiple sessions and this session might get someone else's
MyActionForm?

In general, am I abusing the system, so to speak? Should I implement an
ActionForm that simply maps to my HTML form one-to-one and then perform
conversions between that object and my business objects? I just have
quite complex objects and would like to save myself time by reusing
already implemented javabeans.

Thanks!

--
Fyodor Golos
ResGen, Invitrogen Corporation
2130 Memorial Pkwy, SW
Huntsville, AL 35801
Phone: 800-533-4363
Direct: 256-327-4297
Fax: 256-536-9016




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: If someone is interested

2001-11-15 Thread Nicolas Parisé

Hi,


I'm interested to see your code, i'm looking
for good examples of struts app

Thank you

Nicolas
- Original Message -
From: Yuriy Zubarev [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Thursday, November 15, 2001 4:45 PM
Subject: If someone is interested


 Hello colleagues,

 I've been developing a web app for myself and since
 it's not the first app using Struts I attempted
 to solve some general issues by providing some interfaces,
 custom tag and generic actions. More specifically I'm talking
 about tables, you know that questions about navigation,
 sorting, formatting and so on...

 To see what's done already, point your browser to
 http://english.yuriy-zubarev.com

 And if my work raises some interest among people,
 I'll beautify the code (if there is no big load in the office)
 and share it (with one of the purposes to get feedbacks
 and criticism).

 Best of luck,
 Yuriy Zubarev




 __
 Do You Yahoo!?
 Find the one for you at Yahoo! Personals
 http://personals.yahoo.com

 --
 To unsubscribe, e-mail:
mailto:[EMAIL PROTECTED]
 For additional commands, e-mail:
mailto:[EMAIL PROTECTED]




--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]




Re: If someone is interested

2001-11-15 Thread Christian Rab

Your application looks really cool, I'am very interested tho see your code!

See you
Christian


15.11.2001 22:45:09, Yuriy Zubarev [EMAIL PROTECTED] wrote:
Hello colleagues,

I've been developing a web app for myself and since
it's not the first app using Struts I attempted
to solve some general issues by providing some interfaces,
custom tag and generic actions. More specifically I'm talking
about tables, you know that questions about navigation,
sorting, formatting and so on...

To see what's done already, point your browser to
http://english.yuriy-zubarev.com

And if my work raises some interest among people,
I'll beautify the code (if there is no big load in the office) 
and share it (with one of the purposes to get feedbacks
and criticism).

Best of luck,
Yuriy Zubarev




__
Do You Yahoo!?
Find the one for you at Yahoo! Personals
http://personals.yahoo.com

--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]






--
To unsubscribe, e-mail:   mailto:[EMAIL PROTECTED]
For additional commands, e-mail: mailto:[EMAIL PROTECTED]