a bug in struts-html.tld

2002-06-11 Thread daniele rizzi


or at least that's what seems to me:

tag html:password is duplicated: may somebody remove 
the latter copy (row n.1897 onward)

thanks,
daniele rizzi


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




it happened to me too! (was R: 1.1 Deployment Bug?- Iplanet Web Server)

2002-06-11 Thread daniele rizzi



Well, something similar happens inside Oracle Jdeveloper 9i;
there's a static object that won't be initialized (ie
the jvm won't create it right); sorry I can't put my finger on it,

daniele rizzi



-Messaggio originale-
Da: Rajesh Kalluri [mailto:[EMAIL PROTECTED]]
Inviato: martedì 11 giugno 2002 15.12
A: Struts Users Mailing List
Oggetto: RE: 1.1 Deployment Bug?- Iplanet Web Server


Struts 1.0.x works fine on my Iplanet Web server (Which is more like tomcat
3.2+). But i cannot get the example from Struts 1.1 to work on Iplanet (IWS
6.0 SP2 ). Here is the stack trace.

 Internal error: Unexpected error condition thrown (unknown exception,no
description), stack: java.lang.ExceptionInInitializerError   at
_jsps._layouts._menu_jsp._jspService(_menu_jsp.java:102)   at
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)   at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)   at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.service(JspServlet.ja
va:247)   at
org.apache.jasper.servlet.JspServlet$JspServletWrapper.access$6(JspServlet.j
ava:237)   at
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:520)
at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:589)   at
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)   at
com.iplanet.server.http.servlet.NSServletRunner.invokeServletService(NSServl
etRunner.java:897)   at
com.iplanet.server.http.servlet.WebApplication.service(WebApplication.java:1
065)   at
com.iplanet.server.http.servlet.NSServletRunner.ServiceWebApp(NSServletRunne
r.java:959)   at
com.iplanet.server.http.servlet.NSServletSession.internalRedirect(Native
Method)   at
com.iplanet.server.http.servlet.NSRequestDispatcher.include(NSRequestDispatc
her.java:93)   at
org.apache.jasper.runtime.PageContextImpl.include(PageContextImpl.java:408)
at
org.apache.struts.taglib.tiles.InsertTag$InsertHandler.doEndTag(InsertTag.ja
va:757)   at
org.apache.struts.taglib.tiles.InsertTag.doEndTag(InsertTag.java:369).

The people at iplanet support would not care as they claim its not their
problem (to support external frameworks).

Of course they need to wake up.

Any one seen this issue?


Regards
Raj.

-Original Message-
From: Galbreath, Mark [mailto:[EMAIL PROTECTED]]
Sent: Monday, June 10, 2002 7:28 PM
To: Struts (E-mail)
Subject: 1.1 Deployment Bug?


Is there a known issue with deploying 1.1 apps in any servlet/Web container?
1.02 deploys just find in the WEB-INF/lib directory, but 1.1 is causing the
class loader to throw ClassNotFoundException.  We have found this to be true
in Tomcat 4.01, JRun 3.1 and WebLogic 6.1SP2.  If a work-around exists,
where is the documentation?

Mark


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



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




R: XML/XSLT Question - Help!

2002-06-07 Thread daniele rizzi


hi,
it depends on what you intends for graphics support:
the idea is to decouple the content (in the shape of a xml file)
from the presentation (generated by a transformation, which is
described by a xsl file)

1- if the question is: can xslt produce some .gif?
   the answer is : not a xslt in itself: nevertheless
   some projects (ie FOP) have an extra layer of code
   reading a Xml and writing a Gif

2- can xslt produce some .pdf?
   same answer, and also check iText

3- can xslt generate a html page with a cool layout
   (made with some background and foreground images)?
   yes, creating with a graphics software the images
   and writing down the img... tags into formatting files
   (ie xsl)

hope it may help

d.rizzi




-Messaggio originale-
Da: Spencer Smith [mailto:[EMAIL PROTECTED]]
Inviato: giovedì 6 giugno 2002 18.07
A: [EMAIL PROTECTED]
Oggetto: XML/XSLT Question - Help!



