[OT] XForms

2003-08-01 Thread Andrew Hill
Currently the app Im working on is using an xhtml front end (with struts of
course) but Ive been asked to look at XForms with an eye to migrating to it
in the future (and probably throwing in a migration to JSF while Im there).

Currently the XForms spec is only a candidate release with afaik very little
browser support, though I gather there are a number of plugins that
implement an XForms processor.

I'm in the process of reading through whats on the w3c site about it but am
still pretty clueless as to what it really implies in terms of what we would
do different to now. While I understand what I am reading I dont truly grok
it yet.

Anyone else been looking into this and can share some pointers on what I
need to think about?

Is XForms really going to be the next stage in the evolution of forms on the
browser or is it just some hyped up hot air thats really a wild goose chase?


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



RE: Direct ValueObject creation rather than ActionForm.

2003-08-01 Thread Viral_Thakkar
Yes, I agree that it is not good programming to replace the ActionForm
with ValueObject.

But let me know your view about having both ActionForm and ValueObject
and use some kind of mapping to get the ValueObject instance from the
ActionForm instance.

Example is available at
http://www.mycgiserver.com/~andrej/technical/struts/struts.jsp

Here usage of 
vo = FormToVOMapper.map(form, new ExampleVO()); 
is shown.

Please suggest me whether this is good to use such mapping to get the
valueobject instance and also do they support all possible datatypes and
different mappings.

Thanks.