I have a question regarding the use of XML/XSLT.  Please correct me if I am
wrong, but it is my understanding that XML does not directly support
graphics.  Apparently, a new XML standard called SVG is currently being
reviewed by w3 for approval (hasn't been adopted yet) which uses scalable
vector graphics to display a page, which is pretty cool, but even that
doesn't directly support the use of gifs and jpgs unless you convert all the
graphics to vector graphics (svg format)

Is this true, or can I place graphics in XML and then define them in the XSL
doc?  If so, is this an acceptable technique?


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



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




R: maybe someone knows. Desesperated

2002-06-04 Thread daniele rizzi


Hi Adolfo,
what are you aims in inserting a OracleConnection in a table
using a connection?

daniele rizzi (perplexed)


-Messaggio originale-
Da: Adolfo Miguelez [mailto:[EMAIL PROTECTED]]
Inviato: lunedì 3 giugno 2002 19.34
A: [EMAIL PROTECTED]
Oggetto: maybe someone knows. Desesperated


Has any of you, by chance, inserted an java.sql.Struct (which holds an
OracleConnection) data into an Oracle DB by using a connection obtained from
a WTE datasource (instance of OracleConnectionProxy)?

Is it possible?

TIA,

Adolfo.



_
Join the world’s largest e-mail service with MSN Hotmail.
http://www.hotmail.com


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



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




R: R: maybe someone knows. Desesperated

2002-06-04 Thread daniele rizzi


Well, I may tell you what I know on the matter,
but don't be disappointed by my ignorance:

java.sql.Struct is the father of all the DB object
not exactly primitives, that is BLOB, CLOB, VARRAYs and friends.
There aren't many db servers supporting this sort of stuff
(perhaps just Oracle Server 8i + 9i); Oracle allows you to
shape your data in a Table-inside-a-Table approach, but actually
I've never used it. I remember that in my own youth you
could manage that with PL/SQL code only,
but since then support for jdbc has been extended and I believe
you could mimic PL/SQL code using java classes.
(By the way, PL-SQL is the native db language).

There are few examples around about reading and writing
java.sql.Struct, and all of them come from technet.oracle.com;
the only suggestion that comes to my mind is to put all
the stuff in a transaction:

- getConnection()
- conn.setAutoCommit(false)
- read  write
- conn.commit();
- conn.close();

due to the way the server keeps track of the data  the buffers;
another could be to upgrade the jdbc driver to a more recent version;
finally  there could be some gain in moving your code from java
outside the db to java inside (ie java store procedures) or
straight to a plsql package
(perhaps you have already done that...)


I'm sorry I can only give general suggestions,
but nevertheless hope it may help

bye , d.rizzi





-Messaggio originale-
Da: Adolfo Miguelez [mailto:[EMAIL PROTECTED]]
Inviato: martedì 4 giugno 2002 10.44
A: [EMAIL PROTECTED]
Oggetto: Re: R: maybe someone knows. Desesperated



Us,

:-)

The issue is really complex and I can not find any documentation or example.
Struct is a connected data structure which belongs to JDBC as, by example,
also, ResultSet does, ARRAY...

I am using VisualAge with WTE and thin Oracle driver. Struct (not Struts),
as a connected object holds a instance of OracleConnection to the database
where it comes from.

We are not handling just simple connections, but pooled connections from the
WTE pool, which are, in turn, instances of OracleProxyConnection. The point
is that when I try to use OracleProxyConnection to create the JDBC callable
statement (calls are made through stored procedures), and registerOutParams,
etc, etc, the update is not succeeded. However when I use to create the
CallableStatement the connection holded inside the Struct component, update
is ok, but this connnection is not pooled. Furthermore, if I close this
connection, next time I surprisingly get a closed connection from the pool.
(??). It seems that same connnection is reclycled by the pool when it
actually comes from the struct object, worst it is closed!!!

No idea how to proceed. The question is, has any of you updated or inserted
with JDBC an Struct object in a database through a connection obtained from
a pool?

Just forget if you do not understand, it is quite deep, or maybe I am
missing the obvious!

Regards,

Adolfo.


From: daniele rizzi [EMAIL PROTECTED]
Reply-To: Struts Users Mailing List [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Subject: R: maybe someone knows. Desesperated
Date: Tue, 4 Jun 2002 09:16:37 +0200


Hi Adolfo,
what are you aims in inserting a OracleConnection in a table
using a connection?

daniele rizzi (perplexed)


-Messaggio originale-
Da: Adolfo Miguelez [mailto:[EMAIL PROTECTED]]
Inviato: lunedì 3 giugno 2002 19.34
A: [EMAIL PROTECTED]
Oggetto: maybe someone knows. Desesperated


Has any of you, by chance, inserted an java.sql.Struct (which holds an
OracleConnection) data into an Oracle DB by using a connection obtained
from
a WTE datasource (instance of OracleConnectionProxy)?

Is it possible?

TIA,

Adolfo.



_
Join the world’s largest e-mail service with MSN Hotmail.
http://www.hotmail.com


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



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

_
Send and receive Hotmail on your mobile device: http://mobile.msn.com


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



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




R: validator NullPointer- please help

2002-06-03 Thread daniele rizzi


hi,
have you enclosed the jakarta regexp library?
(it's required by validator only, so everything else works
as usual)

bye, d.rizzi

-Messaggio originale-
Da: Peter Onthrops [mailto:[EMAIL PROTECTED]]
Inviato: venerdi 31 maggio 2002 18.47
A: [EMAIL PROTECTED]
Oggetto: validator NullPointer- please help



I am having problems installing the validator. I am getting a
NullPointerException (see below) in the validate method of
...commons.validator.Validator. I followed the install instructions and just
can't figure out what it causing the exception.

---

java.lang.NullPointerException
at org.apache.commons.validator.Validator.validate(Unknown Source)
at org.apache.struts.validator.action.ValidatorForm.validate(Unknown
Sou
rce)
at
org.apache.struts.action.ActionServlet.processValidate(ActionServlet.
java:2038)
at
org.apache.struts.action.ActionServlet.process(ActionServlet.java:149
7)
at
org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:504)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:211)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:309)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
at com.evermind[Orion/1.5.4 (build 10585)]._deb._lnc(.:514)
at com.evermind[Orion/1.5.4 (build 10585)]._deb._wmb(.:170)
at com.evermind[Orion/1.5.4 (build 10585)]._co._wbb(.:581)
at com.evermind[Orion/1.5.4 (build 10585)]._co._fs(.:189)
at com.evermind[Orion/1.5.4 (build 10585)]._bt.run(.:62)

-

My configuration is as follows.

1) /WEB-INF/struts-config.xml

form-bean name=myForm type=com.ponthrops.web.MyForm / (MyForm extends
ValidatorForm)

2) /WEB-INF/validation.xml

form-validation
   global
   /global
   formset
  form  name=myForm
  field property=firstName
  indexedProperty=member
  indexedListProperty=members
  depends=required
   arg0 key=error.firstname.displayname/
  /field
  /form
   /formset
/form-validation


3) validator-rules.xml includes the validator required

4) /WEB-INF/lib includes commons-validator.jar, struts-validator.jar, and
jakarta-regexp-1.2.jar

5) web.xml includes the example servet config given in the install
directions

My guess is I missed a configuration step, however I can't seem to figure
out where.

Any help is greatly appreciated.



Thanks so much,

Petra



-
Do You Yahoo!?
Yahoo! - Official partner of 2002 FIFA World Cup


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




R: Design Advice - Relational Databases Java Objects

2002-05-31 Thread daniele rizzi


Hi Adam,
I know it sounds silly as an answer, but if you avoid OO altogether
for this sort of questions and
SELECT COUNT(*) FROM MY_TABLE
straight to the db?

d.rizzi


-Messaggio originale-
Da: Adam Hardy [mailto:[EMAIL PROTECTED]]
Inviato: venerdi 31 maggio 2002 10.01
A: Struts Users Mailing List
Oggetto: Re: Design Advice - Relational Databases  Java Objects


There's still one question I've got about using object - relational
mapping  DB access packages:

what happens when I want to pull out a COUNT(*) on a grouping in the
database? For instance when I want to show the number of people who've
voted on an online survey, or the number of replies to a message in an
online forum? How would I integrate that into the framework? Or would it
have to be seperate?

Re the book at http://www.object-relational.com/object-relational.html :
I didn't get further than the document's table of contents, which is why
I didn't see that it was a book to purchase - at a cool $1800. That's a
pity.



[EMAIL PROTECTED] wrote:

The link that I included in Chapter 6 actually has a
cost associated with getting at that information. I
believe it's quite severe. What these guys have done is
to compare these 13 products from every angle imaginable
and they are selling their findings.

I mentioned that this link is beneficial only if your
project had some serious funds and you wanted to be
absolutely sure that you were picking the correct
implementation.