-Original Message-
From: Kalra, Ashwani [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 10:57 AM
To: 'Struts Users Mailing List'
Subject: RE: Direct ValueObject creation rather than ActionForm.

One drawback. ActionForm classes import classes from http packages.
which
binds it to the particular layer. 

Cheers
Ashwani Kalra
http://www.geocities.com/ashwani_kalra/


 -Original Message-
 From: Andrew Hill [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 10:47 AM
 To: Struts Users Mailing List
 Subject: RE: Direct ValueObject creation rather than ActionForm.
 
 
 This is quite a common idea that many people new to struts 
 have. There are
 quite a few reasons why your ActionForm and your value object 
 are different
 objects. (Indeed the very reason ActionForm is implemented as 
 a class rather
 than an interface is specifically to discourage people from 
 using their
 ActionForm as a value object.) If you search the list 
 archives you will see
 numerous threads discussing the reasons why this is in fact a 
 very bad idea
 indeed.
   -Original Message-
   From: Viral_Thakkar [mailto:[EMAIL PROTECTED]
   Sent: Friday, 1 August 2003 13:05
   To: [EMAIL PROTECTED]
   Subject: Direct ValueObject creation rather than ActionForm.
 
 
   I have a idea here. Why we require ActionForm class if we can have
 ValueObject and that we can pass to the service layer.
 
 
 
   Can we create the instance of ValueObject class only rather than
 ActionForm instance from the request data?
 
 
 
   Thanks
 
 
 
 
 
 


This message contains information that may be privileged or confidential
and
is the property of the Cap Gemini Ernst  Young Group. It is intended
only
for the person to whom it is addressed. If you are not the intended
recipient, you are not authorised to read, print, retain, copy,
disseminate,
distribute, or use this message or any part thereof. If you receive this
message in error, please notify the sender immediately and delete all
copies
of this message.

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


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



RE: Direct ValueObject creation rather than ActionForm.

2003-08-01 Thread Kalra, Ashwani
I just went thrugh its main features. One major drawback is that it doesnt
support primitives. 
You can write your own fn in the form class to convert it into VO/DTO.

Cheers
Ashwani Kalra
http://www.geocities.com/ashwani_kalra/


 -Original Message-
 From: Viral_Thakkar [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 12:46 PM
 To: Struts Users Mailing List; [EMAIL PROTECTED];
 [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: RE: Direct ValueObject creation rather than ActionForm.
 
 
 Yes, I agree that it is not good programming to replace the ActionForm
 with ValueObject.
 
 But let me know your view about having both ActionForm and ValueObject
 and use some kind of mapping to get the ValueObject instance from the
 ActionForm instance.
 
 Example is available at
 http://www.mycgiserver.com/~andrej/technical/struts/struts.jsp
 
 Here usage of 
 vo = FormToVOMapper.map(form, new ExampleVO()); 
 is shown.
 
 Please suggest me whether this is good to use such mapping to get the
 valueobject instance and also do they support all possible 
 datatypes and
 different mappings.
 
 Thanks.
 
 -Original Message-
 From: Kalra, Ashwani [mailto:[EMAIL PROTECTED] 
 Sent: Friday, August 01, 2003 10:57 AM
 To: 'Struts Users Mailing List'
 Subject: RE: Direct ValueObject creation rather than ActionForm.
 
 One drawback. ActionForm classes import classes from http packages.
 which
 binds it to the particular layer. 
 
 Cheers
 Ashwani Kalra
 http://www.geocities.com/ashwani_kalra/
 
 
  -Original Message-
  From: Andrew Hill [mailto:[EMAIL PROTECTED]
  Sent: Friday, August 01, 2003 10:47 AM
  To: Struts Users Mailing List
  Subject: RE: Direct ValueObject creation rather than ActionForm.
  
  
  This is quite a common idea that many people new to struts 
  have. There are
  quite a few reasons why your ActionForm and your value object 
  are different
  objects. (Indeed the very reason ActionForm is implemented as 
  a class rather
  than an interface is specifically to discourage people from 
  using their
  ActionForm as a value object.) If you search the list 
  archives you will see
  numerous threads discussing the reasons why this is in fact a 
  very bad idea
  indeed.
-Original Message-
From: Viral_Thakkar [mailto:[EMAIL PROTECTED]
Sent: Friday, 1 August 2003 13:05
To: [EMAIL PROTECTED]
Subject: Direct ValueObject creation rather than ActionForm.
  
  
I have a idea here. Why we require ActionForm class if we can have
  ValueObject and that we can pass to the service layer.
  
  
  
Can we create the instance of ValueObject class only rather than
  ActionForm instance from the request data?
  
  
  
Thanks
  
  
  
  
  
  
 
 
 This message contains information that may be privileged or 
 confidential
 and
 is the property of the Cap Gemini Ernst  Young Group. It is intended
 only
 for the person to whom it is addressed. If you are not the intended
 recipient, you are not authorised to read, print, retain, copy,
 disseminate,
 distribute, or use this message or any part thereof. If you 
 receive this
 message in error, please notify the sender immediately and delete all
 copies
 of this message.
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


This message contains information that may be privileged or confidential and
is the property of the Cap Gemini Ernst  Young Group. It is intended only
for the person to whom it is addressed. If you are not the intended
recipient, you are not authorised to read, print, retain, copy, disseminate,
distribute, or use this message or any part thereof. If you receive this
message in error, please notify the sender immediately and delete all copies
of this message.

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



RE: How to rename file in FormFile in struts 1.1 final release

2003-08-01 Thread Andrew Hill
Yeh. In my case I wasnt event going that far, just jumping from a beta to a
final of 1.1

What bugs me though is that the method is still there and not deprecated.
The first I knew that there was a problem was when QA defected me for the
UnsupportedOperationException that gets thrown :-(

-Original Message-
From: Yansheng Lin [mailto:[EMAIL PROTECTED]
Sent: Thursday, 31 July 2003 23:01
To: 'Struts Users Mailing List'; [EMAIL PROTECTED]
Subject: RE: How to rename file in FormFile in struts 1.1 final release



Same thing happened to me too.  There is going to be a lot of debugging for
people used this function in 1.0.2 and want to switch to 1.1:).


-Original Message-
From: Andrew Hill [mailto:[EMAIL PROTECTED]
Sent: July 31, 2003 6:08 AM
To: Struts
Subject: How to rename file in FormFile in struts 1.1 final release


Whats the deal with
org.apache.struts.upload.CommonsMultipartRequestHandler.CommonsFormFile
being immutable?

Its broken my (production) code that was working with struts 1.1 b1 and
relied on using setFileName() :-(

What is the rationale for the FormFile interface still having these methods
when the standard implementation does not support them?


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


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



Re: Logical Server Name

2003-08-01 Thread Chirag Mehta
I cannot do that though because the port and the physical server is resolved
automatically from the interface file.

Any more suggestions?

Thanks for help anyway

Chirag

Jimmy Emmanual wrote:

 try adding the port # and a database name.

 set-property property=url value=jdbc:sybase:Tds:LNT_MAST:4100/testdb/

 -Original Message-
 From: Chirag Mehta [mailto:[EMAIL PROTECTED]
 Sent: Thursday, July 31, 2003 1:40 PM
 To: struts-user
 Subject: Logical Server Name

 Hello,

 Can anyone help?

 I am using a BasicDataSource config in my config.xml file to reference a
 sybase database. Using a logical server name, the code gives me a
 IOException.

 in my config.xml:
 set-property property=url value=jdbc:sybase:Tds:LNT_MAST/
 exception::
 javax.servlet.ServletException: java.sql.SQLException: JZ003: Incorrect
 URL format. URL: LNT_MAST

 But if I use the physical server name I have no problems setting up the
 DB Connection. (Well I haven't got any exceptions so far)

 Has anyone got any idea of any code I may have to change for my app to
 resolve from the logical server name? (The logical server name resolves
 from a interface file which is on my network server)

 Thanks a million

 Chirag
 --
 NOTICE: If received in error, please destroy and notify sender.  Sender
 does not waive confidentiality or privilege, and use is prohibited.

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

--
NOTICE: If received in error, please destroy and notify sender.  Sender does
not waive confidentiality or privilege, and use is prohibited.


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

RE: Dynamic Tree Menus --- HELP!!!

2003-08-01 Thread Pat Quinn
Thanks for you effort in resolving this issue its working perfectly now.

It might be a good idea to include the changes i've made to the 
DisplayMenuTag class i.e.

in the doStartTag() method after we fetch the menu from the repository we 
could add the following:

/* If no menu was found in the repository*/
   if ( menu == null ) {
   /*check Request for menu component*/
   menu = (MenuComponent) 
this.pageContext.getRequest().getAttribute(this.name);

   /*check session for menu component*/
   if ( menu == null ) {
   menu = (MenuComponent) 
this.pageContext.getSession().getAttribute(this.name);
   }
   }

Anyways thanks again its really appreciated.

Pat



From: Raible, Matt [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: Dynamic Tree Menus --- HELP!!!
Date: Thu, 31 Jul 2003 13:21:26 -0600
Thanks Pat - I confirmed that this is a bug, and fixed it in CVS.  You can
see an example at the following URL:
http://raibledesigns.com/struts-menu/test1.jsp

Download the updated JAR at:

http://raibledesigns.com/downloads/struts-menu.jar

or build struts-menu from CVS.

HTH,

Matt

-Original Message-
From: Pat Quinn [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 9:47 AM
To: [EMAIL PROTECTED]
Subject: RE: Dynamic Tree Menus --- HELP!!!
I appreciate your kind offer my details are as follows:

I've broken it down into a very basic example once you view this the third
node will appear with a series of plus images.
---
Menu-Config.xml
---
?xml version=1.0 encoding=UTF-8 ?
MenuConfig
  Displayers
Displayer   name=ListMenu
type=com.fgm.web.menu.displayer.ListMenuDisplayer/
  /Displayers
  Menus
Menu  name=test1  title=test1  description=test width=200
   Item   name=test2   title=test2 width=200
   Item   name=test3   title=test3 width=200
Item   name=test4   title=test4 location=index.jsp
width=200/
/Item
   /Item
/Menu
  /Menus

/MenuConfig

-
JSP Code
-
%@ taglib uri=/WEB-INF/struts-menu.tld prefix=menu%
menu:useMenuDisplayer name=ListMenu
menu:displayMenu name=test1/
/menu:useMenuDisplayer
From: Raible, Matt [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Subject: RE: Dynamic Tree Menus --- HELP!!!
Date: Thu, 31 Jul 2003 09:22:04 -0600

I'm willing to help if you send me the code.  Which Displayer are you
using?

Matt

-Original Message-
From: Pat Quinn [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 9:20 AM
To: [EMAIL PROTECTED]
Subject: Re: Dynamic Tree Menus --- HELP!!!


Is anyone out there working with dynamic HTML trees at the moment (i.e.
displaying data loaded from a data base) as i'm pulling my hair out here 
at
the moment.

I downloaded the source for Struts Menu and implemented a change to allow
me

to place a java bean with my tree menu details into HttpSession rather 
than
loading it from the menu xml file. Every thing works fine until i tried 
to
add triple nested node to the tree and it totally screws up presentation
i.e. The node image is repeatedly displayed. Its not due to my changes as 
i
tested it in the latest stable version and it fails also to render with 
the
same results.

I've also taken a look into using http://www.kobrix.com/ offering but 
their
configuration requirements to integrate with struts seems abit too much 
for
my liking.




Any suggestions, or should i just go find the JavaScript i require
elsewhere

and wrap it with my own custom tag library



 From: Pat Quinn [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Subject: Dynamic Html Tree Menus - Java Beans.
 Date: Thu, 31 Jul 2003 10:22:51 +0100
 
 I'm looking for a tag library to aid the rendering of a Tree Menu using
 session/request stored objects.
 I want to included the menu data as a Java Bean in HttpSession for each
 user and then use tag libs in my JSP's. I've looked into the StrutsMenu
 Offering for Dynamic Menus but it loads menu data from an XML file.
 
 Any ideas or am i better off to develop my own custom tag lib?
 
 _
 MSN 8 helps eliminate e-mail viruses. Get 2 months FREE*.
 http://join.msn.com/?page=features/virus
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

_
The new MSN 8: advanced junk mail protection and 2 months FREE*
http://join.msn.com/?page=features/junkmail


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


Re: [OT] XForms

2003-08-01 Thread Simon Kelly
I'm just starting to use it myself. And it's a bit of a pain in the RS
really. I think that it will become a standard next year, as for use within
static sites it's an extremely easy thing to use. (The wizard can knock up a
form page in about 2 minutes, and saves a boat load of typing)

However, if like me, your forms are dynamic, it can be a bit of a sh*t to
deal with. You will need to know exactly how to generate the xform xml doc
on the fly, and this means knowing it inside out and back to front. (I'm on
my fifth or sixth read through and it's starting to make my brain hurt)

But I've read enough to know the basics, so any question drop me a line.

Cheers

Simon



- Original Message -
From: Andrew Hill [EMAIL PROTECTED]
To: Struts [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:02 AM
Subject: [OT] XForms


 Currently the app Im working on is using an xhtml front end (with struts
of
 course) but Ive been asked to look at XForms with an eye to migrating to
it
 in the future (and probably throwing in a migration to JSF while Im
there).

 Currently the XForms spec is only a candidate release with afaik very
little
 browser support, though I gather there are a number of plugins that
 implement an XForms processor.

 I'm in the process of reading through whats on the w3c site about it but
am
 still pretty clueless as to what it really implies in terms of what we
would
 do different to now. While I understand what I am reading I dont truly
grok
 it yet.

 Anyone else been looking into this and can share some pointers on what I
 need to think about?

 Is XForms really going to be the next stage in the evolution of forms on
the
 browser or is it just some hyped up hot air thats really a wild goose
chase?


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




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



Strange Problem saving and retrieving file

2003-08-01 Thread Samuel . Opoku-Boadu

In my struts application I save a text file in an oracle database.
Whenever I retrieve the file from the database, it is always 8kb smaller.
Has any one of you ever experienced this problem?

Sam

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



RE: DynaValidatorForm question

2003-08-01 Thread Jones, Marty B.
Will this still validate the request parameters when there are actually
request parameters present?

-Original Message-
From: Yansheng Lin [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 6:04 PM
To: 'Struts Users Mailing List'
Subject: RE: DynaValidatorForm question


Set validate attribute in action to false will solve your problem.

-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: July 31, 2003 3:37 PM
To: [EMAIL PROTECTED]
Subject: DynaValidatorForm question


I have a class that extends Action (LoginAction) and references a
DynaValidatorForm for form validation. I have noticed that if I directly
reference a url say http://myserver/control/login that it instantiates the
LoginAction as it should.  My question is, what is the best way to not allow
the Action class to be fired if no request arguments are on the request so
that the login.jsp file will paint to allow the user to enter usename and
password information in.  I am pretty sure that I could use a normal
ActionForm and in the validation method check to see if the username and
password values are both null.  If they are then return a mapping to go back
to the login screen.  Is there a way to do this with the DynaValidatorForm?

Thanks in advance,

Marty Jones


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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


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

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



RE: Strange Problem saving and retrieving file

2003-08-01 Thread Jones, Marty B.
Are you using a input stream to load the file in the database?  If so make
sure that you flush the stream and close it.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 4:59 AM
To: [EMAIL PROTECTED]
Subject: Strange Problem saving and retrieving file



In my struts application I save a text file in an oracle database.
Whenever I retrieve the file from the database, it is always 8kb smaller.
Has any one of you ever experienced this problem?

Sam

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

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



Using a key as an argument to bean:message

2003-08-01 Thread Paul McCulloch
Hi,

Has anyone got any ideas on how to use a message key as an argument in a
bean:message call.

e.g. bean:message key=field.lookupbutton arg0Key=customer.label/

At the moment I am using a scriptlet to access the message resources and
assign the message for the argument to a page variable. e.g.

%
org.apache.struts.util.MessageResources messages =
(org.apache.struts.util.MessageResources)request.getAttribute(org.apache.str
uts.Globals.MESSAGES_KEY);

String realLabel = messages.getMessage(customer.label);
%

bean:message key=field.lookupbutton arg0=%=realLabel%/

This works but is a bit messy. 

Note that both keys are actually dynamic and come from nested beans on the
ActionForm - I can't just create a fixed composite message in my
application.properties.

thanks,

Paul


**
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you are not 
the addressee indicated in this message (or responsible for delivery of the message to 
such person), you may not copy or deliver this message to anyone. In such case, you 
should destroy this message, and notify us immediately. If you or your employer does 
not consent to Internet email messages of this kind, please advise us immediately. 
Opinions, conclusions and other information expressed in this message are not given or 
endorsed by my Company or employer unless otherwise indicated by an authorised 
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being transmitted 
via electronic mail attachments we cannot guarantee that attachments do not contain 
computer virus code.  You are therefore strongly advised to undertake anti virus 
checks prior to accessing the attachment to this electronic mail.  Axios Systems Ltd 
grants no warranties regarding performance use or quality of any attachment and 
undertakes no liability for loss or damage howsoever caused.


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



simple - import

2003-08-01 Thread Mike Whittaker

How do you get Constants (or anything none scoped ie app/sess/req) into a
jsp for use in EL

I can do

%@ page import=com.blah.Const %

%= Const.MY_CONST %

but not

c:out value=${Const.MY_CONST}/

This probably demonstrates a fundamental none understanding!

TIA
--
Mike W


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



RE: simple - import

2003-08-01 Thread Alex Shneyderman

c:set var=yourVar%= Const.MY_CONST %/c:set

 -Original Message-
 From: Mike Whittaker [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 7:33 AM
 To: Struts List
 Subject: simple - import
 
 
 How do you get Constants (or anything none scoped ie app/sess/req)
into a
 jsp for use in EL
 
 I can do
 
 %@ page import=com.blah.Const %
 
 
 
 but not
 
  
 This probably demonstrates a fundamental none understanding!
 
 TIA
 --
 Mike W
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



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



Re: Using a key as an argument to bean:message

2003-08-01 Thread Nagendra Kumar O V S








  hi,
  u can't send the key as the argument to the bean:message, though u 
  might want to consider this
  bean:define id="realValue"  
  bean:message key="customer.label" 
  //bean:define
  bean:message key="field.lookupbutton" 
  arg0="%=realLabel%"/-- nagi
  
  ---Original Message---
  
  
  From: Struts Users Mailing 
  List
  Date: Friday, August 
  01, 2003 05:00:41 PM
  To: Struts Users Mailing List 
  (E-mail)
  Subject: Using a key as 
  an argument to bean:message
  Hi,Has anyone got any ideas on how to use a 
  message key as an argument in abean:message call.e.g. 
  bean:message key="field.lookupbutton" 
  arg0Key="customer.label"/At the moment I am using a scriptlet 
  to access the message resources andassign the message for the argument 
  to a page variable. 
  e.g.%org.apache.struts.util.MessageResources messages 
  =(org.apache.struts.util.MessageResources)request.getAttribute(org.apache.struts.Globals.MESSAGES_KEY);String 
  realLabel = 
  messages.getMessage("customer.label");%bean:message 
  key="field.lookupbutton" arg0="%=realLabel%"/This 
  works but is a bit messy. Note that both keys are actually dynamic 
  and come from nested beans on theActionForm - I can't just create a 
  fixed composite message in 
  myapplication.properties.thanks,Paul**Axios 
  Email Confidentiality FooterPrivileged/Confidential Information may be 
  contained in this message. If you are not the addressee indicated in this 
  message (or responsible for delivery of the message to such person), you 
  may not copy or deliver this message to anyone. In such case, you should 
  destroy this message, and notify us immediately. If you or your employer 
  does not consent to Internet email messages of this kind, please advise us 
  immediately. Opinions, conclusions and other information expressed in this 
  message are not given or endorsed by my Company or employer unless 
  otherwise indicated by an authorised representative independent of this 
  message.WARNING:While Axios Systems Ltd takes steps to prevent 
  computer viruses from being transmitted via electronic mail attachments we 
  cannot guarantee that attachments do not contain computer virus code. You 
  are therefore strongly advised to undertake anti virus checks prior to 
  accessing the attachment to this electronic mail. Axios Systems Ltd grants 
  no warranties regarding performance use or quality of any attachment and 
  undertakes no liability for loss or damage howsoever 
  caused.-To 
  unsubscribe, e-mail: [EMAIL PROTECTED]For 
  additional commands, e-mail: [EMAIL PROTECTED].





	
	
	
	
	
	
	




 IncrediMail - 
Email has finally evolved - Click 
Here



RE: simple - import

2003-08-01 Thread Mike Whittaker


c:set var=yourVar%= Const.MY_CONST %/c:set


Good grief is this the only way?

a/ isn't the aim to do without scriptlets/expressions?

b/ all the data exists, server side in the app, why do I have to jump
through hoops, copying CONSTANTS over to another variable???

:-(

--
Mike W


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



RE: Using a key as an argument to bean:message

2003-08-01 Thread Paul McCulloch
Thansk - that's ceryainly a lot neater. I keep forgetting that lots of tags
can have stuff defined in their body - I always seem to look at example
which have no body.
 
cheers,
 
Paul

-Original Message-
From: Nagendra Kumar O V S [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 12:47
To: [EMAIL PROTECTED]
Subject: Re: Using a key as an argument to bean:message



hi,
u can't send the key as the argument to the bean:message, though u might
want to consider this
bean:define id=realValue 
bean:message key=customer.label /
 /bean:define
bean:message key=field.lookupbutton arg0=%=realLabel%/

-- nagi

 
---Original Message---
 
From: Struts Users Mailing  mailto:[EMAIL PROTECTED] List
Date: Friday, August 01, 2003 05:00:41 PM
To: Struts Users Mailing List  mailto:[EMAIL PROTECTED]
(E-mail)
Subject: Using a key as an argument to bean:message
 
Hi,

Has anyone got any ideas on how to use a message key as an argument in a
bean:message call.

e.g. bean:message key=field.lookupbutton arg0Key=customer.label/

At the moment I am using a scriptlet to access the message resources and
assign the message for the argument to a page variable. e.g.

%
org.apache.struts.util.MessageResources messages =
(org.apache.struts.util.MessageResources)request.getAttribute(org.apache.str
uts.Globals.MESSAGES_KEY);

String realLabel = messages.getMessage(customer.label);
%

bean:message key=field.lookupbutton arg0=%=realLabel%/

This works but is a bit messy. 

Note that both keys are actually dynamic and come from nested beans on the
ActionForm - I can't just create a fixed composite message in my
application.properties.

thanks,

Paul


**
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you
are not the addressee indicated in this message (or responsible for delivery
of the message to such person), you may not copy or deliver this message to
anyone. In such case, you should destroy this message, and notify us
immediately. If you or your employer does not consent to Internet email
messages of this kind, please advise us immediately. Opinions, conclusions
and other information expressed in this message are not given or endorsed by
my Company or employer unless otherwise indicated by an authorised
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being
transmitted via electronic mail attachments we cannot guarantee that
attachments do not contain computer virus code. You are therefore strongly
advised to undertake anti virus checks prior to accessing the attachment to
this electronic mail. Axios Systems Ltd grants no warranties regarding
performance use or quality of any attachment and undertakes no liability for
loss or damage howsoever caused.


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


.



 http://www.incredimail.com/redir.asp?ad_id=309lang=9   IncrediMail -
Email has finally evolved -
http://www.incredimail.com/redir.asp?ad_id=309lang=9 Click Here 



RE: DynaValidatorForm question

2003-08-01 Thread Jones, Marty B.
I think that I may be missing something here.  When using struts, how do you
load say a html form (using a jsp file) to the user initially without having
the Action class actually being processed and then being forwarded to the
view?  I defintely want to use the Validator class but I only want it to
validate when the user has actually submitted a form with request parameters
to that given action.

Marty

-Original Message-
From: Jones, Marty B. 
Sent: Friday, August 01, 2003 6:09 AM
To: Struts Users Mailing List
Subject: RE: DynaValidatorForm question


Will this still validate the request parameters when there are actually
request parameters present?

-Original Message-
From: Yansheng Lin [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 6:04 PM
To: 'Struts Users Mailing List'
Subject: RE: DynaValidatorForm question


Set validate attribute in action to false will solve your problem.

-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: July 31, 2003 3:37 PM
To: [EMAIL PROTECTED]
Subject: DynaValidatorForm question


I have a class that extends Action (LoginAction) and references a
DynaValidatorForm for form validation. I have noticed that if I directly
reference a url say http://myserver/control/login that it instantiates the
LoginAction as it should.  My question is, what is the best way to not allow
the Action class to be fired if no request arguments are on the request so
that the login.jsp file will paint to allow the user to enter usename and
password information in.  I am pretty sure that I could use a normal
ActionForm and in the validation method check to see if the username and
password values are both null.  If they are then return a mapping to go back
to the login screen.  Is there a way to do this with the DynaValidatorForm?

Thanks in advance,

Marty Jones


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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


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

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

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



Re: OT - Struts w/EJB

2003-08-01 Thread James Mitchell
Not sure.  I'm in this for the money ;)

--
James Mitchell
Software Developer/Struts Evangelist
http://www.struts-atlanta.org
678-910-8017
AIM:jmitchtx


- Original Message - 
From: message message [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 1:48 AM
Subject: Re: OT - Struts w/EJB




 How come there is so much free ware available especially from sourceforge
?


 From: James Mitchell [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Subject: Re: Struts w/EJB
 Date: Fri, 1 Aug 2003 00:38:17 -0400
 
 Download modelj from sourceforge and try it.  Supply the path to your
 j2ee.jar and build the sample app in 2 minutes.  Modelj will create a
 struts/ejb application for you from one single config file.  Using JBoss,
 all you have to do is setup a default data source and deploy your
 sample.ear.
 
 http://sourceforge.net/projects/modelj
 
 
 --
 James Mitchell
 Software Developer/Struts Evangelist
 http://www.struts-atlanta.org
 678-910-8017
 AIM:jmitchtx
 
 
 - Original Message -
 From: Martin Naskovski [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED]
 Sent: Thursday, July 31, 2003 7:01 PM
 Subject: Struts w/EJB
 
 
   Hello all. Is there an app that demonstrates the use of Struts  EJB
as
 a
   persistence layer? I checked out Struts-Resume from Matt Raible, but
it
   uses Hibernate... Is there anything available w/EJB's? Thanks.
  
   Martin
   --
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 

 _
 STOP MORE SPAM with the new MSN 8 and get 2 months FREE*
 http://join.msn.com/?page=features/junkmail


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


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



Creating JSP's with struts.

2003-08-01 Thread Carlos Urtasun
Hi all.

We are a team that develop an online application using struts.

Inside the team exists two groups: the software developers and the interface
designers.
Our designers needs to give expression to the interface accross the JSP's
and we want use a WYSIWYG tool.

Can you give me a clue or guideline to make easier the work to the interface
designers? The tools like Exadel Struts Studio or Metanology MDE are good
for this goal?

Regards,

Carlos Urtasun


Carlos Urtasun, E-mail: [EMAIL PROTECTED]
mailto:[EMAIL PROTECTED]
Editorial Aranzadi: www.aranzadi.es http://www.aranzadi.es
Dpto. Informática - Área Online
Camino de Galar, 15
31190- Cizur Menor - SPAIN
Tlfno.: +34 948 297297  Fax: +34 948 297200
__
Este e-mail y cualquier documento anexo contienen información privada y
confidencial única y exclusivamente para el destinatario. Si usted no es el
destinatario, no tiene autorización para leer, copiar, usar o distribuir el
e-mail y el/los documento anexos. En caso de haber recibido esta
comunicación por error, le rogamos que lo remita al emisor y lo destruya
posteriormente.
This e-mail and any attachment contain information, which is private and
confidential and is intended for the addressee only. If you are not an
addressee, you are not authorized to read, copy, use or distribute this
communication. If you have received this e-mail in error, please notify the
sender by return e-mail.




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





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



RE: Using a key as an argument to bean:message

2003-08-01 Thread Krishnakumar N
If you can use jstl, you can also try

fmt:message key=field.lookupbutton
fmt:param
fmt:message key=customer.label/
/fmt:param
/fmt:message

Cheers,
Krishna


-Original Message-
From: Paul McCulloch [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 5:16 PM
To: 'Struts Users Mailing List'
Subject: RE: Using a key as an argument to bean:message


Thansk - that's ceryainly a lot neater. I keep forgetting that lots of tags
can have stuff defined in their body - I always seem to look at example
which have no body.
 
cheers,
 
Paul

-Original Message-
From: Nagendra Kumar O V S [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 12:47
To: [EMAIL PROTECTED]
Subject: Re: Using a key as an argument to bean:message



hi,
u can't send the key as the argument to the bean:message, though u might
want to consider this
bean:define id=realValue 
bean:message key=customer.label /
 /bean:define
bean:message key=field.lookupbutton arg0=%=realLabel%/

-- nagi

 
---Original Message---
 
From: Struts Users Mailing  mailto:[EMAIL PROTECTED] List
Date: Friday, August 01, 2003 05:00:41 PM
To: Struts Users Mailing List  mailto:[EMAIL PROTECTED]
(E-mail)
Subject: Using a key as an argument to bean:message
 
Hi,

Has anyone got any ideas on how to use a message key as an argument in a
bean:message call.

e.g. bean:message key=field.lookupbutton arg0Key=customer.label/

At the moment I am using a scriptlet to access the message resources and
assign the message for the argument to a page variable. e.g.

%
org.apache.struts.util.MessageResources messages =
(org.apache.struts.util.MessageResources)request.getAttribute(org.apache.str
uts.Globals.MESSAGES_KEY);

String realLabel = messages.getMessage(customer.label);
%

bean:message key=field.lookupbutton arg0=%=realLabel%/

This works but is a bit messy. 

Note that both keys are actually dynamic and come from nested beans on the
ActionForm - I can't just create a fixed composite message in my
application.properties.

thanks,

Paul


**
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you
are not the addressee indicated in this message (or responsible for delivery
of the message to such person), you may not copy or deliver this message to
anyone. In such case, you should destroy this message, and notify us
immediately. If you or your employer does not consent to Internet email
messages of this kind, please advise us immediately. Opinions, conclusions
and other information expressed in this message are not given or endorsed by
my Company or employer unless otherwise indicated by an authorised
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being
transmitted via electronic mail attachments we cannot guarantee that
attachments do not contain computer virus code. You are therefore strongly
advised to undertake anti virus checks prior to accessing the attachment to
this electronic mail. Axios Systems Ltd grants no warranties regarding
performance use or quality of any attachment and undertakes no liability for
loss or damage howsoever caused.


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


.



 http://www.incredimail.com/redir.asp?ad_id=309lang=9   IncrediMail -
Email has finally evolved -
http://www.incredimail.com/redir.asp?ad_id=309lang=9 Click Here 


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



RE: Using a key as an argument to bean:message

2003-08-01 Thread Paul McCulloch
Having a look at JSTL is on my todo list:-)

-Original Message-
From: Krishnakumar N [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 13:10
To: Struts Users Mailing List
Subject: RE: Using a key as an argument to bean:message


If you can use jstl, you can also try

fmt:message key=field.lookupbutton
fmt:param
fmt:message key=customer.label/
/fmt:param
/fmt:message

Cheers,
Krishna


-Original Message-
From: Paul McCulloch [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 5:16 PM
To: 'Struts Users Mailing List'
Subject: RE: Using a key as an argument to bean:message


Thansk - that's ceryainly a lot neater. I keep forgetting that lots of tags
can have stuff defined in their body - I always seem to look at example
which have no body.
 
cheers,
 
Paul

-Original Message-
From: Nagendra Kumar O V S [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 12:47
To: [EMAIL PROTECTED]
Subject: Re: Using a key as an argument to bean:message



hi,
u can't send the key as the argument to the bean:message, though u might
want to consider this
bean:define id=realValue 
bean:message key=customer.label /
 /bean:define
bean:message key=field.lookupbutton arg0=%=realLabel%/

-- nagi

 
---Original Message---
 
From: Struts Users Mailing  mailto:[EMAIL PROTECTED] List
Date: Friday, August 01, 2003 05:00:41 PM
To: Struts Users Mailing List  mailto:[EMAIL PROTECTED]
(E-mail)
Subject: Using a key as an argument to bean:message
 
Hi,

Has anyone got any ideas on how to use a message key as an argument in a
bean:message call.

e.g. bean:message key=field.lookupbutton arg0Key=customer.label/

At the moment I am using a scriptlet to access the message resources and
assign the message for the argument to a page variable. e.g.

%
org.apache.struts.util.MessageResources messages =
(org.apache.struts.util.MessageResources)request.getAttribute(org.apache.str
uts.Globals.MESSAGES_KEY);

String realLabel = messages.getMessage(customer.label);
%

bean:message key=field.lookupbutton arg0=%=realLabel%/

This works but is a bit messy. 

Note that both keys are actually dynamic and come from nested beans on the
ActionForm - I can't just create a fixed composite message in my
application.properties.

thanks,

Paul


**
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you
are not the addressee indicated in this message (or responsible for delivery
of the message to such person), you may not copy or deliver this message to
anyone. In such case, you should destroy this message, and notify us
immediately. If you or your employer does not consent to Internet email
messages of this kind, please advise us immediately. Opinions, conclusions
and other information expressed in this message are not given or endorsed by
my Company or employer unless otherwise indicated by an authorised
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being
transmitted via electronic mail attachments we cannot guarantee that
attachments do not contain computer virus code. You are therefore strongly
advised to undertake anti virus checks prior to accessing the attachment to
this electronic mail. Axios Systems Ltd grants no warranties regarding
performance use or quality of any attachment and undertakes no liability for
loss or damage howsoever caused.


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


.



 http://www.incredimail.com/redir.asp?ad_id=309lang=9   IncrediMail -
Email has finally evolved -
http://www.incredimail.com/redir.asp?ad_id=309lang=9 Click Here 


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

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



Re: simple - import

2003-08-01 Thread James Mitchell
Easy way:

You can always use the unstandard tags.  Works great for me:

un:bind type=com.company.project.Const field=SOME_CONST var=yourVar/
c:if test=${$yourVar == 'some value'}
 c:out value=${yourVar}/
/c:if


Not so easy way:
---
(by Kris Schneider on taglib-users)

Put something like this in a startup servlet or a plug-in:

public static Map getConstantFieldsAsMap(Class cls)
  throws IllegalAccessException {
Field[] allFields = cls.getDeclaredFields();
int numFields = allFields.length;
Map propMap = new HashMap(numFields);
for (int i = 0; i  numFields; i++) {
Field f = allFields[i];
int mods = f.getModifiers();
if (Modifier.isPublic(mods) 
Modifier.isStatic(mods) 
Modifier.isFinal(mods)) {
String name = f.getName();
Object value = f.get(null);
propMap.put(name, value);
}
}
return Collections.unmodifiableMap(propMap);
}

In JSP:

c:set var=responseMap

value=${applicationScope['javax.servlet.http.HttpServletResponse']}/
SC_NOT_FOUND: c:out value=${responseMap.SC_NOT_FOUND}/


Search the archives on taglib-user for more details.


--
James Mitchell
Software Developer/Struts Evangelist
http://www.struts-atlanta.org
678-910-8017
AIM:jmitchtx


- Original Message - 
From: Mike Whittaker [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 7:46 AM
Subject: RE: simple - import



 
 c:set var=yourVar%= Const.MY_CONST %/c:set
 

 Good grief is this the only way?

 a/ isn't the aim to do without scriptlets/expressions?

 b/ all the data exists, server side in the app, why do I have to jump
 through hoops, copying CONSTANTS over to another variable???

 :-(

 --
 Mike W


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


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



Formbean Scope

2003-08-01 Thread Goldy J
Hello,
I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated with some 
values that I set in action class associated with  JSP1. I am using the same formbean 
for both JSP 1 and JSP 2. I set the value that I need in JSP2 in Action class1 and I 
can see they are getting set in the formbean. But when JSP2 open the get method shows 
value as null.  In action mapping the scope is session.
I suppose that Iam losing the formbean when the JSP2 opens ..is there a way out ?
Pls. help
 
Thanks


-
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!

AW: Strange Problem saving and retrieving file

2003-08-01 Thread Samuel . Opoku-Boadu
Thanks. I have solved the problem. I was calling a BufferReaeder.readLine() method 
earlier before
loading the InputStream in the database.

Cheers!!!

-Ursprungliche Nachricht-
Von: Jones, Marty B. [mailto:[EMAIL PROTECTED]
Gesendet: Freitag, 1. August 2003 13:10
An: Struts Users Mailing List
Betreff: RE: Strange Problem saving and retrieving file


Are you using a input stream to load the file in the database?  If so make
sure that you flush the stream and close it.

-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 4:59 AM
To: [EMAIL PROTECTED]
Subject: Strange Problem saving and retrieving file



In my struts application I save a text file in an oracle database.
Whenever I retrieve the file from the database, it is always 8kb smaller.
Has any one of you ever experienced this problem?

Sam

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

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

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



Re: OT - Struts w/EJB

2003-08-01 Thread Alen Ribic
If one is to start another OSS project, what would it be? ;)
I think there isn't one idea that hasn't been thought of and put into open
source now days.

But like James, I'm in it for the money too. What can I say, Love
programming and of course $.

--Alen



- Original Message -
From: James Mitchell [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 1:52 PM
Subject: Re: OT - Struts w/EJB


 Not sure.  I'm in this for the money ;)

 --
 James Mitchell
 Software Developer/Struts Evangelist
 http://www.struts-atlanta.org
 678-910-8017
 AIM:jmitchtx


 - Original Message -
 From: message message [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 1:48 AM
 Subject: Re: OT - Struts w/EJB


 
 
  How come there is so much free ware available especially from
sourceforge
 ?
 
 
  From: James Mitchell [EMAIL PROTECTED]
  Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
  To: Struts Users Mailing List [EMAIL PROTECTED]
  Subject: Re: Struts w/EJB
  Date: Fri, 1 Aug 2003 00:38:17 -0400
  
  Download modelj from sourceforge and try it.  Supply the path to your
  j2ee.jar and build the sample app in 2 minutes.  Modelj will create a
  struts/ejb application for you from one single config file.  Using
JBoss,
  all you have to do is setup a default data source and deploy your
  sample.ear.
  
  http://sourceforge.net/projects/modelj
  
  
  --
  James Mitchell
  Software Developer/Struts Evangelist
  http://www.struts-atlanta.org
  678-910-8017
  AIM:jmitchtx
  
  
  - Original Message -
  From: Martin Naskovski [EMAIL PROTECTED]
  To: Struts Users Mailing List [EMAIL PROTECTED]
  Sent: Thursday, July 31, 2003 7:01 PM
  Subject: Struts w/EJB
  
  
Hello all. Is there an app that demonstrates the use of Struts  EJB
 as
  a
persistence layer? I checked out Struts-Resume from Matt Raible, but
 it
uses Hibernate... Is there anything available w/EJB's? Thanks.
   
Martin
--
   
   
  
 -
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
  
  
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
  
 
  _
  STOP MORE SPAM with the new MSN 8 and get 2 months FREE*
  http://join.msn.com/?page=features/junkmail
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]


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



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



RE: DynaValidatorForm question

2003-08-01 Thread Mainguy, Mike
My gut reaction would be to use a depends=required on both fields.  This
should give you the behavior you desire.  

-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 31, 2003 5:37 PM
To: [EMAIL PROTECTED]
Subject: DynaValidatorForm question

I have a class that extends Action (LoginAction) and references a
DynaValidatorForm for form validation. I have noticed that if I directly
reference a url say http://myserver/control/login that it instantiates the
LoginAction as it should.  My question is, what is the best way to not allow
the Action class to be fired if no request arguments are on the request so
that the login.jsp file will paint to allow the user to enter usename and
password information in.  I am pretty sure that I could use a normal
ActionForm and in the validation method check to see if the username and
password values are both null.  If they are then return a mapping to go back
to the login screen.  Is there a way to do this with the DynaValidatorForm?

Thanks in advance,

Marty Jones


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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


This message and its contents (to include attachments) are the property of Kmart 
Corporation (Kmart) and may contain confidential and proprietary information. You are 
hereby notified that any disclosure, copying, or distribution of this message, or the 
taking of any action based on information contained herein is strictly prohibited. 
Unauthorized use of information contained herein may subject you to civil and criminal 
prosecution and penalties. If you are not the intended recipient, you should delete 
this message immediately.




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



RE: DynaValidatorForm question

2003-08-01 Thread Jones, Marty B.
I currently have that setting that you mentioned.  That is exactly the
problem that I am seeing.  If a user goes directly to the /login url.  The
LoginAction is being instatiated and the validator trys to validate
parameters that the user never had a chance to enter.

-Original Message-
From: Mainguy, Mike [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 7:46 AM
To: 'Struts Users Mailing List'
Subject: RE: DynaValidatorForm question


My gut reaction would be to use a depends=required on both fields.  This
should give you the behavior you desire.  

-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: Thursday, July 31, 2003 5:37 PM
To: [EMAIL PROTECTED]
Subject: DynaValidatorForm question

I have a class that extends Action (LoginAction) and references a
DynaValidatorForm for form validation. I have noticed that if I directly
reference a url say http://myserver/control/login that it instantiates the
LoginAction as it should.  My question is, what is the best way to not allow
the Action class to be fired if no request arguments are on the request so
that the login.jsp file will paint to allow the user to enter usename and
password information in.  I am pretty sure that I could use a normal
ActionForm and in the validation method check to see if the username and
password values are both null.  If they are then return a mapping to go back
to the login screen.  Is there a way to do this with the DynaValidatorForm?

Thanks in advance,

Marty Jones


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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


This message and its contents (to include attachments) are the property of
Kmart Corporation (Kmart) and may contain confidential and proprietary
information. You are hereby notified that any disclosure, copying, or
distribution of this message, or the taking of any action based on
information contained herein is strictly prohibited. Unauthorized use of
information contained herein may subject you to civil and criminal
prosecution and penalties. If you are not the intended recipient, you should
delete this message immediately.




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

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



Re: Formbean Scope

2003-08-01 Thread David Chelimsky
Try overriding reset() such that it doesn't do anything. Otherwise, the
reset() method in ActionForm will set all primitives to their defaults and
all objects to null.


- Original Message -
From: Goldy J [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 7:20 AM
Subject: Formbean Scope


 Hello,
 I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
with some values that I set in action class associated with  JSP1. I am
using the same formbean for both JSP 1 and JSP 2. I set the value that I
need in JSP2 in Action class1 and I can see they are getting set in the
formbean. But when JSP2 open the get method shows value as null.  In action
mapping the scope is session.
 I suppose that Iam losing the formbean when the JSP2 opens ..is there a
way out ?
 Pls. help

 Thanks


 -
 Do you Yahoo!?
 SBC Yahoo! DSL - Now only $29.95 per month!


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



RE: DynaValidatorForm question

2003-08-01 Thread Alex Shneyderman
I think the easiest way is to actually set validate to false on your
action and do it manually first thing in your execute:

// check for null values if there are just display the page otherwise

ActionErrors errors = yourForm.validate (...);
If (!errors.isEmpty ()) { return input mapping }

// everything is ok




 -Original Message-
 From: Jones, Marty B. [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 8:55 AM
 To: Struts Users Mailing List
 Subject: RE: DynaValidatorForm question
 
 I currently have that setting that you mentioned.  That is exactly the
 problem that I am seeing.  If a user goes directly to the /login url.
The
 LoginAction is being instatiated and the validator trys to validate
 parameters that the user never had a chance to enter.
 
 -Original Message-
 From: Mainguy, Mike [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 7:46 AM
 To: 'Struts Users Mailing List'
 Subject: RE: DynaValidatorForm question
 
 
 My gut reaction would be to use a depends=required on both fields.
This
 should give you the behavior you desire.
 
 -Original Message-
 From: Jones, Marty B. [mailto:[EMAIL PROTECTED]
 Sent: Thursday, July 31, 2003 5:37 PM
 To: [EMAIL PROTECTED]
 Subject: DynaValidatorForm question
 
 I have a class that extends Action (LoginAction) and references a
 DynaValidatorForm for form validation. I have noticed that if I
directly
 reference a url say http://myserver/control/login that it instantiates
the
 LoginAction as it should.  My question is, what is the best way to not
 allow
 the Action class to be fired if no request arguments are on the
request so
 that the login.jsp file will paint to allow the user to enter usename
and
 password information in.  I am pretty sure that I could use a normal
 ActionForm and in the validation method check to see if the username
and
 password values are both null.  If they are then return a mapping to
go
 back
 to the login screen.  Is there a way to do this with the
 DynaValidatorForm?
 
 Thanks in advance,
 
 Marty Jones
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 This message and its contents (to include attachments) are the
property of
 Kmart Corporation (Kmart) and may contain confidential and proprietary
 information. You are hereby notified that any disclosure, copying, or
 distribution of this message, or the taking of any action based on
 information contained herein is strictly prohibited. Unauthorized use
of
 information contained herein may subject you to civil and criminal
 prosecution and penalties. If you are not the intended recipient, you
 should
 delete this message immediately.
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



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



RE: [OT] XForms

2003-08-01 Thread Mike Jasnowski
Is XForms really going to be the next stage in the evolution of forms on
the
browser or is it just some hyped up hot air thats really a wild goose
chase?

IMHO it's hard to say, XForms has been perculating for along time. I think
if you speak to some vendors (Like Novell) they think so. But in reality,
there are some assumptions being made by these vendors that may make it
difficult for XForms to really proliferate. Such as native support for
XForms. As you mentioned there are few clients that natively support XForms,
and those that do use a plugin. Now you might argue that using a plugin is
good enough, until you have to start managing plugins, plugin verions, etc..
then you have different platforms for the plugin (applets anyone?).  It also
assumes that you (and your app) live in mostly an XML world. Which is not
the case for many, and those that do may not be doing so natively (I.e.
exposing relational data via XML as opposed to an XML database).

And if XForms becomes natively supported, let's hope all vendors choose to
support the same,full spec the same way. (HTML, CSS, CSSP ???).

Frankly I think you can accomplish similar things with existing technologies
and practices.

HTH,
Mike j

-Original Message-
From: Andrew Hill [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 2:03 AM
To: Struts
Subject: [OT] XForms


Currently the app Im working on is using an xhtml front end (with struts of
course) but Ive been asked to look at XForms with an eye to migrating to it
in the future (and probably throwing in a migration to JSF while Im there).

Currently the XForms spec is only a candidate release with afaik very little
browser support, though I gather there are a number of plugins that
implement an XForms processor.

I'm in the process of reading through whats on the w3c site about it but am
still pretty clueless as to what it really implies in terms of what we would
do different to now. While I understand what I am reading I dont truly grok
it yet.

Anyone else been looking into this and can share some pointers on what I
need to think about?

Is XForms really going to be the next stage in the evolution of forms on the
browser or is it just some hyped up hot air thats really a wild goose chase?


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



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



RE: DynaValidatorForm question

2003-08-01 Thread Jones, Marty B.
That is what I figured.

Thanks for your help.

-Original Message-
From: Alex Shneyderman [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:01 AM
To: 'Struts Users Mailing List'
Subject: RE: DynaValidatorForm question


I think the easiest way is to actually set validate to false on your
action and do it manually first thing in your execute:

// check for null values if there are just display the page otherwise

ActionErrors errors = yourForm.validate (...);
If (!errors.isEmpty ()) { return input mapping }

// everything is ok




 -Original Message-
 From: Jones, Marty B. [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 8:55 AM
 To: Struts Users Mailing List
 Subject: RE: DynaValidatorForm question
 
 I currently have that setting that you mentioned.  That is exactly the
 problem that I am seeing.  If a user goes directly to the /login url.
The
 LoginAction is being instatiated and the validator trys to validate
 parameters that the user never had a chance to enter.
 
 -Original Message-
 From: Mainguy, Mike [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 7:46 AM
 To: 'Struts Users Mailing List'
 Subject: RE: DynaValidatorForm question
 
 
 My gut reaction would be to use a depends=required on both fields.
This
 should give you the behavior you desire.
 
 -Original Message-
 From: Jones, Marty B. [mailto:[EMAIL PROTECTED]
 Sent: Thursday, July 31, 2003 5:37 PM
 To: [EMAIL PROTECTED]
 Subject: DynaValidatorForm question
 
 I have a class that extends Action (LoginAction) and references a
 DynaValidatorForm for form validation. I have noticed that if I
directly
 reference a url say http://myserver/control/login that it instantiates
the
 LoginAction as it should.  My question is, what is the best way to not
 allow
 the Action class to be fired if no request arguments are on the
request so
 that the login.jsp file will paint to allow the user to enter usename
and
 password information in.  I am pretty sure that I could use a normal
 ActionForm and in the validation method check to see if the username
and
 password values are both null.  If they are then return a mapping to
go
 back
 to the login screen.  Is there a way to do this with the
 DynaValidatorForm?
 
 Thanks in advance,
 
 Marty Jones
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 This message and its contents (to include attachments) are the
property of
 Kmart Corporation (Kmart) and may contain confidential and proprietary
 information. You are hereby notified that any disclosure, copying, or
 distribution of this message, or the taking of any action based on
 information contained herein is strictly prohibited. Unauthorized use
of
 information contained herein may subject you to civil and criminal
 prosecution and penalties. If you are not the intended recipient, you
 should
 delete this message immediately.
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]



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

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



Re: simple - import

2003-08-01 Thread David Chelimsky
JSTL won't handle static methods. If you add a method to your Const class
that returns a Const instance (ideally a singleton so you don't keep
creating these), you can keep a Const on your ActionForm bean and set it in
your ActionForm. Then your JSP would look like this:

c:out value=${myForm.const.myVar}/

and you wouldn't even need the import statement.

- Original Message -
From: Alex Shneyderman [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 6:34 AM
Subject: RE: simple - import



 c:set var=yourVar%= Const.MY_CONST %/c:set

  -Original Message-
  From: Mike Whittaker [mailto:[EMAIL PROTECTED]
  Sent: Friday, August 01, 2003 7:33 AM
  To: Struts List
  Subject: simple - import
 
 
  How do you get Constants (or anything none scoped ie app/sess/req)
 into a
  jsp for use in EL
 
  I can do
 
  %@ page import=com.blah.Const %
 
 
 
  but not
 
  
  This probably demonstrates a fundamental none understanding!
 
  TIA
  --
  Mike W
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]



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





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



Re: simple - import

2003-08-01 Thread David Chelimsky
Alternatively, you could load this into session or application scopes and do
this:

c:out value=${sessionScope.constants.myVal}
or
c:out value=${applicationScope.constants.myVal}
- Original Message -
From: David Chelimsky [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:12 AM
Subject: Re: simple - import


 JSTL won't handle static methods. If you add a method to your Const class
 that returns a Const instance (ideally a singleton so you don't keep
 creating these), you can keep a Const on your ActionForm bean and set it
in
 your ActionForm. Then your JSP would look like this:

 c:out value=${myForm.const.myVar}/

 and you wouldn't even need the import statement.

 - Original Message -
 From: Alex Shneyderman [EMAIL PROTECTED]
 To: 'Struts Users Mailing List' [EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 6:34 AM
 Subject: RE: simple - import


 
  c:set var=yourVar%= Const.MY_CONST %/c:set
 
   -Original Message-
   From: Mike Whittaker [mailto:[EMAIL PROTECTED]
   Sent: Friday, August 01, 2003 7:33 AM
   To: Struts List
   Subject: simple - import
  
  
   How do you get Constants (or anything none scoped ie app/sess/req)
  into a
   jsp for use in EL
  
   I can do
  
   %@ page import=com.blah.Const %
  
  
  
   but not
  
   
   This probably demonstrates a fundamental none understanding!
  
   TIA
   --
   Mike W
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 


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





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



Re: Formbean Scope

2003-08-01 Thread Goldy J
Thanks a lot David for the prompt reply . Iam actually not using reset method. I have 
couple of text fields and combobox in JSP2 which I need to prepopulate from JSP1. Do 
you still recommend using reset or there is any other way. If you can refer to any 
working example it would be great. 
Thanks

David Chelimsky [EMAIL PROTECTED] wrote:
Try overriding reset() such that it doesn't do anything. Otherwise, the
reset() method in ActionForm will set all primitives to their defaults and
all objects to null.


- Original Message -
From: Goldy J 
To: 
Sent: Friday, August 01, 2003 7:20 AM
Subject: Formbean Scope


 Hello,
 I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
with some values that I set in action class associated with JSP1. I am
using the same formbean for both JSP 1 and JSP 2. I set the value that I
need in JSP2 in Action class1 and I can see they are getting set in the
formbean. But when JSP2 open the get method shows value as null. In action
mapping the scope is session.
 I suppose that Iam losing the formbean when the JSP2 opens ..is there a
way out ?
 Pls. help

 Thanks


 -
 Do you Yahoo!?
 SBC Yahoo! DSL - Now only $29.95 per month!


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



-
Do you Yahoo!?
SBC Yahoo! DSL - Now only $29.95 per month!

Re: Formbean Scope

2003-08-01 Thread David Chelimsky
Even if you don't write a reset method, the ActionForm's reset method is called on 
every request. Your only option (that I'm aware of) is to override it:

public void reset(ActionMapping mapping, HttpServletRequest request) {}

This will cause reset to do nothing and all your values will remain in tact. If you 
need a means of clearing these out, you'll have to add another method that you can 
call from Action1, for example:

public void clearForm() {
property1 = null;
//etc.
}

This is because Struts always calls reset on every request, regardless of bean scope.





- Original Message - 
From: Goldy J [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]; [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:18 AM
Subject: Re: Formbean Scope


 Thanks a lot David for the prompt reply . Iam actually not using reset method. I 
 have couple of text fields and combobox in JSP2 which I need to prepopulate from 
 JSP1. Do you still recommend using reset or there is any other way. If you can refer 
 to any working example it would be great. 
 Thanks
 
 David Chelimsky [EMAIL PROTECTED] wrote:
 Try overriding reset() such that it doesn't do anything. Otherwise, the
 reset() method in ActionForm will set all primitives to their defaults and
 all objects to null.
 
 
 - Original Message -
 From: Goldy J 
 To: 
 Sent: Friday, August 01, 2003 7:20 AM
 Subject: Formbean Scope
 
 
  Hello,
  I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
 with some values that I set in action class associated with JSP1. I am
 using the same formbean for both JSP 1 and JSP 2. I set the value that I
 need in JSP2 in Action class1 and I can see they are getting set in the
 formbean. But when JSP2 open the get method shows value as null. In action
 mapping the scope is session.
  I suppose that Iam losing the formbean when the JSP2 opens ..is there a
 way out ?
  Pls. help
 
  Thanks
 
 
  -
  Do you Yahoo!?
  SBC Yahoo! DSL - Now only $29.95 per month!
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 Do you Yahoo!?
 SBC Yahoo! DSL - Now only $29.95 per month!

RE: validwhen Alternative

2003-08-01 Thread Kamholz, Keith (corp-staff) USX
Thanks for the response Imran.

plea-for-help
I'd rather not do a custom validator if it's not necessary, but if nobody
else reponds I might have to bite the bullet and create one...
I'm surprised I haven't gotten any other responses, this seems like
something that many other people would have run into, or would at least know
how to handle...
/plea-for-help

Thanks in advance!


- Keith



-Original Message-
From: Imran Bohoran [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 12:00 AM
To: Struts Users Mailing List
Subject: RE: validwhen Alternative


We had a requirement of this sought as well. Since we needed it fast, we
went ahead with the custom validator. And it works fine. so keith, if you
want to get crackin on it I guess the custom validator is the way to go. if
anyone else has any other ideas i'll be excited to hear them. 

- I

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 9:02 PM
To: Struts (E-mail)
Subject: validwhen Alternative


Hey everyone,
From what I hear, it seems like the validwhen validation is not supported in
the final release of Struts 1.1.  Is there an alternative to this?

I have a form where 2 of the fields are start range and end range.  I want a
validation that does the following:
1) If start range is filled in, and end range isn't, validation is
successful.
2) If start range is less than or equal to the end range (and end range is
greater than or equal to start range), validation is successful.
3) Start range must be filled in.

Do I need a custom validator for this, or can I get away with the existing
validations?  Any help with this would be greatly appreciated, thanks!


- Keith


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


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

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



RE: simple - import

2003-08-01 Thread Mike Whittaker

All these ideas rely on the use of a single class/interface for declaring
constants.
I don't like this workaround to what SDK1.5 will solve.
My constants are in the right places, the classes to which they logically
belong.
I suppose with 1.5 I will be importing these constants to one class which I
can then make available as you suggest.
I think EL should have syntax to enable it to access statics

--
Mike W



Alternatively, you could load this into session or application
scopes and do
this:

c:out value=${sessionScope.constants.myVal}
or
c:out value=${applicationScope.constants.myVal}
- Original Message -
From: David Chelimsky [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:12 AM
Subject: Re: simple - import


 JSTL won't handle static methods. If you add a method to your Const class
 that returns a Const instance (ideally a singleton so you don't keep
 creating these), you can keep a Const on your ActionForm bean and set it
in
 your ActionForm. Then your JSP would look like this:

 c:out value=${myForm.const.myVar}/

 and you wouldn't even need the import statement.

 - Original Message -
 From: Alex Shneyderman [EMAIL PROTECTED]
 To: 'Struts Users Mailing List' [EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 6:34 AM
 Subject: RE: simple - import


 
  c:set var=yourVar%= Const.MY_CONST %/c:set
 
   -Original Message-
   From: Mike Whittaker [mailto:[EMAIL PROTECTED]
   Sent: Friday, August 01, 2003 7:33 AM
   To: Struts List
   Subject: simple - import
  
  
   How do you get Constants (or anything none scoped ie app/sess/req)
  into a
   jsp for use in EL
  
   I can do
  
   %@ page import=com.blah.Const %
  
  
  
   but not
  
   
   This probably demonstrates a fundamental none understanding!
  
   TIA
   --
   Mike W
  
  
   -
   To unsubscribe, e-mail: [EMAIL PROTECTED]
   For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 


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





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



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



white space on jsp compile

2003-08-01 Thread Brown, Melonie S. - Contractor
Mike,

The whitespace and formatting really bugged me as well, so I wrote a servlet
filter to run the generated html through the Java port of Html tidy
(http://sourceforge.net/projects/jtidy/) to format it and clean up the
whitespace.  

[It does have the side effect of not displaying your page, if the html is
not standards compliant (http://www.webstandards.org/), but that could be
fixed.  I deliberately left it that way, so I knew which pages needed work.
]  

---

public class TidyOutput implements Filter
{
//~ Static fields/initializers
-
static Logger log = Logger.getLogger(TidyOutput.class.getName());
//~ Instance fields

private ServletContext ctx;
private boolean isTextOut;
//~ Inner Classes
--
private static class ByteArrayServletStream extends ServletOutputStream
{
ByteArrayOutputStream baos;
ByteArrayServletStream(ByteArrayOutputStream baos)
{
this.baos = baos;
}
public void write(int param) throws java.io.IOException
{
baos.write(param);
}
}
private static class ByteArrayPrintWriter
{
private ByteArrayOutputStream baos = new ByteArrayOutputStream();
private PrintWriter pw = new PrintWriter(baos);
private ServletOutputStream sos = new ByteArrayServletStream(baos);
public PrintWriter getWriter()
{
return pw;
}
public ServletOutputStream getStream()
{
return sos;
}
byte[] toByteArray()
{
return baos.toByteArray();
}
}
//~ Methods

/**
 * Initializes the filter
 *
 * @param filterConfig
 *
 * @throws ServletException
 */
public void init(FilterConfig filterConfig) throws ServletException
{
ctx = filterConfig.getServletContext();
}
/**
 * Performs the filtering action
 *
 * @param req
 * @param response
 * @param chain
 *
 * @throws IOException
 * @throws ServletException
 */
public void doFilter(
ServletRequest req,
ServletResponse response,
FilterChain chain)
throws IOException, ServletException
{
HttpServletRequest hsr = (HttpServletRequest) req;
final HttpServletResponse resp = (HttpServletResponse) response;
final ByteArrayPrintWriter pw = new ByteArrayPrintWriter();
HttpServletResponse wrappedResp = new
HttpServletResponseWrapper(resp)
{
public PrintWriter getWriter()
{
return pw.getWriter();
}
public ServletOutputStream getOutputStream()
{
return pw.getStream();
}
};
chain.doFilter(req, wrappedResp);
byte[] bytes = pw.toByteArray();
String str = new String(bytes);
if (str.indexOf(text/html)  0)
{
setTextOut(true);
}
ServletOutputStream out = response.getOutputStream();
String contentType = req.getContentType();
//make sure that this is html 
if ((bytes != null)  isTextOut)
{
ByteArrayOutputStream baos = new ByteArrayOutputStream();
ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
Tidy tidy = new Tidy();
tidy.setIndentContent(true);
tidy.setSpaces(2);
tidy.setQuiet(true);
tidy.setSmartIndent(true);
tidy.setXHTML(false);
tidy.setWraplen(120);
tidy.setMakeClean(true);
tidy.parse(bais, baos);
byte[] xformBytes = baos.toByteArray();
resp.setContentLength(xformBytes.length);
resp.getOutputStream().write(xformBytes);
}
else
{
resp.getOutputStream().write(bytes);
}
}
/**
 * Cleanup when the filter ends
 */
public void destroy()
{
}
/**
 * Setter
 *
 * @return value
 */
public boolean isTextOut()
{
return isTextOut;
}
/**
 * Getter
 *
 * @param b
 */
public void setTextOut(boolean b)
{
isTextOut = b;
}
}
 Original Message 
Subject: white space on jsp compile
Date: Thu, 31 Jul 2003 20:21:08 +0100
From: Mike Whittaker [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
Newsgroups: gmane.comp.jakarta.struts.user

Is there any way to control it? It seems a little excessive

I'd like to retain it in the JSP, and remove as much as possible in the html

--
Mike W

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

[OT] Approaches to URL Parameter masking in Struts

2003-08-01 Thread John Cavacas
After reading a somewhat interesting post by Russell Beattie in which he
mentions the desire to separate the URL that a user sees from the actual
logic and data that it represents, it got me thinking about the approaches
that one can take in Struts to achieve something similar. I don't think the
way he refers to this practice is correct. I'm more used to referring to it
as URL parameter rewrite or masking. For those that don't know what I am
talking about, here's an example.

Say you have an URL like so: 

http://www.mysite.com/do/SomeAction?param1=value1param2=value2

After doing some magic it looks like this to the user:

http://www.mysite.com/do/SomeAction/param1/value1/param2/value2

It's somewhat easy to do this if you use Apache in front of your container.
Using a module, you can mask and unmask the URL before and after it reaches
your container. It's somewhat common practice in PHP and Perl based sites
that I've seen. That's where I first learned the trick.

Why do this? Well the most common reason is to provide search engine
friendly URLs. The other more interesting reason is to hide away your
specific technology implementation from the URL. For example, the URL could
look something like this:

http://www.mysite.com/html/SomeAction/param1/value1 or even
http://www.mysite.com/SomeAction/html/param1/value1

It also has the advantage of making the URLs somewhat easier to remember, if
you don't have a lot of parameters that is. Cocoon seems to do this as
Russell mentions in his blog. The specific abstraction between the URL and
the underlying action mapping is already accomplished by using Struts.

Anyway to finally get to the point, what approaches (if any) have you taken
to do this in a Struts/J2EE specific way? Could a Servlet Filter be used?
Throwing Apache in front of your container is not the best solution as you
could be using IIS (gasp) or just serving the site from your container
directly. Russell describes his approach in his Blog
(http://www.russellbeattie.com/notebook/1003728.html careful it's friken
long) but it doesn't seem very clean to me. 

Thanks,
John






This communication is intended for the use of the individual(s) or entity it
was addressed to and may contain confidential and/or privileged information.
If the reader of this transmission is not the intended recipient, you are
hereby notified that any review, dissemination, distribution or copying of
this communication is prohibited.  If you receive this communication in
error, please notify the sender immediately and delete this communication
from your system(s) to which it was sent and/or replicated to. (c) 2003
Sapiens Americas Corp.

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



RE: white space on jsp compile

2003-08-01 Thread Alex Shneyderman
What really would be cool if Jasper would have a setting to get rid of
those extra whitespaces, but after your first post I looked up jasper's
config settings and there does not seem to be one, or maybe there is any
Tomcat experts here? I am wondering if other containers have this
feature implemented or maybe they just do not generate extra endlines in
the first place.

Your way you add an extra processing for a request, which is probably
acceptable for development but gets to be unnecessary for the
production.

Alex.

 -Original Message-
 From: Brown, Melonie S. - Contractor
 [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 9:43 AM
 To: '[EMAIL PROTECTED]'; '[EMAIL PROTECTED]'
 Subject: white space on jsp compile
 
 Mike,
 
 The whitespace and formatting really bugged me as well, so I wrote a
 servlet
 filter to run the generated html through the Java port of Html tidy
 (http://sourceforge.net/projects/jtidy/) to format it and clean up the
 whitespace.
 
 [It does have the side effect of not displaying your page, if the html
is
 not standards compliant (http://www.webstandards.org/), but that could
be
 fixed.  I deliberately left it that way, so I knew which pages needed
 work.
 ]
 
 ---
 
 public class TidyOutput implements Filter
 {
 //~ Static fields/initializers
 -
 static Logger log = Logger.getLogger(TidyOutput.class.getName());
 //~ Instance fields
 
 private ServletContext ctx;
 private boolean isTextOut;
 //~ Inner Classes
 --
 private static class ByteArrayServletStream extends
 ServletOutputStream
 {
 ByteArrayOutputStream baos;
 ByteArrayServletStream(ByteArrayOutputStream baos)
 {
 this.baos = baos;
 }
 public void write(int param) throws java.io.IOException
 {
 baos.write(param);
 }
 }
 private static class ByteArrayPrintWriter
 {
 private ByteArrayOutputStream baos = new
ByteArrayOutputStream();
 private PrintWriter pw = new PrintWriter(baos);
 private ServletOutputStream sos = new
 ByteArrayServletStream(baos);
 public PrintWriter getWriter()
 {
 return pw;
 }
 public ServletOutputStream getStream()
 {
 return sos;
 }
 byte[] toByteArray()
 {
 return baos.toByteArray();
 }
 }
 //~ Methods
 
 /**
  * Initializes the filter
  *
  * @param filterConfig
  *
  * @throws ServletException
  */
 public void init(FilterConfig filterConfig) throws
ServletException
 {
 ctx = filterConfig.getServletContext();
 }
 /**
  * Performs the filtering action
  *
  * @param req
  * @param response
  * @param chain
  *
  * @throws IOException
  * @throws ServletException
  */
 public void doFilter(
 ServletRequest req,
 ServletResponse response,
 FilterChain chain)
 throws IOException, ServletException
 {
 HttpServletRequest hsr = (HttpServletRequest) req;
 final HttpServletResponse resp = (HttpServletResponse)
response;
 final ByteArrayPrintWriter pw = new ByteArrayPrintWriter();
 HttpServletResponse wrappedResp = new
 HttpServletResponseWrapper(resp)
 {
 public PrintWriter getWriter()
 {
 return pw.getWriter();
 }
 public ServletOutputStream getOutputStream()
 {
 return pw.getStream();
 }
 };
 chain.doFilter(req, wrappedResp);
 byte[] bytes = pw.toByteArray();
 String str = new String(bytes);
 if (str.indexOf(text/html)  0)
 {
 setTextOut(true);
 }
 ServletOutputStream out = response.getOutputStream();
 String contentType = req.getContentType();
 //make sure that this is html
 if ((bytes != null)  isTextOut)
 {
 ByteArrayOutputStream baos = new ByteArrayOutputStream();
 ByteArrayInputStream bais = new
ByteArrayInputStream(bytes);
 Tidy tidy = new Tidy();
 tidy.setIndentContent(true);
 tidy.setSpaces(2);
 tidy.setQuiet(true);
 tidy.setSmartIndent(true);
 tidy.setXHTML(false);
 tidy.setWraplen(120);
 tidy.setMakeClean(true);
 tidy.parse(bais, baos);
 byte[] xformBytes = baos.toByteArray();
 resp.setContentLength(xformBytes.length);
 resp.getOutputStream().write(xformBytes);
 }
 else
 {
 resp.getOutputStream().write(bytes);
 

RE: Formbean Scope

2003-08-01 Thread Paul McCulloch
The implementation of reset in ActionForm is empty. Overriding reset in your
descendants to do nothing will have no effect.

Paul

-Original Message-
From: David Chelimsky [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 14:34
To: Struts Users Mailing List
Subject: Re: Formbean Scope


Even if you don't write a reset method, the ActionForm's reset method is
called on every request. Your only option (that I'm aware of) is to override
it:

public void reset(ActionMapping mapping, HttpServletRequest request) {}

This will cause reset to do nothing and all your values will remain in tact.
If you need a means of clearing these out, you'll have to add another method
that you can call from Action1, for example:

public void clearForm() {
property1 = null;
//etc.
}

This is because Struts always calls reset on every request, regardless of
bean scope.





- Original Message - 
From: Goldy J [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED];
[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 8:18 AM
Subject: Re: Formbean Scope


 Thanks a lot David for the prompt reply . Iam actually not using reset
method. I have couple of text fields and combobox in JSP2 which I need to
prepopulate from JSP1. Do you still recommend using reset or there is any
other way. If you can refer to any working example it would be great. 
 Thanks
 
 David Chelimsky [EMAIL PROTECTED] wrote:
 Try overriding reset() such that it doesn't do anything. Otherwise, the
 reset() method in ActionForm will set all primitives to their defaults and
 all objects to null.
 
 
 - Original Message -
 From: Goldy J 
 To: 
 Sent: Friday, August 01, 2003 7:20 AM
 Subject: Formbean Scope
 
 
  Hello,
  I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
 with some values that I set in action class associated with JSP1. I am
 using the same formbean for both JSP 1 and JSP 2. I set the value that I
 need in JSP2 in Action class1 and I can see they are getting set in the
 formbean. But when JSP2 open the get method shows value as null. In action
 mapping the scope is session.
  I suppose that Iam losing the formbean when the JSP2 opens ..is there a
 way out ?
  Pls. help
 
  Thanks
 
 
  -
  Do you Yahoo!?
  SBC Yahoo! DSL - Now only $29.95 per month!
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 -
 Do you Yahoo!?
 SBC Yahoo! DSL - Now only $29.95 per month!


**
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you are not 
the addressee indicated in this message (or responsible for delivery of the message to 
such person), you may not copy or deliver this message to anyone. In such case, you 
should destroy this message, and notify us immediately. If you or your employer does 
not consent to Internet email messages of this kind, please advise us immediately. 
Opinions, conclusions and other information expressed in this message are not given or 
endorsed by my Company or employer unless otherwise indicated by an authorised 
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being transmitted 
via electronic mail attachments we cannot guarantee that attachments do not contain 
computer virus code.  You are therefore strongly advised to undertake anti virus 
checks prior to accessing the attachment to this electronic mail.  Axios Systems Ltd 
grants no warranties regarding performance use or quality of any attachment and 
undertakes no liability for loss or damage howsoever caused.


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



DynaValidatorBean Error Question

2003-08-01 Thread Jones, Marty B.
I am getting the following error when I try to set the name and type
attribute of the html:form tag.  I have included a snippet of my login.jsp
file and my struts-config.xml file

The main reason I am trying to set them is because if I don't set them and
let the form tag configure itself with the appropriate bean, the action
attribute on the form is empty
(action=)  .  If someone can explain why the action attribute is not being
set then I will not worry about having to try to set the name and type
attributes of the form tag.


Any help with be greatly appreciated.

Marty Jones







Error I received.




java.lang.NullPointerException
at
org.apache.commons.beanutils.PropertyUtils.getSimpleProperty(PropertyUtils.j
ava:1162)
at
org.apache.commons.beanutils.PropertyUtils.getNestedProperty(PropertyUtils.j
ava:772)
at
org.apache.commons.beanutils.PropertyUtils.getProperty(PropertyUtils.java:80
1)
at org.apache.struts.util.RequestUtils.lookup(RequestUtils.java:952)
at
org.apache.struts.taglib.html.BaseFieldTag.doStartTag(BaseFieldTag.java:176)
at
jrun__WEB2dINF__pages__login2ejsp18._jspService(jrun__WEB2dINF__pages__login
2ejsp18.java:111)
at jrun.jsp.runtime.HttpJSPServlet.service(HttpJSPServlet.java:43)
at jrun.jsp.JSPServlet.service(JSPServlet.java:119)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
at
jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at
jrun.servlet.JRunRequestDispatcher.invokeNext(JRunRequestDispatcher.java:439
)
at
jrun.servlet.JRunRequestDispatcher.forwardInvoke(JRunRequestDispatcher.java:
409)
at
jrun.servlet.JRunRequestDispatcher.forward(JRunRequestDispatcher.java:178)
at
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:10
69)
at
org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcesso
r.java:274)
at
org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProces
sor.java:455)
at
org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequ
estProcessor.java:320)
at
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
at
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at jrun.servlet.ServletInvoker.invoke(ServletInvoker.java:91)
at
jrun.servlet.JRunInvokerChain.invokeNext(JRunInvokerChain.java:42)
at
jrun.servlet.JRunRequestDispatcher.invoke(JRunRequestDispatcher.java:252)
at
jrun.servlet.ServletEngineService.dispatch(ServletEngineService.java:527)
at jrun.servlet.http.WebService.invokeRunnable(WebService.java:168)
at
jrunx.scheduler.ThreadPool$ThreadThrottle.invokeRunnable(ThreadPool.java:451
)
at jrunx.scheduler.WorkerThread.run(WorkerThread.java:66)





snippet of login.jsp



html:form name=loginForm action=/login focus=username method=GET
type=org.apache.struts.validator.DynaValidatorForm
table border=0 width=50%
tr
td align=center colspan=2H2StarTeam
Integration/H2/td
/tr
  tr
th align=right width=50%
  bean:message key=prompt.username/:
/th
td align=left width=50%
  html:text property=username size=16 maxlength=18/
/td
  /tr

  tr
th align=right width=40%
  bean:message key=prompt.password/:
/th
td align=left width=50%
  html:password property=password size=16 maxlength=18
redisplay=false/
/td
  /tr

  tr
td align=center colspan=2
br
html:img page=/images/common/login_btn.gif border=0
onclick=submitForm()/
/td
  /tr
/table
html:errors/
br
/center
/html:form




struts-config.xml

HELP ME: my index.jsp is a blank page

2003-08-01 Thread Laurent MARQUEZ


Hi,
I m deploying xpetstore sourceforge project 
on bea weblogic 7.0
But in my client browser threre is a blank page.
WHY?

Help Me!!!

The log:

Starting WebLogic Server...
1 ao¹t 03 16:02:53 CEST Notice Management 140005 Loading
configuration C:\bea\user_projects\xpetstore\.\config.xml
1 ao¹t 03 16:02:58 CEST Notice Security 090082 Security
initializing using realm myrealm.
1 ao¹t 03 16:02:58 CEST Notice WebLogicServer 000327 Starting
WebLogic Admin Server xpetstoreserver for domain
xpetstore
1 ao¹t 03 16:03:28 CEST Notice Management 141052 Application
Poller started for development server.
0 [Thread-11] INFO util.PropertyMessageResources  - Initializing,
config='org.apache.struts.util.LocalStrings', returnNull=true
0 [Thread-11] INFO util.PropertyMessageResources  - Initializing,
config='org.apache.struts.action.ActionResources', retur
nNull=true
312 [Thread-11] INFO util.PropertyMessageResources  - Initializing,
config='Resources', returnNull=true
328 [Thread-11] INFO filter.SignOnFilter  - init()
328 [Thread-11] INFO filter.SignOnFilter  -
...signon.action=/signon.jspa
328 [Thread-11] INFO filter.SignOnFilter  - ...Adding URI to protect:
checkout.jspa
328 [Thread-11] INFO filter.SignOnFilter  - ...Adding URI to protect:
order.jspa
1 ao¹t 03 16:03:29 CEST Notice Security 090092 SSL will load
trusted CAs from the JDK cacerts KeyStore:
C:\bea\jdk131_02\jre\lib\security\cacerts for realm myrealm on server
xpetstoreserver.
1 ao¹t 03 16:03:30 CEST Notice WebLogicServer 000355 Thread
SSLListenThread.Default listening on port 7002, ipaddress
192.168.1.28
1 ao¹t 03 16:03:30 CEST Notice WebLogicServer 000355 Thread
ListenThread.Default listening on port 8080, ip address 192.168.1.28
1 ao¹t 03 16:03:30 CEST Notice Management 141030 Starting
discovery of Managed Server... This feature is on by default, you may
turn this off by passing -Dweblogic.management.discover=false
1 ao¹t 03 16:03:30 CEST Notice WebLogicServer 000331 Started
WebLogic Admin Server xpetstoreserver for domain xpetstore running
in Development Mode
1 ao¹t 03 16:03:30 CEST Notice WebLogicServer 000365 Server
state changed to RUNNING
1 ao¹t 03 16:03:30 CEST Notice WebLogicServer 000360 Server
started in RUNNING mode13687 [ExecuteThread: '12' for queue: 'default']
INFO util.PropertyMessageResources  - Initializing,
config='org.apache.struts.taglib.bean.LocalStrings',returnNull=true
13687 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing,
config='org.apache.struts.util.LocalStrings', returnNull=true
13687 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing,
config='org.apache.struts.taglib.html.LocalStrings', returnNull=true
13687 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true
16359 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true
16359 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.logic.LocalStrings', returnNull=true
16375 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true
16375 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true
16406 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true
16406 [ExecuteThread: '12' for queue: 'default'] INFO
util.PropertyMessageResources  - Initializing, config='org.apache.st
ruts.taglib.html.LocalStrings', returnNull=true


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



RE: DynaValidatorForm question

2003-08-01 Thread Yansheng Lin
You can forward to a .jsp page directly, i.e., without using an action forward
in struts-config.  That way the action class won't be called initially.

Then by setting the form name and form field the same as the FormBean, you can
still submit to whichever action that handles your request.   


-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: August 1, 2003 5:50 AM
To: Struts Users Mailing List
Subject: RE: DynaValidatorForm question


I think that I may be missing something here.  When using struts, how do you
load say a html form (using a jsp file) to the user initially without having
the Action class actually being processed and then being forwarded to the
view?  I defintely want to use the Validator class but I only want it to
validate when the user has actually submitted a form with request parameters
to that given action.

Marty

-Original Message-
From: Jones, Marty B. 
Sent: Friday, August 01, 2003 6:09 AM
To: Struts Users Mailing List
Subject: RE: DynaValidatorForm question


Will this still validate the request parameters when there are actually
request parameters present?

-Original Message-
From: Yansheng Lin [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 6:04 PM
To: 'Struts Users Mailing List'
Subject: RE: DynaValidatorForm question


Set validate attribute in action to false will solve your problem.

-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: July 31, 2003 3:37 PM
To: [EMAIL PROTECTED]
Subject: DynaValidatorForm question


I have a class that extends Action (LoginAction) and references a
DynaValidatorForm for form validation. I have noticed that if I directly
reference a url say http://myserver/control/login that it instantiates the
LoginAction as it should.  My question is, what is the best way to not allow
the Action class to be fired if no request arguments are on the request so
that the login.jsp file will paint to allow the user to enter usename and
password information in.  I am pretty sure that I could use a normal
ActionForm and in the validation method check to see if the username and
password values are both null.  If they are then return a mapping to go back
to the login screen.  Is there a way to do this with the DynaValidatorForm?

Thanks in advance,

Marty Jones


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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


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

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

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


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



Downloading files using JSP

2003-08-01 Thread Jagannayakam
How to download attachments using JSPs

Regards,
Jagan.


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



RE: Logical Server Name (Sybase database)

2003-08-01 Thread OFlaherty, Colm
Chirag, 

I may be coming in late on this one, but heres what I know on the issue u're 
experiencing.. 

When u use most native (or ODBC) Sybase drivers, they go through the Sybase Open 
Client (CTLIB or DBLIB), doing a translation of the logical server name to the 
physical server name (and port number) though the SQL.INI file, as stored in 
%sybase%\ini\sql.ini.  

Funnily enough though, when u use the Sybase Jconnect drivers (which u seem to be, 
based on the JDBC URL below), they do strongNOTstrong seem to do the 
logical-physical server translation thing, using the SQL.INI... why this is, I'm not 
sure, but that's my experience with it.  U can prove this using a non-Struts POJO 
which just uses the driver to connect to the database using the physical server name.  

The upshot of this (unless there is a way around it, which I'm not aware of) is that 
strong u have to pass the physical server name and port number in the JDBC 
connection URL, instead of just the local server name /strong

If u really wanted to use the __logical__ server name, u could do the translation 
yourself before connecting, by looking up the %sybase%/ini/sql.ini file, and parsing 
it to produce the physical server name and port number.  This would certainly help 
maintenance (at the cost of some loss of DBMS independence), given that SQL.INI is the 
traditional method of naming and maintaining Sybase servers.

Hope this helps u understand your issue a little better.. 

Colm
 -Original Message-
From:   Chirag Mehta [mailto:[EMAIL PROTECTED] 
Sent:   01 August 2003 09:22
To: Struts Users Mailing List
Subject:Re: Logical Server Name

I cannot do that though because the port and the physical server is resolved
automatically from the interface file.

Any more suggestions?

Thanks for help anyway

Chirag

Jimmy Emmanual wrote:

 try adding the port # and a database name.

 set-property property=url value=jdbc:sybase:Tds:LNT_MAST:4100/testdb/

 -Original Message-
 From: Chirag Mehta [mailto:[EMAIL PROTECTED]
 Sent: Thursday, July 31, 2003 1:40 PM
 To: struts-user
 Subject: Logical Server Name

 Hello,

 Can anyone help?

 I am using a BasicDataSource config in my config.xml file to reference a
 sybase database. Using a logical server name, the code gives me a
 IOException.

 in my config.xml:
 set-property property=url value=jdbc:sybase:Tds:LNT_MAST/
 exception::
 javax.servlet.ServletException: java.sql.SQLException: JZ003: Incorrect
 URL format. URL: LNT_MAST

 But if I use the physical server name I have no problems setting up the
 DB Connection. (Well I haven't got any exceptions so far)

 Has anyone got any idea of any code I may have to change for my app to
 resolve from the logical server name? (The logical server name resolves
 from a interface file which is on my network server)

 Thanks a million

 Chirag
 --
 NOTICE: If received in error, please destroy and notify sender.  Sender
 does not waive confidentiality or privilege, and use is prohibited.

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

--
NOTICE: If received in error, please destroy and notify sender.  Sender does
not waive confidentiality or privilege, and use is prohibited.





**
This message is sent in confidence for the addressee
only.  The contents are not allowed to be disclosed to
anyone other than the addressee.  Unauthorised 
recipients must preserve this confidentiality and should 
please advise the sender immediately of any error in
transmission.
**


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



RE: Urgent: Editor for JSP in Eclipse

2003-08-01 Thread Ashish Kulkarni
Hi, 
i was looking at
http://black-sun.sourceforge.net/
which is the editor for jsp???

Ashish

--- [EMAIL PROTECTED] wrote:
 Thanx a lot!!! works great for me
 
 --mohan
 
 
  I am using the blacksun plugin.  It does have a
 find start/end tag
  feature.
 
  http://black-sun.sourceforge.net/
 
  -Original Message-
  From: [EMAIL PROTECTED]
 [mailto:[EMAIL PROTECTED]
  Sent: Thursday, July 31, 2003 4:31 PM
  To: [EMAIL PROTECTED]
  Subject: Urgent: Editor for JSP in Eclipse
 
 
  Hi All
  I am using Eclipse and i need a JSP editor/ HTML
 editor to stuff like
  matching HTML tags in my JSPs and warn if there
 are no matching tags for
  an HTML tag, i have downloaded the solar eclipse
 plug-in but it ownly
  colors various JSP/HTML elements but i am not sure
 how to find mactching
  HTML tags or JSP tags wid it
 
 
 
  Thanx
 
  --MOhan
 
 
 
 

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

***
   This electronic mail transmission contains
 confidential and/or
  privileged  information intended only for the
 person(s) named.  Any use,
  distribution,  copying or disclosure by another
 person is strictly
  prohibited.
 

***
 
 
 
 
 

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

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


=
A$HI$H

__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



Re: Formbean Scope

2003-08-01 Thread David Chelimsky
Goldy, Paul is correct (and corrected I stand...).

Paul - do you have a recommendation for Goldy's situation?


- Original Message -
From: Paul McCulloch [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 9:07 AM
Subject: RE: Formbean Scope


 The implementation of reset in ActionForm is empty. Overriding reset in
your
 descendants to do nothing will have no effect.

 Paul

 -Original Message-
 From: David Chelimsky [mailto:[EMAIL PROTECTED]
 Sent: 01 August 2003 14:34
 To: Struts Users Mailing List
 Subject: Re: Formbean Scope


 Even if you don't write a reset method, the ActionForm's reset method is
 called on every request. Your only option (that I'm aware of) is to
override
 it:

 public void reset(ActionMapping mapping, HttpServletRequest request) {}

 This will cause reset to do nothing and all your values will remain in
tact.
 If you need a means of clearing these out, you'll have to add another
method
 that you can call from Action1, for example:

 public void clearForm() {
 property1 = null;
 //etc.
 }

 This is because Struts always calls reset on every request, regardless of
 bean scope.





 - Original Message -
 From: Goldy J [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED];
 [EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 8:18 AM
 Subject: Re: Formbean Scope


  Thanks a lot David for the prompt reply . Iam actually not using reset
 method. I have couple of text fields and combobox in JSP2 which I need to
 prepopulate from JSP1. Do you still recommend using reset or there is any
 other way. If you can refer to any working example it would be great.
  Thanks
 
  David Chelimsky [EMAIL PROTECTED] wrote:
  Try overriding reset() such that it doesn't do anything. Otherwise, the
  reset() method in ActionForm will set all primitives to their defaults
and
  all objects to null.
 
 
  - Original Message -
  From: Goldy J
  To:
  Sent: Friday, August 01, 2003 7:20 AM
  Subject: Formbean Scope
 
 
   Hello,
   I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
  with some values that I set in action class associated with JSP1. I am
  using the same formbean for both JSP 1 and JSP 2. I set the value that I
  need in JSP2 in Action class1 and I can see they are getting set in the
  formbean. But when JSP2 open the get method shows value as null. In
action
  mapping the scope is session.
   I suppose that Iam losing the formbean when the JSP2 opens ..is there
a
  way out ?
   Pls. help
  
   Thanks
  
  
   -
   Do you Yahoo!?
   SBC Yahoo! DSL - Now only $29.95 per month!
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  Do you Yahoo!?
  SBC Yahoo! DSL - Now only $29.95 per month!


 **
 Axios Email Confidentiality Footer
 Privileged/Confidential Information may be contained in this message. If
you are not the addressee indicated in this message (or responsible for
delivery of the message to such person), you may not copy or deliver this
message to anyone. In such case, you should destroy this message, and notify
us immediately. If you or your employer does not consent to Internet email
messages of this kind, please advise us immediately. Opinions, conclusions
and other information expressed in this message are not given or endorsed by
my Company or employer unless otherwise indicated by an authorised
representative independent of this message.
 WARNING:
 While Axios Systems Ltd takes steps to prevent computer viruses from being
transmitted via electronic mail attachments we cannot guarantee that
attachments do not contain computer virus code.  You are therefore strongly
advised to undertake anti virus checks prior to accessing the attachment to
this electronic mail.  Axios Systems Ltd grants no warranties regarding
performance use or quality of any attachment and undertakes no liability for
loss or damage howsoever caused.


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





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



RE: Formbean Scope

2003-08-01 Thread Paul McCulloch
Afraid not - I'm a newbie who happened to look at the source for ActionForm
yesterday. Sorry.

-Original Message-
From: David Chelimsky [mailto:[EMAIL PROTECTED]
Sent: 01 August 2003 15:54
To: Struts Users Mailing List
Subject: Re: Formbean Scope


Goldy, Paul is correct (and corrected I stand...).

Paul - do you have a recommendation for Goldy's situation?


- Original Message -
From: Paul McCulloch [EMAIL PROTECTED]
To: 'Struts Users Mailing List' [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 9:07 AM
Subject: RE: Formbean Scope


 The implementation of reset in ActionForm is empty. Overriding reset in
your
 descendants to do nothing will have no effect.

 Paul

 -Original Message-
 From: David Chelimsky [mailto:[EMAIL PROTECTED]
 Sent: 01 August 2003 14:34
 To: Struts Users Mailing List
 Subject: Re: Formbean Scope


 Even if you don't write a reset method, the ActionForm's reset method is
 called on every request. Your only option (that I'm aware of) is to
override
 it:

 public void reset(ActionMapping mapping, HttpServletRequest request) {}

 This will cause reset to do nothing and all your values will remain in
tact.
 If you need a means of clearing these out, you'll have to add another
method
 that you can call from Action1, for example:

 public void clearForm() {
 property1 = null;
 //etc.
 }

 This is because Struts always calls reset on every request, regardless of
 bean scope.





 - Original Message -
 From: Goldy J [EMAIL PROTECTED]
 To: Struts Users Mailing List [EMAIL PROTECTED];
 [EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 8:18 AM
 Subject: Re: Formbean Scope


  Thanks a lot David for the prompt reply . Iam actually not using reset
 method. I have couple of text fields and combobox in JSP2 which I need to
 prepopulate from JSP1. Do you still recommend using reset or there is any
 other way. If you can refer to any working example it would be great.
  Thanks
 
  David Chelimsky [EMAIL PROTECTED] wrote:
  Try overriding reset() such that it doesn't do anything. Otherwise, the
  reset() method in ActionForm will set all primitives to their defaults
and
  all objects to null.
 
 
  - Original Message -
  From: Goldy J
  To:
  Sent: Friday, August 01, 2003 7:20 AM
  Subject: Formbean Scope
 
 
   Hello,
   I have JSP1 from which I go to JSP2. The JSP2 should come prepopulated
  with some values that I set in action class associated with JSP1. I am
  using the same formbean for both JSP 1 and JSP 2. I set the value that I
  need in JSP2 in Action class1 and I can see they are getting set in the
  formbean. But when JSP2 open the get method shows value as null. In
action
  mapping the scope is session.
   I suppose that Iam losing the formbean when the JSP2 opens ..is there
a
  way out ?
   Pls. help
  
   Thanks
  
  
   -
   Do you Yahoo!?
   SBC Yahoo! DSL - Now only $29.95 per month!
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
  -
  Do you Yahoo!?
  SBC Yahoo! DSL - Now only $29.95 per month!


 **
 Axios Email Confidentiality Footer
 Privileged/Confidential Information may be contained in this message. If
you are not the addressee indicated in this message (or responsible for
delivery of the message to such person), you may not copy or deliver this
message to anyone. In such case, you should destroy this message, and notify
us immediately. If you or your employer does not consent to Internet email
messages of this kind, please advise us immediately. Opinions, conclusions
and other information expressed in this message are not given or endorsed by
my Company or employer unless otherwise indicated by an authorised
representative independent of this message.
 WARNING:
 While Axios Systems Ltd takes steps to prevent computer viruses from being
transmitted via electronic mail attachments we cannot guarantee that
attachments do not contain computer virus code.  You are therefore strongly
advised to undertake anti virus checks prior to accessing the attachment to
this electronic mail.  Axios Systems Ltd grants no warranties regarding
performance use or quality of any attachment and undertakes no liability for
loss or damage howsoever caused.


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





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

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



Re: Logical Server Name (Sybase database)

2003-08-01 Thread Chirag Mehta
I think so mate.

Thanks for the help!

Chirag

OFlaherty, Colm wrote:

 Chirag,

 I may be coming in late on this one, but heres what I know on the issue u're 
 experiencing..

 When u use most native (or ODBC) Sybase drivers, they go through the Sybase Open 
 Client (CTLIB or DBLIB), doing a translation of the logical server name to the 
 physical server name (and port number) though the SQL.INI file, as stored in 
 %sybase%\ini\sql.ini.

 Funnily enough though, when u use the Sybase Jconnect drivers (which u seem to be, 
 based on the JDBC URL below), they do strongNOTstrong seem to do the 
 logical-physical server translation thing, using the SQL.INI... why this is, I'm not 
 sure, but that's my experience with it.  U can prove this using a non-Struts POJO 
 which just uses the driver to connect to the database using the physical server name.

 The upshot of this (unless there is a way around it, which I'm not aware of) is that 
 strong u have to pass the physical server name and port number in the JDBC 
 connection URL, instead of just the local server name /strong

 If u really wanted to use the __logical__ server name, u could do the translation 
 yourself before connecting, by looking up the %sybase%/ini/sql.ini file, and parsing 
 it to produce the physical server name and port number.  This would certainly help 
 maintenance (at the cost of some loss of DBMS independence), given that SQL.INI is 
 the traditional method of naming and maintaining Sybase servers.

 Hope this helps u understand your issue a little better..

 Colm
  -Original Message-
 From:   Chirag Mehta [mailto:[EMAIL PROTECTED]
 Sent:   01 August 2003 09:22
 To: Struts Users Mailing List
 Subject:Re: Logical Server Name

 I cannot do that though because the port and the physical server is resolved
 automatically from the interface file.

 Any more suggestions?

 Thanks for help anyway

 Chirag

 Jimmy Emmanual wrote:

  try adding the port # and a database name.
 
  set-property property=url value=jdbc:sybase:Tds:LNT_MAST:4100/testdb/
 
  -Original Message-
  From: Chirag Mehta [mailto:[EMAIL PROTECTED]
  Sent: Thursday, July 31, 2003 1:40 PM
  To: struts-user
  Subject: Logical Server Name
 
  Hello,
 
  Can anyone help?
 
  I am using a BasicDataSource config in my config.xml file to reference a
  sybase database. Using a logical server name, the code gives me a
  IOException.
 
  in my config.xml:
  set-property property=url value=jdbc:sybase:Tds:LNT_MAST/
  exception::
  javax.servlet.ServletException: java.sql.SQLException: JZ003: Incorrect
  URL format. URL: LNT_MAST
 
  But if I use the physical server name I have no problems setting up the
  DB Connection. (Well I haven't got any exceptions so far)
 
  Has anyone got any idea of any code I may have to change for my app to
  resolve from the logical server name? (The logical server name resolves
  from a interface file which is on my network server)
 
  Thanks a million
 
  Chirag
  --
  NOTICE: If received in error, please destroy and notify sender.  Sender
  does not waive confidentiality or privilege, and use is prohibited.
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]

 --
 NOTICE: If received in error, please destroy and notify sender.  Sender does
 not waive confidentiality or privilege, and use is prohibited.

 **
 This message is sent in confidence for the addressee
 only.  The contents are not allowed to be disclosed to
 anyone other than the addressee.  Unauthorised
 recipients must preserve this confidentiality and should
 please advise the sender immediately of any error in
 transmission.
 **

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

--
NOTICE: If received in error, please destroy and notify sender.  Sender does not waive 
confidentiality or privilege, and use is prohibited.


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

RE: Struts 1.1 in Websphere 4.01 on plugin with OS/390

2003-08-01 Thread Gramann, Cindy
I've been able to get Struts working with the Websphere 4.01 plugin on z/OS
(recently upgraded from OS/390). We are using JSP 1.1 and Servlet 2.2. The
only changes that I needed to make after running the Struts example .war
file through wartowebapp were to extract the dtd's under
org.apache.struts.resources and find the right .jar files for xml parsing.

Is there any other message in your log file before the error message that
you mentioned?

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 3:43 PM
To: [EMAIL PROTECTED]
Subject: Struts 1.1 in Websphere 4.01 on plugin with OS/390


Does anyone has any luck with running Struts 1.1 in the following env.?

Websphere 4.01 on with a plugin
OS/390

JSP level is configured to 1.1 and it's running at servlet level 2.2, 
so I'm hopeful that it'll work.

I used wartowebapp to deploy the struts-example war file and it looks 
like the actionServlet doesn't even gets load or initialized on 
startup.  Accessing the index.jsp file could give me the famous Cannot 
find message resources under key org.apache.struts.action.MESSAGE 
error.  Any idea?

YPL


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



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



RE: Struts 1.1 in Websphere 4.01 on plugin with OS/390

2003-08-01 Thread yau-pang . lee
Thks for the info Cindy,

I'm trying to check with the admin to see if it's reading the 
webapp-name.webapp file to initialize itself on startup with our 
admin(The joy of working with/through an admin).  And I'll try 
extracting the DTD files like you said just in case(as soon as the 
admin let me and give me permission to the directory).  BTW, which xml 
parser are you using?

YPL

-Original Message-
From: Cindy.Gramann [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 11:00 AM
To: struts-user
Subject: RE: Struts 1.1 in Websphere 4.01 on plugin with OS/390


I've been able to get Struts working with the Websphere 4.01 plugin on 
z/OS
(recently upgraded from OS/390). We are using JSP 1.1 and Servlet 2.2. 
The
only changes that I needed to make after running the Struts example .war
file through wartowebapp were to extract the dtd's under
org.apache.struts.resources and find the right .jar files for xml 
parsing.

Is there any other message in your log file before the error message 
that
you mentioned?

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
Sent: Thursday, July 31, 2003 3:43 PM
To: [EMAIL PROTECTED]
Subject: Struts 1.1 in Websphere 4.01 on plugin with OS/390


Does anyone has any luck with running Struts 1.1 in the following env.?

Websphere 4.01 on with a plugin
OS/390

JSP level is configured to 1.1 and it's running at servlet level 2.2, 
so I'm hopeful that it'll work.

I used wartowebapp to deploy the struts-example war file and it looks 
like the actionServlet doesn't even gets load or initialized on 
startup.  Accessing the index.jsp file could give me the famous Cannot 
find message resources under key org.apache.struts.action.MESSAGE 
error.  Any idea?

YPL


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



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


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



javax.servlet.ServletException: BeanUtils.populate

2003-08-01 Thread Yan, Charlene
All,

I have been strugling with this for a while.  I looked at the archive and found 
similar questions but no answers there.

I have a form that has two fields - a bean and a String field.
My jsp displays the two fields.  I was able to get to the JSP by calling 
ssoXref.do?operation=showSsoXref.  But when I click on look up button on the page.  It 
throws the exception --javax.servlet.ServletException: BeanUtils.populate.  

My action and struts-config are attached below.  THANKS FOR ANY INSIGHT ON THIS...  
Charlene
action path=/ssoXref parameter=operation type=com.tl.tln.action.SsoXrefAction 
name=ssoXrefForm input=/ssoXrefEdit.jsp scope=session  
  forward name=showSsoXref path=/ssoXrefEdit.jsp/
/action
=
public class SsoXrefForm extends TlnActionForm
{
  private TlnSsoXref tlnSsoXref = new TlnSsoXref();

  private String searchSwbId = ;

  public String getSearchSwbId()
  {
return searchSwbId;
  }

  public void setSearchSwbId(String newSearchSwbId)
  {
searchSwbId = newSearchSwbId;
  }

  public TlnSsoXref getTlnSsoXref()
  {
return tlnSsoXref;
  }

  public void setTlnSsoXref(TlnSsoXref newTlnSsoXref)
  {
tlnSsoXref = newTlnSsoXref;
  }
}

%@ taglib uri=/WEB-INF/struts-html.tld prefix=html %
%@ include file=/include/incPageStart.jsp %
bean:define id=crumbName type=java.lang.String name=ssoXrefForm 
property=crumbName /
bean:define id=crumbID type=java.lang.String name=ssoXrefForm 
property=crumbID /
bean:define id=crumbAction type=java.lang.String name=ssoXrefForm 
property=crumbAction /
html
head
meta http-equiv=Content-Language content=en-us
meta http-equiv=content-type content=text/html;charset=iso-8859-1
title%=crumbName%/title
link rel=stylesheet type=text/css href=includes/styles.css

script language=Javascript src=includes/floating-toolbar.js 
type=text/javascript/script
script language=Javascript type=text/javascript
function handleSubmit(action) {
document.forms[0].operation.value=action;
alert(operation is  + document.forms[0].operation.value);
return true;
  }
/script
base target=contents
/head

body onload=setFocus()
html:form method=post action=/ssoXref.do
input type=hidden name=operation value= /

div id=taskarea
div class=breadcrumb
  bc:breadcrumb showCrumbs=true
crumbAction=%=crumbAction%
crumbName=%=crumbName%
crumbID=%=crumbID% /
/div
div class=taskbar align=right
/div
/div
div id=taskareaspacer
/div
html:errors/
table cellpadding=0 cellspacing=0 border=0 width=100%
tr
td width=20img src=images/spacer.gif height=1 width=20 alt= 
border=0/td
td width=100%
!-- Content Begin --
table cellpadding=0 cellspacing=0 border=0
tr
td colspan=3img class=field-divider alt= src= //td
/tr
tr class=columnheadings
  td colspan=3span class=resultstitle%=crumbName%/span/td
/tr
tr
td colspan=3img class=field-divider src= alt= //td
/tr  
tr
td class=field-name width=20%Swb ID:nbsp;*/td
td class=vdivider width=1 img class=spacer src= alt= 
//td
td class=field-text width=80%
html:text name=ssoXrefForm property=searchSwbId size=54 
maxlength=200 / 
nbsp;nbsp;nbsp; div class=actionsinput type=submit name=action 
value=Look up onClick=javascript:handleSubmit('lookup');/div/td
/tr
  tr
td colspan=3html:errors//td
/tr  
tr
td class=field-name width=20%Swb ID:nbsp;*/td
td class=vdivider width=1 img class=spacer src= alt= 
//td
td class=field-text width=80%

html:text name=ssoXrefForm property=tlnSsoXref.swbId 
size=54 maxlength=200 /
/td
/tr
  tr
td colspan=3img class=field-divider src= alt= //td
/tr
tr
td class=field-name width=20% valign=topAuth Class:nbsp;*/td
td class=vdivider width=1 img class=spacer src= alt= 
//td
td class=field-text width=80%html:text name=ssoXrefForm 
property=tlnSsoXref.authClass size=54//td
/tr
  tr
td colspan=3img class=field-divider src= alt= //td
/tr
  tr
td class=field-name width=20% valign=topExpiration 
Date:nbsp;*/td
td class=vdivider width=1 img class=spacer src= alt= 
//td
td class=field-text width=80%html:text name=ssoXrefForm 
property=tlnSsoXref.expirationDt size=54//td
/tr
tr
td colspan=3img class=field-divider src= alt= //td
/tr
  tr
td class=field-name width=20% valign=topMaintained 
By:nbsp;*/td
td class=vdivider width=1 img class=spacer src= alt= 
//td
   

RE: Downloading files using JSP

2003-08-01 Thread NYIMI Jose (BMB)
Just provide a link the document, the browser will try to open it, if it can not it 
will pop up a message to download it.

José.

-Original Message-
From: Jagannayakam [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 4:33 PM
To: Struts Users Mailing List (E-mail)
Subject: Downloading files using JSP


How to download attachments using JSPs

Regards,
Jagan.


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



 DISCLAIMER 

This e-mail and any attachment thereto may contain information which is confidential 
and/or protected by intellectual property rights and are intended for the sole use of 
the recipient(s) named above. 
Any use of the information contained herein (including, but not limited to, total or 
partial reproduction, communication or distribution in any form) by other persons than 
the designated recipient(s) is prohibited. 
If you have received this e-mail in error, please notify the sender either by 
telephone or by e-mail and delete the material from any computer.

Thank you for your cooperation.

For further information about Proximus mobile phone services please see our website at 
http://www.proximus.be or refer to any Proximus agent.


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



RE: Downloading files using JSP

2003-08-01 Thread Yee, Richard K,,DMDCWEST
What do you mean by 'attachment'? Are you talking about an email attachment
or something else?

-R

-Original Message-
From: Jagannayakam [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 7:33 AM
To: Struts Users Mailing List (E-mail)
Subject: Downloading files using JSP


How to download attachments using JSPs

Regards,
Jagan.


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

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



Html Form Tag Question

2003-08-01 Thread Jones, Marty B.
I have the following tag declaration in a jsp file:

html:form name=loginForm action=/login focus=username method=POST
type=com.dailyaccess.actions.LoginBean

The jsp compiles correct and views correctly.  The issue that I am having is
that the action attribute in the html form that is created is an empty
string!  It is as if the FormTag class is not setting the action string.

Any help would be greatly appreciated.


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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



Re: Html Form Tag Question

2003-08-01 Thread Michael Ruppin
I don't know if it was resolved, but this thread
should be of interest to you:

http://marc.theaimsgroup.com/?l=struts-userm=105943092932593w=2

HTH

m

--- Jones, Marty B. [EMAIL PROTECTED]
wrote:
 I have the following tag declaration in a jsp file:
 
 html:form name=loginForm action=/login
 focus=username method=POST
 type=com.dailyaccess.actions.LoginBean
 
 The jsp compiles correct and views correctly.  The
 issue that I am having is
 that the action attribute in the html form that is
 created is an empty
 string!  It is as if the FormTag class is not
 setting the action string.
 
 Any help would be greatly appreciated.
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



Re: Struts w/EJB

2003-08-01 Thread Erik Price


Martin Naskovski wrote:
Hello all. Is there an app that demonstrates the use of Struts  EJB as a
persistence layer? I checked out Struts-Resume from Matt Raible, but it
uses Hibernate... Is there anything available w/EJB's? Thanks.


http://xpetstore.sf.net/

There are two implementations of Xpetstore, one that uses EJB and one 
that just uses servlets.  Check out the EJB one, it works great with JBoss.

Note, I personally don't think that using EJB is fundamentally different 
from any other persistence layer, at least not in reference to Struts, 
so you should be able to look at just about any sample code and figure 
out some best practices.  It all boils down to the fact that you have 
Struts Actions, which receive HTTP requests from the client, and which 
then delegate the work to other objects.  Whether those objects are 
session beans that perform some task by calling EJB or Hibernate 
objects, or whether you're going the simple route (what I'm doing b/c my 
needs are so trivial) and just having your Struts Actions directly 
manipulate Data Access Objects which use JDBC business delegates, it's 
not really much different.

The only big difference I've seen is that some people believe you should 
abstract your model into a layer just beyond Struts Actions so that you 
can switch from Struts to another framework if necessary.  But the other 
line of reasoning is that this is a lot of extra work if you have no 
plans to leave Struts.

My 2 cents.

Erik

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


ActionForm Design Question

2003-08-01 Thread Caroline Jen
Hi, I am building a web site.  The primary functions
of this site are for authors to submit their research
papers.  The research papers will go through a
screening process (screened by peers in the field). 
Visiors can view the published articles online.

Authors and peers are the registered users of the web
site.

Therefore, there is not much data manipulation at the
web site except that authors may be requested to
revise their papers and re-submit.  And both authors
and peers have to fill out registration forms to
become members of the web site.

The content of the registration form is pretty
standard: name, address, phone number, academic
background information and achievements, etc.  Most of
them are Strings.  A couple of checkboxes, three sets
of radio buttons (to indicate preferences), and a
primitive double.  Of course, I have a text field for
loading research papers.

Question 1: Do I use conventional ActionForm?
Map-backed ActionForm? or DynaActionForm for this
project?

Question 2: Which strategy should I use to transfer
values between tiers?  Setting an immutable value
object?  or transferring values by reflection
(BeanUtil)? or passing a Map?

I highly value your opinions and advices.  Thanks.

__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



RE: Html Form Tag Question

2003-08-01 Thread Canning, Chuck
Hey,

I had the same syptoms and the problem was an incorrect servlet-mapping in
my web.xml. We had /*.do instead of *.do. because of that, the
RequestUtils.getActionMappingURL() would not parse the action correctly. YOu
might want to start looking there.

Chuck

-Original Message-
From: Michael Ruppin [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:40 AM
To: Struts Users Mailing List
Subject: Re: Html Form Tag Question


I don't know if it was resolved, but this thread
should be of interest to you:

http://marc.theaimsgroup.com/?l=struts-userm=105943092932593w=2

HTH

m

--- Jones, Marty B. [EMAIL PROTECTED]
wrote:
 I have the following tag declaration in a jsp file:
 
 html:form name=loginForm action=/login
 focus=username method=POST
 type=com.dailyaccess.actions.LoginBean
 
 The jsp compiles correct and views correctly.  The
 issue that I am having is
 that the action attribute in the html form that is
 created is an empty
 string!  It is as if the FormTag class is not
 setting the action string.
 
 Any help would be greatly appreciated.
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

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



Re: OT - Struts w/EJB

2003-08-01 Thread Erik Price


message message wrote:


How come there is so much free ware available especially from sourceforge ?
The whole point of sourceforge is to foster the development of open 
source/free software by providing web hosting, CVS repositories, mailing 
lists, and most other needs traditionally used by open source software 
projects.

I think SF is pretty damn cool, but I really wish that they'd (1) go 
through and clean up all the projects that haven't released any files in 
 their first 1 month of existence, and (2) be given a few million 
dollars worth of hardware to improve their site performance.  (Maybe a 
J2EE rewrite would help here, but not really sure.)



Erik

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


RE: Html Form Tag Question

2003-08-01 Thread Jones, Marty B.
Thanks for the info.  I will take a look.

-Original Message-
From: Canning, Chuck [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:49 AM
To: 'Struts Users Mailing List'
Subject: RE: Html Form Tag Question


Hey,

I had the same syptoms and the problem was an incorrect servlet-mapping in
my web.xml. We had /*.do instead of *.do. because of that, the
RequestUtils.getActionMappingURL() would not parse the action correctly. YOu
might want to start looking there.

Chuck

-Original Message-
From: Michael Ruppin [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:40 AM
To: Struts Users Mailing List
Subject: Re: Html Form Tag Question


I don't know if it was resolved, but this thread
should be of interest to you:

http://marc.theaimsgroup.com/?l=struts-userm=105943092932593w=2

HTH

m

--- Jones, Marty B. [EMAIL PROTECTED]
wrote:
 I have the following tag declaration in a jsp file:
 
 html:form name=loginForm action=/login
 focus=username method=POST
 type=com.dailyaccess.actions.LoginBean
 
 The jsp compiles correct and views correctly.  The
 issue that I am having is
 that the action attribute in the html form that is
 created is an empty
 string!  It is as if the FormTag class is not
 setting the action string.
 
 Any help would be greatly appreciated.
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

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

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



RE: Html Form Tag Question

2003-08-01 Thread Bailey, Shane C.

Take out the type and name attributes out of the form tag.  They should
already be mapped in the struts-config and you don't need them in the JSP.



-Original Message-
From: Jones, Marty B. [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 11:34 AM
To: [EMAIL PROTECTED]
Subject: Html Form Tag Question

I have the following tag declaration in a jsp file:

html:form name=loginForm action=/login focus=username method=POST
type=com.dailyaccess.actions.LoginBean

The jsp compiles correct and views correctly.  The issue that I am having is
that the action attribute in the html form that is created is an empty
string!  It is as if the FormTag class is not setting the action string.

Any help would be greatly appreciated.


Marty B. Jones
Senior Software Engineer
DailyAccess.Com


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

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



Re: Struts w/EJB

2003-08-01 Thread Vic Cekvenich
Maybe EJB should be used with JSF (and blue prints 
http://java.sun.com/blueprints/code/index.html) instead of Struts.

Struts is more like this http://ibatis.com/jpetstore/jpetstore.html.
.V
Erik Price wrote:


Martin Naskovski wrote:

Hello all. Is there an app that demonstrates the use of Struts  EJB as a
persistence layer? I checked out Struts-Resume from Matt Raible, but it
uses Hibernate... Is there anything available w/EJB's? Thanks.


http://xpetstore.sf.net/

There are two implementations of Xpetstore, one that uses EJB and one 
that just uses servlets.  Check out the EJB one, it works great with JBoss.

Note, I personally don't think that using EJB is fundamentally different 
from any other persistence layer, at least not in reference to Struts, 
so you should be able to look at just about any sample code and figure 
out some best practices.  It all boils down to the fact that you have 
Struts Actions, which receive HTTP requests from the client, and which 
then delegate the work to other objects.  Whether those objects are 
session beans that perform some task by calling EJB or Hibernate 
objects, or whether you're going the simple route (what I'm doing b/c my 
needs are so trivial) and just having your Struts Actions directly 
manipulate Data Access Objects which use JDBC business delegates, it's 
not really much different.

The only big difference I've seen is that some people believe you should 
abstract your model into a layer just beyond Struts Actions so that you 
can switch from Struts to another framework if necessary.  But the other 
line of reasoning is that this is a lot of extra work if you have no 
plans to leave Struts.

My 2 cents.

Erik
--
Vic Cekvenich,
Struts Instructor,
1-800-917-JAVA
Advanced a href =baseBeans.comStruts Training/a, mentoring and 
project recovery in North East.
Open Source a href =baseBeans.comPortal Content Management/a 
basicPortal  software.



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


RE: Html Form Tag Question

2003-08-01 Thread Jones, Marty B.
Thanks Michael.

-Original Message-
From: Michael Ruppin [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:40 AM
To: Struts Users Mailing List
Subject: Re: Html Form Tag Question


I don't know if it was resolved, but this thread
should be of interest to you:

http://marc.theaimsgroup.com/?l=struts-userm=105943092932593w=2

HTH

m

--- Jones, Marty B. [EMAIL PROTECTED]
wrote:
 I have the following tag declaration in a jsp file:
 
 html:form name=loginForm action=/login
 focus=username method=POST
 type=com.dailyaccess.actions.LoginBean
 
 The jsp compiles correct and views correctly.  The
 issue that I am having is
 that the action attribute in the html form that is
 created is an empty
 string!  It is as if the FormTag class is not
 setting the action string.
 
 Any help would be greatly appreciated.
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

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



Date format

2003-08-01 Thread Silverio Wagner Silva(Secorp)
A beginner question:

When my date field is shown in my jsp it appears in a different way,
although my Locale object is correctly set.

Anyone knows how to solve this problem?

Thanks.




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



RE: Html Form Tag Question

2003-08-01 Thread Jones, Marty B.
Chuck,

Sure enough, that was it.  The action attribute is now being set as it
should.

Thanks for all your help.

-Original Message-
From: Canning, Chuck [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:49 AM
To: 'Struts Users Mailing List'
Subject: RE: Html Form Tag Question


Hey,

I had the same syptoms and the problem was an incorrect servlet-mapping in
my web.xml. We had /*.do instead of *.do. because of that, the
RequestUtils.getActionMappingURL() would not parse the action correctly. YOu
might want to start looking there.

Chuck

-Original Message-
From: Michael Ruppin [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:40 AM
To: Struts Users Mailing List
Subject: Re: Html Form Tag Question


I don't know if it was resolved, but this thread
should be of interest to you:

http://marc.theaimsgroup.com/?l=struts-userm=105943092932593w=2

HTH

m

--- Jones, Marty B. [EMAIL PROTECTED]
wrote:
 I have the following tag declaration in a jsp file:
 
 html:form name=loginForm action=/login
 focus=username method=POST
 type=com.dailyaccess.actions.LoginBean
 
 The jsp compiles correct and views correctly.  The
 issue that I am having is
 that the action attribute in the html form that is
 created is an empty
 string!  It is as if the FormTag class is not
 setting the action string.
 
 Any help would be greatly appreciated.
 
 
 Marty B. Jones
 Senior Software Engineer
 DailyAccess.Com
 
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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

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

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



RE: Date format

2003-08-01 Thread Tamia Ramírez
with type is your date, java.sql or java.util?

-Original Message-
From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:27 AM
To: 'Struts Users Mailing List'
Subject: Date format


A beginner question:

When my date field is shown in my jsp it appears in a different way,
although my Locale object is correctly set.

Anyone knows how to solve this problem?

Thanks.




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





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



RES: Date format

2003-08-01 Thread Silverio Wagner Silva(Secorp)
java.util.Date

-Mensagem original-
De: Tamia Ramírez [mailto:[EMAIL PROTECTED] 
Enviada em: sexta-feira, 1 de agosto de 2003 13:33
Para: Struts Users Mailing List
Assunto: RE: Date format

with type is your date, java.sql or java.util?

-Original Message-
From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:27 AM
To: 'Struts Users Mailing List'
Subject: Date format


A beginner question:

When my date field is shown in my jsp it appears in a different way,
although my Locale object is correctly set.

Anyone knows how to solve this problem?

Thanks.




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





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

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



NoSuchMethodException

2003-08-01 Thread Kamholz, Keith (corp-staff) USX
Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right?
Anyway, when I submit the form, I get a NoSuchMethod error.  What would
cause this?  All of my regular validations work, just not this custom one.
Here are some code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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



question about data formating using display taglib

2003-08-01 Thread victor gusz
Hi,

Has anyone used display taglib from the following
address:
http://edhill.its.uiowa.edu/

It seems this tag does not have data-formating ability
to
align titles or data. Does anyone konw a workaround
about this?

regards,



__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



RE: Date format

2003-08-01 Thread Tamia Ramírez
THIS CODE BECOME A JAVA.UTIL.DATE WITH FORMAT: dd/MM/ to a date MMM dd,
:

SimpleDateFormat dateFormatter = new SimpleDateFormat(MMM dd, );
String new_Date = dateFormatter.format(myDate);
reservacion.setFechaSalString(new_Date);

you may need to import java.text first.

I hope it can help to you too... it works for me.

-Original Message-
From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:33 AM
To: 'Struts Users Mailing List'
Subject: RES: Date format


java.util.Date

-Mensagem original-
De: Tamia Ramírez [mailto:[EMAIL PROTECTED]
Enviada em: sexta-feira, 1 de agosto de 2003 13:33
Para: Struts Users Mailing List
Assunto: RE: Date format

with type is your date, java.sql or java.util?

-Original Message-
From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:27 AM
To: 'Struts Users Mailing List'
Subject: Date format


A beginner question:

When my date field is shown in my jsp it appears in a different way,
although my Locale object is correctly set.

Anyone knows how to solve this problem?

Thanks.




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





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

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





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



Conversion to 1.1 troubles

2003-08-01 Thread Slattery, Tim - BLS
I'm trying to swich from version 1.0.2 to version 1.1 of Struts. I've
downloaded the new version and replaced the *.tld files in my web-inf
directory, and the *.jar files in web-inf\lib. 

When I try to run my system, I get a strange error. This system uses
bean:define... tags, which worked fine in the older version. The very
first page to appear has two of them. One of them - which one I can't tell -
gives this error message:

Root cause of ServletException
javax.servlet.jsp.JspTagException: Since tag class
org.apache.struts.taglib.bean
.DefineTag does not implement BodyTag, it cannot return
BodyTag.EVAL_BODY_BUFFERED

If I remove one of the two bean:define... tags - either one - the page
displays, although some data is missing. Then I go on to the next page,
which has a single bean:define... tag. That page dies with the same odd
message.

Does anybody know what's gong on here?

--
Tim Slattery
[EMAIL PROTECTED]


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



Using Struts Validator on Map-backed ActionForms

2003-08-01 Thread Cordingley, Charles
Hi,

I am trying to use the Struts Validator to generate Javascript validation on
a Map-backed action form, but I keep getting type is null or not an object
javascript error (I am using Struts 1.1). Non map-backed properties on the
form work fine.

In the JSP I am creating text boxes using:

html:text style=WIDTH: 75px; text-align: right
property='%=volume(+act.getActivityID()+)%'
value='%=+scenAct.getActivityVolume()%'/

and have this method on the action form to get it:

public void setVolume(String key, Object value) {
   volumes.put(key, value);
}

In the validation.xml I have tried:

field property=volume()
   depends=required
   arg0 key=/
/field

and:

field property=volume()
   depends=required
   arg0 key=/
/field

but both result in the error.

Does anyone know how to do this?

Thanks,
Charles.



The Royal Bank of Scotland plc ('the Bank') is regulated by the Financial 
Services Authority and is a member of The Royal Bank of Scotland Marketing
Group.  The only packaged products (life policies, unit trusts and other
collective investment schemes and stakeholder and other pensions) the Bank
advises on and sells are those of the Marketing Group, whose other members
are Royal Scottish Assurance plc and Royal Bank of Scotland Unit Trust
Management Limited, both regulated by the Financial Services Authority.

The Royal Bank of Scotland plc. Registered in Scotland No 90312.  Registered
Office: 36 St Andrew Square, Edinburgh EH2 2YB. 

Agency agreements exist between members of The Royal Bank of Scotland Group.

This e-mail message is confidential and for use by the addressee only. If
the message is received by anyone other than the addressee, please return
the message to the sender by replying to it and then delete the message from
your computer. Internet e-mails are not necessarily secure. The Royal Bank
of Scotland plc does not accept responsibility for changes made to this
message after it was sent. 

Whilst all reasonable care has been taken to avoid the transmission of
viruses, it is the responsibility of the recipient to ensure that the onward
transmission, opening or use of this message and any attachments will not
adversely affect its systems or data. No responsibility is accepted by The
Royal Bank of Scotland plc in this regard and the recipient should carry out
such virus and other checks as it considers appropriate.


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



Re: Conversion to 1.1 troubles

2003-08-01 Thread Craig R. McClanahan


On Fri, 1 Aug 2003, Slattery, Tim - BLS wrote:

 Date: Fri, 1 Aug 2003 13:13:56 -0400
 From: Slattery, Tim - BLS [EMAIL PROTECTED]
 Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
 To: Struts User List ([EMAIL PROTECTED])
 [EMAIL PROTECTED]
 Subject: Conversion to 1.1 troubles

 I'm trying to swich from version 1.0.2 to version 1.1 of Struts. I've
 downloaded the new version and replaced the *.tld files in my web-inf
 directory, and the *.jar files in web-inf\lib.

 When I try to run my system, I get a strange error. This system uses
 bean:define... tags, which worked fine in the older version. The very
 first page to appear has two of them. One of them - which one I can't tell -
 gives this error message:

 Root cause of ServletException
 javax.servlet.jsp.JspTagException: Since tag class
 org.apache.struts.taglib.bean
 .DefineTag does not implement BodyTag, it cannot return
 BodyTag.EVAL_BODY_BUFFERED

 If I remove one of the two bean:define... tags - either one - the page
 displays, although some data is missing. Then I go on to the next page,
 which has a single bean:define... tag. That page dies with the same odd
 message.

 Does anybody know what's gong on here?

One very important step that you must do (and perhaps already have, but
didn't mention) is recompile your application against the new Struts JAR
files.  Failure to do this will lead to all sorts of problems because of
changes in the internal inheritance hierarchy, and this kind of error
message is the sort of thing you can expect to see if you don't recompile.


 --
 Tim Slattery
 [EMAIL PROTECTED]

Craig

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



RE: Using Struts Validator on Map-backed ActionForms

2003-08-01 Thread Yansheng Lin

I don't think this is legal, i.e., you can not have a bracket inside of property
attribute:

field property=volume()

You form should have the getter method for getVolume().  


-Original Message-
From: Cordingley, Charles [mailto:[EMAIL PROTECTED] 
Sent: August 1, 2003 11:24 AM
To: '[EMAIL PROTECTED]'
Subject: Using Struts Validator on Map-backed ActionForms


Hi,

I am trying to use the Struts Validator to generate Javascript validation on
a Map-backed action form, but I keep getting type is null or not an object
javascript error (I am using Struts 1.1). Non map-backed properties on the
form work fine.

In the JSP I am creating text boxes using:

html:text style=WIDTH: 75px; text-align: right
property='%=volume(+act.getActivityID()+)%'
value='%=+scenAct.getActivityVolume()%'/

and have this method on the action form to get it:

public void setVolume(String key, Object value) {
   volumes.put(key, value);
}

In the validation.xml I have tried:

field property=volume()
   depends=required
   arg0 key=/
/field

and:

field property=volume()
   depends=required
   arg0 key=/
/field

but both result in the error.

Does anyone know how to do this?

Thanks,
Charles.



The Royal Bank of Scotland plc ('the Bank') is regulated by the Financial 
Services Authority and is a member of The Royal Bank of Scotland Marketing
Group.  The only packaged products (life policies, unit trusts and other
collective investment schemes and stakeholder and other pensions) the Bank
advises on and sells are those of the Marketing Group, whose other members
are Royal Scottish Assurance plc and Royal Bank of Scotland Unit Trust
Management Limited, both regulated by the Financial Services Authority.

The Royal Bank of Scotland plc. Registered in Scotland No 90312.  Registered
Office: 36 St Andrew Square, Edinburgh EH2 2YB. 

Agency agreements exist between members of The Royal Bank of Scotland Group.

This e-mail message is confidential and for use by the addressee only. If
the message is received by anyone other than the addressee, please return
the message to the sender by replying to it and then delete the message from
your computer. Internet e-mails are not necessarily secure. The Royal Bank
of Scotland plc does not accept responsibility for changes made to this
message after it was sent. 

Whilst all reasonable care has been taken to avoid the transmission of
viruses, it is the responsibility of the recipient to ensure that the onward
transmission, opening or use of this message and any attachments will not
adversely affect its systems or data. No responsibility is accepted by The
Royal Bank of Scotland plc in this regard and the recipient should carry out
such virus and other checks as it considers appropriate.


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


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



nested forms

2003-08-01 Thread imran ali
HI All
 I have a form which contains an array of other forms 
along with other data. I am putting this form in session. when I 
submit I am writing data to database and then removing the form 
from session. and going to another page. Now if user hit on BACK 
button of browser, It takes him to earliar page and user have a 
choice of hitting the submit button again. If he does he gets an 
exception:

java.lang.ArrayIndexOutOfBoundsException
	at java.lang.reflect.Array.get(Native Method)
	at 
org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils.java:525)
	at 
org.apache.commons.beanutils.PropertyUtils.getIndexedProperty(PropertyUtils.java:428)
	at 
org.apache.commons.beanutils.PropertyUtils.getNestedProperty(PropertyUtils.java:770)
	at 
org.apache.commons.beanutils.PropertyUtils.getProperty(PropertyUtils.java:801)
	at 
org.apache.commons.beanutils.BeanUtils.setProperty(BeanUtils.java:881)
..

  How can I get rid of it. Please help .

Imran.

Imran
___
Download the hottest  happening ringtones here!
OR SMS: Top tone to 7333
Click here now: 
http://sms.rediff.com/cgi-bin/ringtone/ringhome.pl



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


RE: question about data formating using display taglib

2003-08-01 Thread Yansheng Lin

Yes it does.  

style type=text/css 
.tableRowHeader {
 align:center;
}
.tableRowOdd {
 align:center;
}
.tableRowEven {
 align:center;
}

...
/style

-Original Message-
From: victor gusz [mailto:[EMAIL PROTECTED] 
Sent: August 1, 2003 11:05 AM
To: [EMAIL PROTECTED]
Subject: question about data formating using display taglib


Hi,

Has anyone used display taglib from the following
address:
http://edhill.its.uiowa.edu/

It seems this tag does not have data-formating ability
to
align titles or data. Does anyone konw a workaround
about this?

regards,



__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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


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



RE: Conversion to 1.1 troubles

2003-08-01 Thread Slattery, Tim - BLS
 I'm trying to swich from version 1.0.2 to version 1.1 of Struts. I've
 downloaded the new version and replaced the *.tld files in my web-inf
 directory, and the *.jar files in web-inf\lib. 
 
 When I try to run my system, I get a strange error. This system uses
 bean:define... tags, which worked fine in the older 
 version. The very first page to appear has two of them. One of them -
which one 
 I can't tell - gives this error message:

I seem to have figured it out. Apparently, I've got my container (WebLogic7,
running on my own desktop, for development) set to retain previously
compiled JSP pages - even when I shut the server down and start it up again!
If I make a trivial change in a page that's reporting this odd error - even
just insert a space someplace, then immediately delete it again - WebLogic
recompiles the page, and the error disappears.

Good grief!


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



Calling a tiles definition from a jsp?

2003-08-01 Thread David Erickson
We've got all our tiles definitions in tiles-def.xml in the web-inf folder,
and we were wondering if it is possible to somehow call a definition and
load it from a jsp?

For example if a user comes to our site thats not logged in we wanted to
direct him to a jsp that uses one of our tiles def's like .app.Home  instead
of forwarding to a blank action that all it does is forward a user to that
same definition.  Is this possible at all or do I have to go through an
action.
Thanks


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



RE: question about data formating using display taglib

2003-08-01 Thread victor gusz
Thanks,

Does it? How do you use this stylesheet in its
display:table
display:column

tags? The following stylesheet is used in its
examples'
html pages, its not in its jsp source, just because
its
tags cannot format data? Maybe I am just not clear
about this, please clarify.

regards,

Victor


--- Yansheng Lin [EMAIL PROTECTED] wrote:
 
 Yes it does.  
 
 style type=text/css 
 .tableRowHeader {
align:center;
 }
 .tableRowOdd {
  align:center;
 }
 .tableRowEven {
  align:center;
 }
 
 ...
 /style
 
 -Original Message-
 From: victor gusz [mailto:[EMAIL PROTECTED] 
 Sent: August 1, 2003 11:05 AM
 To: [EMAIL PROTECTED]
 Subject: question about data formating using display
 taglib
 
 
 Hi,
 
 Has anyone used display taglib from the following
 address:
 http://edhill.its.uiowa.edu/
 
 It seems this tag does not have data-formating
 ability
 to
 align titles or data. Does anyone konw a workaround
 about this?
 
 regards,
 
 
 
 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site
 design software
 http://sitebuilder.yahoo.com
 

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

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



another question display taglib: its requestURI

2003-08-01 Thread victor gusz


Hi,  
Has anyone used display taglib from the following
address: 

http://edhill.its.uiowa.edu/ 

How do you specify the requestURI parameter of
display:table if I want to display multiple pages
if number of results is huge? The taglib's examples 
seem to link results pages to different pages, is it a
bug or so?


regards,
 
 
 
 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site
 design software
 http://sitebuilder.yahoo.com
 

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



RE: question about data formating using display taglib

2003-08-01 Thread Yansheng Lin
It's the default classname for the rows and columns, etc. if you take a look at
the source code.  
Presentation in html should be separated from the content, that's what css is
all about:).  Try CSS, you will discover the power of it.

Use the style anywhere you want, external, internal, as long as your jsp page
refers to it, it's going to render it.

Hope this helps!



-Original Message-
From: victor gusz [mailto:[EMAIL PROTECTED] 
Sent: August 1, 2003 12:22 PM
To: Struts Users Mailing List
Subject: RE: question about data formating using display taglib


Thanks,

Does it? How do you use this stylesheet in its
display:table
display:column

tags? The following stylesheet is used in its
examples'
html pages, its not in its jsp source, just because
its
tags cannot format data? Maybe I am just not clear
about this, please clarify.

regards,

Victor


--- Yansheng Lin [EMAIL PROTECTED] wrote:
 
 Yes it does.  
 
 style type=text/css 
 .tableRowHeader {
align:center;
 }
 .tableRowOdd {
  align:center;
 }
 .tableRowEven {
  align:center;
 }
 
 ...
 /style
 
 -Original Message-
 From: victor gusz [mailto:[EMAIL PROTECTED] 
 Sent: August 1, 2003 11:05 AM
 To: [EMAIL PROTECTED]
 Subject: question about data formating using display
 taglib
 
 
 Hi,
 
 Has anyone used display taglib from the following
 address:
 http://edhill.its.uiowa.edu/
 
 It seems this tag does not have data-formating
 ability
 to
 align titles or data. Does anyone konw a workaround
 about this?
 
 regards,
 
 
 
 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site
 design software
 http://sitebuilder.yahoo.com
 

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

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


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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


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



RE: Calling a tiles definition from a jsp?

2003-08-01 Thread Mike Jasnowski
You could put the tile-def on the JSP

-Original Message-
From: David Erickson [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 2:11 PM
To: Struts Mailing List
Subject: Calling a tiles definition from a jsp?


We've got all our tiles definitions in tiles-def.xml in the web-inf folder,
and we were wondering if it is possible to somehow call a definition and
load it from a jsp?

For example if a user comes to our site thats not logged in we wanted to
direct him to a jsp that uses one of our tiles def's like .app.Home  instead
of forwarding to a blank action that all it does is forward a user to that
same definition.  Is this possible at all or do I have to go through an
action.
Thanks


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



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



RE: JSTL and Struts

2003-08-01 Thread Stephen Brown
Since you are relying on the browser anyways, I'd use javascript for this.
The numbers would stay formatted as you change them then.  As a caveat, you
really need to check the values on the server side afterwards.

Steve

 -Original Message-
 From: Mainguy, Mike [mailto:[EMAIL PROTECTED]
 Sent: July 31, 2003 12:23 PM
 To: 'Struts Users Mailing List'
 Subject: RE: JSTL and Struts
 
 
 exactly
 
 -Original Message-
 From: Erik Price [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, July 31, 2003 12:16 PM
 To: Struts Users Mailing List
 Subject: Re: JSTL and Struts
 
 
 
 Mainguy, Mike wrote:
  When I return a currency or date value, the client has a 
 specific format
  they want it in.  i.e. $1,000.000 or 02/02/2003.  
 
 Do you mean you are using an input tag for display purposes (i.e. 
 returning data to the browser with an input tag that has a 
 default value).
 
 
 Erik
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 This message and its contents (to include attachments) are 
 the property of Kmart Corporation (Kmart) and may contain 
 confidential and proprietary information. You are hereby 
 notified that any disclosure, copying, or distribution of 
 this message, or the taking of any action based on 
 information contained herein is strictly prohibited. 
 Unauthorized use of information contained herein may subject 
 you to civil and criminal prosecution and penalties. If you 
 are not the intended recipient, you should delete this 
 message immediately.
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


RE: question about data formating using display taglib

2003-08-01 Thread victor gusz
Thanks,

You are right. But it seems it only renders internal 
stylesheets. 

regards,




--- Yansheng Lin [EMAIL PROTECTED] wrote:
 It's the default classname for the rows and columns,
 etc. if you take a look at
 the source code.  
 Presentation in html should be separated from the
 content, that's what css is
 all about:).  Try CSS, you will discover the power
 of it.
 
 Use the style anywhere you want, external, internal,
 as long as your jsp page
 refers to it, it's going to render it.
 
 Hope this helps!
 
e.org
 


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



2 different submits on a single JSP - how?

2003-08-01 Thread yan
Not sure how best to set this up and indeed, if it is possible so any advice
would be appreciated.



I have an ActionForm called 'RegisterForm' that allows a new user to enter
their details (name, email, school name and school address) or, an existing
registered user to edit these fields.



Alongside the 'school address' field I have a submit button, 'Find School'
that allows a user to enter part of the school name or address and hit this
'FindSchool' button which then goes off to another page (selectSchool.jsp)
that displays a list of matching schools.  The user then clicks on their
chosen school on selectSchool.jsp and is then returned to the RegisterForm
with the 'school name' and 'school address' fields populated.



The user then hits another submit (either 'Register Me' or 'Update Details')
button at the bottom of the page which saves the user details.



My query is this: I am aware that I have 2 html: form action =someAction
's, one for the 'Find School' submit button and one for the 'Register
Me/Update Details' submit button.



I have only seen examples where you have a single html: form action =
someAction tag on a jsp.  Any advice or examples on how I can do it with
the 2 actions that I need on my one JSP



Thanks in advance

yan


KickStartESolutions.com
[EMAIL PROTECTED]



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



Re: ActionForm Design Question

2003-08-01 Thread Jing Zhou

- Original Message - 
From: Caroline Jen [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Friday, August 01, 2003 10:42 AM
Subject: ActionForm Design Question


 Hi, I am building a web site.  The primary functions
 of this site are for authors to submit their research
 papers.  The research papers will go through a
 screening process (screened by peers in the field). 
 Visiors can view the published articles online.
 
 Authors and peers are the registered users of the web
 site.
 
 Therefore, there is not much data manipulation at the
 web site except that authors may be requested to
 revise their papers and re-submit.  And both authors
 and peers have to fill out registration forms to
 become members of the web site.
 
 The content of the registration form is pretty
 standard: name, address, phone number, academic
 background information and achievements, etc.  Most of
 them are Strings.  A couple of checkboxes, three sets
 of radio buttons (to indicate preferences), and a
 primitive double.  Of course, I have a text field for
 loading research papers.
 
 Question 1: Do I use conventional ActionForm?
 Map-backed ActionForm? or DynaActionForm for this
 project?

If I were you, I would use the conventional ActionForm if
most of the properties are Strings.

 
 Question 2: Which strategy should I use to transfer
 values between tiers?  Setting an immutable value
 object?  or transferring values by reflection
 (BeanUtil)? or passing a Map?

Then I would use the transerring mechanism in the
BeanUtil package.

 
 I highly value your opinions and advices.  Thanks.
 

Jing
Netspread Carrier
http://www.netspread.com


 __
 Do you Yahoo!?
 Yahoo! SiteBuilder - Free, easy-to-use web site design software
 http://sitebuilder.yahoo.com
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



RE: 2 different submits on a single JSP - how?

2003-08-01 Thread Marcos Oliva
Yan, 


Why not use a windowpop up javascript for your school search and then
set the school var on the parent page then submit the form

marcos

-Original Message-
From: yan [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 10:18 AM
To: [EMAIL PROTECTED]
Subject: 2 different submits on a single JSP - how?

Not sure how best to set this up and indeed, if it is possible so any
advice
would be appreciated.



I have an ActionForm called 'RegisterForm' that allows a new user to
enter
their details (name, email, school name and school address) or, an
existing
registered user to edit these fields.



Alongside the 'school address' field I have a submit button, 'Find
School'
that allows a user to enter part of the school name or address and hit
this
'FindSchool' button which then goes off to another page
(selectSchool.jsp)
that displays a list of matching schools.  The user then clicks on their
chosen school on selectSchool.jsp and is then returned to the
RegisterForm
with the 'school name' and 'school address' fields populated.



The user then hits another submit (either 'Register Me' or 'Update
Details')
button at the bottom of the page which saves the user details.



My query is this: I am aware that I have 2 html: form action
=someAction
's, one for the 'Find School' submit button and one for the 'Register
Me/Update Details' submit button.



I have only seen examples where you have a single html: form action =
someAction tag on a jsp.  Any advice or examples on how I can do it
with
the 2 actions that I need on my one JSP



Thanks in advance

yan


KickStartESolutions.com
[EMAIL PROTECTED]



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


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



RE: 2 different submits on a single JSP - how?

2003-08-01 Thread James Childers
Use JavaScript to change the submit action based upon the criteria you listed:

function doSubmit() {
if (someCondition) {
document.yourForm.action = 'html:rewrite action=/actionNumeroUno 
/';
} else {
document.yourForm.action = 'html:rewrite action=/actionNumeroDos 
/';
}
}

-= J


 -Original Message-
 From: yan [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 12:18 PM
 To: [EMAIL PROTECTED]
 Subject: 2 different submits on a single JSP - how?
 
 
 Not sure how best to set this up and indeed, if it is 
 possible so any advice
 would be appreciated.
 
 
 
 I have an ActionForm called 'RegisterForm' that allows a new 
 user to enter
 their details (name, email, school name and school address) 
 or, an existing
 registered user to edit these fields.
 
 
 
 Alongside the 'school address' field I have a submit button, 
 'Find School'
 that allows a user to enter part of the school name or 
 address and hit this
 'FindSchool' button which then goes off to another page 
 (selectSchool.jsp)
 that displays a list of matching schools.  The user then 
 clicks on their
 chosen school on selectSchool.jsp and is then returned to the 
 RegisterForm
 with the 'school name' and 'school address' fields populated.
 
 
 
 The user then hits another submit (either 'Register Me' or 
 'Update Details')
 button at the bottom of the page which saves the user details.
 
 
 
 My query is this: I am aware that I have 2 html: form action 
 =someAction
 's, one for the 'Find School' submit button and one for the 'Register
 Me/Update Details' submit button.
 
 
 
 I have only seen examples where you have a single html: form 
 action =
 someAction tag on a jsp.  Any advice or examples on how I 
 can do it with
 the 2 actions that I need on my one JSP
 
 
 
 Thanks in advance
 
 yan
 
 
 KickStartESolutions.com
 [EMAIL PROTECTED]
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 

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



RE: NoSuchMethodException

2003-08-01 Thread Kamholz, Keith (corp-staff) USX
Well, so much for the helpfulness of this list.

I politely asked a few completely reasonable questions in the past few days,
and they were questions that could easily be of interest to others as well.
They were also pretty simple issues that I'm sure other people have
encountered or would have some sort of input on.
Maybe people just ignore my posts or something, but I've been trying all
week to get couple simple answers, and I'm not seeing any interest from
anyone.

Maybe it's just a waste of time posting here.  You'll probably say I'm just
being in patient, but this list has such a fast turnaround that if a post is
not addressed within a few hours, it most likely won't be addressed at all.

You'll have to forgive my frustration.  Long work days trying to figure
things out with no end in sight, and no help from coworkers or the list can
drive one mad.


- Keith



-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 12:40 PM
To: Struts (E-mail)
Subject: NoSuchMethodException


Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right?
Anyway, when I submit the form, I get a NoSuchMethod error.  What would
cause this?  All of my regular validations work, just not this custom one.
Here are some code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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

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



RE: 2 different submits on a single JSP - how?

2003-08-01 Thread Tamia Ramírez
Give a different value to every submit... in your form make just one submit
and ask for its value, so you can know with one they chosse:

input type=submit value=Login
input type=submit value=request

-Original Message-
From: yan [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 11:18 AM
To: [EMAIL PROTECTED]
Subject: 2 different submits on a single JSP - how?


Not sure how best to set this up and indeed, if it is possible so any advice
would be appreciated.



I have an ActionForm called 'RegisterForm' that allows a new user to enter
their details (name, email, school name and school address) or, an existing
registered user to edit these fields.



Alongside the 'school address' field I have a submit button, 'Find School'
that allows a user to enter part of the school name or address and hit this
'FindSchool' button which then goes off to another page (selectSchool.jsp)
that displays a list of matching schools.  The user then clicks on their
chosen school on selectSchool.jsp and is then returned to the RegisterForm
with the 'school name' and 'school address' fields populated.



The user then hits another submit (either 'Register Me' or 'Update Details')
button at the bottom of the page which saves the user details.



My query is this: I am aware that I have 2 html: form action =someAction
's, one for the 'Find School' submit button and one for the 'Register
Me/Update Details' submit button.



I have only seen examples where you have a single html: form action =
someAction tag on a jsp.  Any advice or examples on how I can do it with
the 2 actions that I need on my one JSP



Thanks in advance

yan


KickStartESolutions.com
[EMAIL PROTECTED]



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





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



Re: 2 different submits on a single JSP - how?

2003-08-01 Thread Gregory F. March

On Aug 1, 2003, yan [EMAIL PROTECTED]  wrote:

 |My query is this: I am aware that I have 2 html: form action =someAction
 |'s, one for the 'Find School' submit button and one for the 'Register
 |Me/Update Details' submit button.

The way I did this was to use a LookupDispatchAction and have both
submits call the same action.  The LookupDispatchAction will decided
which execute method to call.

/greg

--
Gregory F. March-=-http://www.gfm.net:81/~march-=-AIM:GfmNet

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



RE: NoSuchMethodException

2003-08-01 Thread Yee, Richard K,,DMDCWEST
How about supplying more information like the name of the method that is not
being found?

Regards,

Richard

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 12:00 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


Well, so much for the helpfulness of this list.

I politely asked a few completely reasonable questions in the past few days,
and they were questions that could easily be of interest to others as well.
They were also pretty simple issues that I'm sure other people have
encountered or would have some sort of input on. Maybe people just ignore my
posts or something, but I've been trying all week to get couple simple
answers, and I'm not seeing any interest from anyone.

Maybe it's just a waste of time posting here.  You'll probably say I'm just
being in patient, but this list has such a fast turnaround that if a post is
not addressed within a few hours, it most likely won't be addressed at all.

You'll have to forgive my frustration.  Long work days trying to figure
things out with no end in sight, and no help from coworkers or the list can
drive one mad.


- Keith



-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 12:40 PM
To: Struts (E-mail)
Subject: NoSuchMethodException


Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right? Anyway,
when I submit the form, I get a NoSuchMethod error.  What would cause this?
All of my regular validations work, just not this custom one. Here are some
code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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

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

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



RE: NoSuchMethodException

2003-08-01 Thread Kamholz, Keith (corp-staff) USX
Hey,
Thanks a bunch for the reply.  It's the validateRange method that's not
being found, the one responsible for doing the validation.
Has anyone else run into anything like this while trying to do custom
validation?

- Keith



-Original Message-
From: Yee, Richard K,,DMDCWEST [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 3:06 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


How about supplying more information like the name of the method that is not
being found?

Regards,

Richard

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 12:00 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


Well, so much for the helpfulness of this list.

I politely asked a few completely reasonable questions in the past few days,
and they were questions that could easily be of interest to others as well.
They were also pretty simple issues that I'm sure other people have
encountered or would have some sort of input on. Maybe people just ignore my
posts or something, but I've been trying all week to get couple simple
answers, and I'm not seeing any interest from anyone.

Maybe it's just a waste of time posting here.  You'll probably say I'm just
being in patient, but this list has such a fast turnaround that if a post is
not addressed within a few hours, it most likely won't be addressed at all.

You'll have to forgive my frustration.  Long work days trying to figure
things out with no end in sight, and no help from coworkers or the list can
drive one mad.


- Keith



-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 12:40 PM
To: Struts (E-mail)
Subject: NoSuchMethodException


Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right? Anyway,
when I submit the form, I get a NoSuchMethod error.  What would cause this?
All of my regular validations work, just not this custom one. Here are some
code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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

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

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

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



RE: NoSuchMethodException

2003-08-01 Thread Alex Shneyderman
Just a quick guess your paramaters are probably messed up?
This is what you have in your descriptor
 java.lang.Object,
org.apache.commons.validator.ValidatorAction,
org.apache.commons.validator.Field,
org.apache.struts.action.ActionErrors,
javax.servlet.http.HttpServletRequest,
javax.servlet.ServletContext 
   
and this is what you have in your method

 Object bean, ValidatorAction va,
 
   Field field, ActionErrors
errors,
 HttpServletRequest request)

How do you expect Validator to find the method?
Go home take some rest you will think clearer :-)


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



RE: NoSuchMethodException

2003-08-01 Thread Yee, Richard K,,DMDCWEST
Keith,
Yes, I think you are missing the javax.servlet.ServletContext in your method
signature
Or your methodParams has an extra parameter.

-Richard


-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 12:07 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


Hey,
Thanks a bunch for the reply.  It's the validateRange method that's not
being found, the one responsible for doing the validation. Has anyone else
run into anything like this while trying to do custom validation?

- Keith



-Original Message-
From: Yee, Richard K,,DMDCWEST [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 3:06 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


How about supplying more information like the name of the method that is not
being found?

Regards,

Richard

-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: Friday, August 01, 2003 12:00 PM
To: 'Struts Users Mailing List'
Subject: RE: NoSuchMethodException


Well, so much for the helpfulness of this list.

I politely asked a few completely reasonable questions in the past few days,
and they were questions that could easily be of interest to others as well.
They were also pretty simple issues that I'm sure other people have
encountered or would have some sort of input on. Maybe people just ignore my
posts or something, but I've been trying all week to get couple simple
answers, and I'm not seeing any interest from anyone.

Maybe it's just a waste of time posting here.  You'll probably say I'm just
being in patient, but this list has such a fast turnaround that if a post is
not addressed within a few hours, it most likely won't be addressed at all.

You'll have to forgive my frustration.  Long work days trying to figure
things out with no end in sight, and no help from coworkers or the list can
drive one mad.


- Keith



-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED]
Sent: Friday, August 01, 2003 12:40 PM
To: Struts (E-mail)
Subject: NoSuchMethodException


Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right? Anyway,
when I submit the form, I get a NoSuchMethod error.  What would cause this?
All of my regular validations work, just not this custom one. Here are some
code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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

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

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

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

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



RE: Please Help With Simple Tiles Problem

2003-08-01 Thread Terry Brick
Thanks for your response David.  Correct me if I'm
wrong, but isn't this exactly what I had in my
example?  Maybe I'm just not grasping something...  
It looks to me like I'm still having to add two
definition blocks for each form I want to add. 
Under your form_page definition you point to form1
-OR- form2. But in reality can't you only have one or
the other?  I have an struts action pointing to each
form so wouldn't I have to do something like...


 definition name=page path=page.jsp/
 
 definition name=form_page1 extends=page
put name=body value=form1
 /definition
 
 definition name=form_page2 extends=page
put name=body value=form2
 /definition

 definition name=form1 path=form_wrapper.jsp
put name=body value=form1.jsp/
 definition
 
 definition name=form2 path=form_wrapper.jsp
put name=body value=form2.jsp/
 definition


So I would have an action pointing to form_page1 and
an action pointing two form_page2.  But I would have
to add two definitions to my tiles-config file for
each form.  It just seems redundant to me.

Sorry if I'm being dense, your patience is much
appreciated :-)



--- David Tobey [EMAIL PROTECTED] wrote:
 Can you just create a generic definition for a form
 page. Then, switch out
 what you put for the body. Like this:
 
 definition name=page path=page.jsp/
 
 definition name=form_page extends=page
   put name=body value=form1
   -- OR: put name=body value=form2 --
 /definition
 
 definition name=form1 path=form_wrapper.jsp
put name=body value=form1.jsp/
 definition
 
 definition name=form2 path=form_wrapper.jsp
put name=body value=form2.jsp/
 definition
 
 ... etc ...
 
 Now you must create one new definition for each
 form, but to use a different
 one, just change what you use for the body of the
 form_page.
 
 dave
 
 
  -Original Message-
  From: Terry Brick
 [mailto:[EMAIL PROTECTED]
  Sent: Thursday, July 31, 2003 10:55 PM
  To: Struts Users Mailing List
  Subject: Re: Please Help With Simple Tiles Problem
 
 
  Ok, I've finally gotten this to work.  However, I
  don't think it's the right solution and it's
  certainly not one I'm happy with.  But maybe by
  showing how I'm getting it to work, that will
 better
  communicate to people what I'm trying SO HARD to
 do.
 
  This works:
 
  definition name=page path=page.jsp/
 
  definition name=form1 extends=page
 put name=body value=form1a/
  definition
 
  definition name=form1a path=form_wrapper.jsp
 put name=form-body value=form1.jsp/
  /definition
 
  So this gives me...
  page.jsp
form_wrapper.jsp
  form1.jsp/
/form_wrapper.jsp
  /page.jsp
 
  The problem is that form1.jsp will not always be
  form1.jsp.  I want to be able to swap that for a
  form2.jsp, form3.jsp, etc.  Using this method,
 I
  would have to add TWO definitions into the
  tile-defs.xml for each new form I wanted!  (form2,
  form2a, form3, form3a, etc)
  There must be a better way where I only have to
 add a
  single definition for each new form.  Any ideas?
  Advice is much appreciated. Thanks.
 
 
 
 
  __
  Do you Yahoo!?
  Yahoo! SiteBuilder - Free, easy-to-use web site
 design software
  http://sitebuilder.yahoo.com
 
 


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



RE: NoSuchMethodException

2003-08-01 Thread Yansheng Lin
I can see there are several issues here.  First I think you might want to supply
the ServletContext as well.  Second, you want to add the error to Errors
collection by adding:
errors.add(field.getKey(), ValidatorUtil.getActionError(servletContext,
request, va, field));
before the return statement. 

Try it.  I spent a lot of time before on this too.


-Original Message-
From: Kamholz, Keith (corp-staff) USX [mailto:[EMAIL PROTECTED] 
Sent: August 1, 2003 10:40 AM
To: Struts (E-mail)
Subject: NoSuchMethodException


Hey everyone,
I'm working on a custom validator right now, and all the validation method
does is return false.  That means it fails that validation, right?
Anyway, when I submit the form, I get a NoSuchMethod error.  What would
cause this?  All of my regular validations work, just not this custom one.
Here are some code snippets.  Thanks in advance for any help!

public class CustomValidator implements Serializable 
{
public static boolean validateRange(Object bean, ValidatorAction va,

Field field, ActionErrors errors,
HttpServletRequest request)
{
return false;
}
}


validator-rules.xml:

  !-- Custom Validators --
  
  validator name=validRange
classname=com.moog.us.app.ans.validation.CustomValidator
   method=validateRange
 methodParams=java.lang.Object,
   org.apache.commons.validator.ValidatorAction,
   org.apache.commons.validator.Field,
   org.apache.struts.action.ActionErrors,
   javax.servlet.http.HttpServletRequest,
   javax.servlet.ServletContext
  msg=errors.invalid.range
  /validator


And parts of my validation.xml:

global

/global

form name=/AddAssignment
field  property=startRange
depends=required
arg0 key=app.label.startRange/
/field
field  property=endRange
depends=validRange
/field
/form




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


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



RE: Date format

2003-08-01 Thread Daniel H. F. e Silva
Hi all,

  Well, i recommend using JSTL tag formatNumber with type='currency'.
You can do this way:

  %@ taglib uri=http://java.sun.com/jstl/fmt; prefix=fmt %

  fmt:setLocale value=pt_BR/
  fmt:formatNumber value=${your_property} type=currency/

  It worked for me.

Regards,
 Daniel Silva


--- Tamia_Ramírez [EMAIL PROTECTED] wrote:
 THIS CODE BECOME A JAVA.UTIL.DATE WITH FORMAT: dd/MM/ to a date MMM dd,
 :
 
 SimpleDateFormat dateFormatter = new SimpleDateFormat(MMM dd, );
 String new_Date = dateFormatter.format(myDate);
 reservacion.setFechaSalString(new_Date);
 
 you may need to import java.text first.
 
 I hope it can help to you too... it works for me.
 
 -Original Message-
 From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 10:33 AM
 To: 'Struts Users Mailing List'
 Subject: RES: Date format
 
 
 java.util.Date
 
 -Mensagem original-
 De: Tamia Ramírez [mailto:[EMAIL PROTECTED]
 Enviada em: sexta-feira, 1 de agosto de 2003 13:33
 Para: Struts Users Mailing List
 Assunto: RE: Date format
 
 with type is your date, java.sql or java.util?
 
 -Original Message-
 From: Silverio Wagner Silva(Secorp) [mailto:[EMAIL PROTECTED]
 Sent: Friday, August 01, 2003 10:27 AM
 To: 'Struts Users Mailing List'
 Subject: Date format
 
 
 A beginner question:
 
 When my date field is shown in my jsp it appears in a different way,
 although my Locale object is correctly set.
 
 Anyone knows how to solve this problem?
 
 Thanks.
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 
 
 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


__
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com

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



  1   2   >