Unfortunately, applications have different requirements
as well as resources available. No one solution is going
to be the perfect one for all. I would prefer to buy an
ORM solution, rather than building one, although I know
that some developers feel the opposite way.

Chuck


Oh boy, now I've got information overload! Fortunately there's a link in
Chuck Cavaness's book to an article reviewing  comparing some of them -
although strangely they include Forte for Java from Sun instead of JDO.
Well, I can see what I'm going to be doing this weekend.

Regards
Adam




Steve Muench wrote:



Oracle's J2EE Framework Business Components for Java
makes it very easy to read and write from collections
of values objects (sourced from the database) with
automatic interaction with business objects that
centralize your business rules, and handles the OR mapping
for your business objects. You pick the shape of
the data you need in your view layer, and it implements
all of the handlers for your value object collections
and optionally makes the value objects in these
collections transparently updateable, delegating
changes back through your business object layer
with no yucky code you have to write yourself.

A whitepaper on all the capabilities is at:

http://otn.oracle.com/products/jdev/htdocs/j2ee_bc4j.html

If you've read the O'Reilly Struts book sample chapters
on TheServerSide.com, basically all of the Model Layer things
that Chuck describes in Chapter 6, Struts Model Components
as necessary pieces for your working Struts-with-Database-
and-Business-Logic application, the BC4J framework
implements for you. You basically just tell it the
tables you want to work with (for your BO layer), or
forward generate those tables from a BO object model
that you design, and then tell it what queries your
view layer needs to perform.

You don't need to write model layer plumbing code.

 - Don't bother writing Value Object classes

 - Don't bother writing JDBC code for queries

 - Don't bother writing a class to expose your
collections of value objects to the view layer

All of these things are done for you.

Plus, it works with any SQL database, not only Oracle. :-)

I'm planning a whitepaper that specifically illustrates
how to couple Struts with BC4J next.

__
Steve Muench - Developer, Product Mgr, Java/XML Evangelist, Author
Simplify J2EE and EJB Development with BC4J
http://otn.oracle.com/products/jdev/htdocs/j2ee_bc4j.html
Building Oracle XML Apps, www.oreilly.com/catalog/orxmlapp
- Original Message -
From: [EMAIL PROTECTED]
To: Struts Users Mailing List [EMAIL PROTECTED]
Sent: Wednesday, May 29, 2002 6:44 PM
Subject: Re: Design Advice - Relational Databases  Java Objects


|
|
|
| Adam -
|
| Have you looked at Torque from the Jakarta Tubine project?
|
| I haven't used it but have heard good things about it. It provides an
| ability to perform O/R mapping using an XML configuration file - and
(as I
| understand) it creates Java files for you that implement a peristence
| layer.
|
| FWIW -
| Kevin
|
|
|
|
| Adam Hardy [EMAIL PROTECTED] on 05/29/2002 12:44:28 PM
|
| Please respond to Struts Users Mailing List
|   [EMAIL PROTECTED]
|
| To:   Struts Users Mailing List [EMAIL PROTECTED]
| cc:(bcc: Kevin Bedell/Systems/USHO/SunLife)
| Subject:  Design Advice - Relational Databases  Java Objects
|
|
| Hi All,
|
| I saw this thread in the archives and I thought I'd pinch the title.
| I've spent this afternoon surfing 

R: R: Design Advice - Relational Databases Java Objects

2002-05-31 Thread daniele rizzi


Well, I don't know if I'm close to the point you're making,
but accessing to a db has (at least) two different meanings:

a- you may read some data from one or more tables, related or
   non-related by foreign keys;
b- you may change some data in one or more tables, that is 
   inserting, updating or deleting one or more records, besides 
   just reading.

Case (b) is by far harder than (a): it usually means some sort
of concurrency and lock manager, and a way to remap the same
data in a non-relational structure, in our case in some sort
of Java beans; all the frameworks sketched in the previous mails
(J2ee for instance) includes code designed to cope with those 
aspects of computing. 

If your requirements are limited to (a), that is just reading some
data without any need to write back, the frameworks sketched 
above may add a lot of overhead without measurable gains:

should you have to write in a .jsp stating the number of rows 
of a table (let's say EMP), you are better off writing
a 'simple' Java class which open a JDBC connection, 
execute a query (SELECT COUNT(*) FROM EMP) and returns
the result as a String, and then invoke this class
inside the jsp.

Of course, if your needs are related to a full-fledged web
application, there are no shortcuts: you have to learn
how to use a framework or write down a lot of code by yourself
(and usually both cases are true)

hope this may help
bye, d.rizzi







-Messaggio originale-
Da: Adam Hardy [mailto:[EMAIL PROTECTED]]
Inviato: venerdi 31 maggio 2002 11.06
A: Struts Users Mailing List
Oggetto: Re: R: Design Advice - Relational Databases  Java Objects


Yes sure but where would I do that? If I've got a complete DB access  
object-relation mapping package between my business classes and my 
database, then I would have to write a whole new seperate bunch of 
classes to handle COUNT(*)s queries.

I was hoping somebody who uses such a package could tell me how they do 
it. Perhaps there's some way of specifying it in the mapping definitions 
that I haven't found yet. I haven't chosen a mapping package yet, so I'm 
not in that deep.

Adam




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




Validation DTD (was R: DTD Question - SIMPLE SOLUTION)

2002-05-31 Thread daniele rizzi


Hi all,
by the way last night I wrote down the DTDs for validation.xml
and validator-rules.xml

Hope it might help (well I'm not even sure I've written down right...)

bye,
d.rizzi


-Messaggio originale-
Da: Emaho, Ghoot [mailto:[EMAIL PROTECTED]]
Inviato: venerdì 31 maggio 2002 12.03
A: Struts Users Mailing List
Oggetto: RE: DTD Question - SIMPLE SOLUTION


A simple way of bypassing the need to access the DTD externally (as the
Struts 'automatic' resolution within the jar does NOT always work - see mail
archives) is to change the DOCTYPE def to something like the following:

!DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web Application
2.2//EN dtds/web-app_2_2.dtd

where the dtd directory is a subdirectory of your WEB-INF directory. Copy
the web_app dtd into that directory and it will be found there. Nice and
simple.

NOTE it is still defined as 'PUBLIC'. There have been other posts about
using the 'SYSTEM' definition and looking locally, but this doesnt always
work - depending on which server/setup you have.

However, the suggested method works all the time and on as many different
environments as I've tried it.

Cheers

Ghoot Emaho

Lead Architect
Petrotechnics Ltd

 -Original Message-
 From: Struts Newsgroup (@Basebeans.com) [mailto:[EMAIL PROTECTED]]
 Sent: 30 May 2002 20:40
 To: [EMAIL PROTECTED]
 Subject: DTD Question


 Subject: DTD Question
 From: Adam Cohen [EMAIL PROTECTED]
  ===
 I'm working on a web-app that is on a server that has no
 access to the web
 on port 80.
 When web.xml tries to get the dtd:
 !DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.//DTD Web
 Application
 2.2//EN http://java.sun.com/j2ee/dtds/web-app_2_2.dtd;
 The server waits for a long time for the request to time out.
 I don't want to hard code a local path to the dtd and the
 server can't get
 accss to the web.
 Is there a better way to do?
 Thanks, Adam



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



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




xml.zip
Description: Zip compressed data

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


R: Brain Teaser

2002-05-29 Thread daniele rizzi


That's easy!
It's not a file, just a name to be called in html:form
action=logon/html:form

bye,
d.rizzi


-Messaggio originale-
Da: Chris Cairns [mailto:[EMAIL PROTECTED]]
Inviato: mercoledi 29 maggio 2002 9.23
A: [EMAIL PROTECTED]
Oggetto: Brain Teaser


Could someone explain to me what the path attribute for the action mappings
element is for?  I know it's the path of the action, but what sort of file
is it?  jsp?

struts-config
form-beans
form-bean
   name=logonForm
   type=org.apache.struts.example.LogonForm /
/form-beans global-forwards
   type=org.apache.struts.action.ActionForward /
forward name=logon path=/logon.jsp
  redirect=false / /global-forwards

action-mappings action
 path=/logon
 type=org.apache.struts.example.LogonAction
 name=logonForm
scope=request
input=/logon.jsp
  unknown=false
 validate=true / /action-mappings
/struts-config


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



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




ever got a StackOverflowError calling a form?

2002-05-28 Thread daniele rizzi


Hi all,

I'm rather green using Struts: to gain some experience,
I've written an application using Actions  Forms, and
it works until there's no validation (i.e. Validate=false
in struts-config.xml).

Turning validation on, (i.e. validate=true) and
putting a mock validation.xml and validator-rules.xml
in the right place (basically cutpaste from registration.jsp)
raises a
--- begin ---
java.lang.StackOverflowErrorint java.lang.Object.hashCode()
java.lang.Object java.util.HashMap.get(java.lang.Object)java.lang.Object
org.apache.commons.collections.FastHashMap.get(java.lang.Object)

--- end ---
whenever the page is called (that is, NOT a submit error, but
when the jsp is loaded)

That's rather weird, because it means that a never-ending loop
is evocated :-(, and I don't know how I could create such a beast.

Any hint will be appreciated,
thanx for listening,
daniele rizzi ([EMAIL PROTECTED])



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




R: validator generated HTML code

2002-05-28 Thread daniele rizzi


Hi,
you're not the only one studying this stuff! As far as I may know
(after 3 days  nigths of hard work) the answers are:

---q1
--Can I get rid of the other functions?

No, they're loaded in bundle, but you can always get into
the validator-rule.xml and remove what you don't like

---q2
--i notice that i get a lot of \n characters in between the lines...

oh, open the file with textpad and substitute any \n\n with \n

(maybe the writer worked on a pc, then sent the code to a unix box,
so every \n became a \n\n)

like it?
bye, daniele rizzi


-Messaggio originale-
Da: Adolfo Miguelez [mailto:[EMAIL PROTECTED]]
Inviato: martedì 28 maggio 2002 16.25
A: [EMAIL PROTECTED]
Oggetto: validator generated HTML code



Hi All,

i have been checking the validator framework and i have some issues for yuo.
First a, probably silly, question. I place in my JSP:
onsubmit=return validateLoginForm(this);
in the html:form and
html:javascript formName=LoginForm/.

The result is that I am getting all the javascript functions present in my
validator-rules.xml file in the generated HTML, i.e:

function validateShort(form)
function validateMask(form)
function validateCreditCard(form)
function validateEmail(form)
function validateMaxLength(form)
function validateDate(form)
function validateFloat(form)
function validateRange(form)
function validateMinLength(form)
function validateRequired(form)
function validateInteger(form)
function validateByte(form)

I suppose, I should only get the necessary functions for my validation, in
my case function validateRequired(form). What am I doing wrong or missing?
Can I get rid of the other functions?

Secondly, i notice that i get a lot of \n characters in between the lines of
the generated functions, i.e.:

function validateRequired(form) {

var bValid = true;

var focusField = null;

var i = 0;

var fields = new Array();

oRequired = new required();



for (x in oRequired) {

if ((form[oRequired[x][0]].type == 'text' ||
form[oRequired[x][0]].type == 'textarea' || form[oRequired[x][0]].type ==
'select-one' || form[oRequired[x][0]].type == 'radio' ||
form[oRequired[x][0]].type == 'password')  form[oRequired[x][0]].value ==
'') {

   if (i == 0)

  focusField = form[oRequired[x][0]];



   fields[i++] = oRequired[x][1];



   bValid = false;

}

}



if (fields.length  0) {

   focusField.focus();

   alert(fields.join('\n'));

}



return bValid;

}

Could this code generation be optimized in order to get javascript functions
with same format that in the validator-rules.xml?


Adolfo.



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


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



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




R: Do we have struts custom tag for success messages.

2002-05-23 Thread daniele rizzi


yep, there is:

a/ put this code somewhere in your Action.perform

--- begin

  ActionMessages messages = new ActionMessages();
  messages.add(statusTrans, new ActionMessage(trans.generic.read_ok));
  saveMessages(request, messages);
  return mapping.findForward(dest);

--- end

b/ put this other in .jsp

--- begin
 p class=StrMessageOk
 html:messages id=message property=statusTrans message=true
  bean:write name=message/br
 /html:messages
/p

--- end

that's should be enough to show the 'trans.generic_read.ok' message when
it's time.

bye, d.rizzi



-Messaggio originale-
Da: Harinath [mailto:[EMAIL PROTECTED]]
Inviato: giovedì 23 maggio 2002 15.22
A: struts
Oggetto: Do we have struts custom tag for success messages.


Hi,

As we have html:errors/ for displaying error messages, do we have any
custom tag in struts for success messages ?
I need to display a success message to the user, when the request is
processed successfully by the Action class.

Regards,
Hari





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



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