RE: 'required' is undefined when using struts javascript validation

2005-08-23 Thread Mariano Petrakovsky
The problem si the function name generated by struts.

I'm fix this problem, modifying the validator_rules.xml (I'm attach this)...
Sure exist a more correct to resolve this problem... but... time is money.

The function name generated by struts is "_required (form)" for
required validator for instance. But the javascript in validator_rules.xml
search for a "required(form)" function. I modify the javascript in
validator_rules.xml for it search the correct function name.

Saludos :)...

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·


-Mensaje original-
De: Tian Chi [mailto:[EMAIL PROTECTED]
Enviado el: Martes, 23 de Agosto de 2005 02:44
Para: user@struts.apache.org
Asunto: 'required' is undefined when using struts javascript validation


Hi,

I'm a newbie at using strus and have been trying to get client-side
validation to work using Struts, but I 'm receiving a javascript error while
trying to use the
'required ' validation rule. The error in IE and FireFox both say:

Error: 'required ' is undefined

When I look at the generated javascript, it seems the object 'required' is
not defined in the following generated function. Can anyone give me some
guidance how to resolve this? I'd really appreciate it.  Hope to hear from
you soon.

function validateRequired(form) {
var isValid = true;
var focusField = null;
var i = 0;
var fields = new Array();
oRequired = new required();
for (x in oRequired) {
var field = form[oRequired[x][0]];
...  


Thanks in advance,

-Paul



-
 Start your day with Yahoo! - make it your home page
http://jakarta.apache.org/commons/dtds/validator_1_0.dtd";>




   

  

 
 

  

  
  

  

 
 

  


  

 
 

  


  

 
 

  


  

 
 

  


  

 
 

  


  

 
 

  


  


  

 
 

  


  


  

 
 

  


  

 
 

  

  

 
 

  

  

 
 

  

  

 
 

  


  

 
 

  

  

 
 

  


   



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

Struts Menu - PermissionsAdapter

2005-07-21 Thread Mariano Petrakovsky

 I make my custom class implements permissionAdapter...

 How... link my menu with this class ?

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



Cancel and Populating...

2005-07-18 Thread Mariano Petrakovsky

  I have a Cancel Button in my page... when it's submit, populating error
occurs...
  In jsf, it's solutionated by the immediante attribute to false. How is in
struts?...

  (When Cancel, i want forward to another page... nothing more :) )

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



I can't initialize de Serlvet Action :(

2005-07-11 Thread Mariano Petrakovsky

Throw an exception ServletAction can't load...

In my .jsp say me same (I'm using eclipe)... what should be the troubble?

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



[Shale] Validation Server-Side

2005-06-07 Thread Mariano Petrakovsky
If use the tag like this



I need implement the server side validation ? or this is inside de shale?

Thanxs

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



Using Jsf, Struts, Tiles... and Frames?

2005-05-26 Thread Mariano Petrakovsky

 I'm using Jsf with Struts and Tiles... displaying a header, a tree (at
left) and content.
 The tree is big to reaload some time a request begin.
 Frame is the my first idea... but... reading I'm found this link

   http://www.jroller.com/page/rkischuk/20040601#struts_tiles_and_frames_don

 I have a tiles.xml like this

-
   tiles-definitions>












   

---

The each page change only the body in the template... but all other parts
are realoded (header & menu's).
How resolve this? :S.. if Frames is the solution... how mix with the other
stuff?

Thanxs :)

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



RE: [Shale] Re: Javascript validator

2005-05-26 Thread Mariano Petrakovsky
It's Work :D many thanxs! :)

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·


-Mensaje original-
De: Manfred Klug [mailto:[EMAIL PROTECTED]
Enviado el: Miércoles, 25 de Mayo de 2005 01:55
Para: user@struts.apache.org
Asunto: [Shale] Re: Javascript validator


> I have a JSP like this:
>
> -
>
> 
>
>
> value="#{sizeTableHandler.currentconfig}" required="true"
> size="10">
>
> server="false" client="true" />
>
>
> 
>
>
> --
-
>
> when JSF generate mi static HMTL using Commons Validators, (for instance,
> i'm not fill the "currentconfig" field), mi mozilla Javascript Console
> capture this: "Error: v is not defined"
> Then... looking source of this static page... I'm Found the javascript
> generate like this:
>
> --
-
> var bCancel = false;
> function ValidateForm(form) { return bCancel || true
> && validateRequired.js,v(form)
> ;}
> function required() {
> this[0] = new Array("content:testForm:currentconfig", "currentconfig is
> required.", new Function("x", "return {}[x];"));
> }
> --
-
> Now... I'm asking... it's and bug of commons validator libraries or...
it's
> my error???

Neither commons validator nor you.

It seems that the shale-validator makes some assumptions about the content
of
the script which are not correct for the scripts in the commons validator
jar.

Please use the validator-rules.xml from the shale use cases and it should
work.

Manfred Klug

__
Mit WEB.DE FreePhone mit hoechster Qualitaet ab 0 Ct./Min.
weltweit telefonieren! http://freephone.web.de/?mc=021201


-
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]



Shale Forum?

2005-05-24 Thread Mariano Petrakovsky
Exist any Shale Forum?

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



[Shale] Javascript validator

2005-05-23 Thread Mariano Petrakovsky

I have a JSP like this:

-










---

when JSF generate mi static HMTL using Commons Validators, (for instance,
i'm not fill the "currentconfig" field), mi mozilla Javascript Console
capture this: "Error: v is not defined"
Then... looking source of this static page... I'm Found the javascript
generate like this:

---
var bCancel = false;
function ValidateForm(form) { return bCancel || true
&& validateRequired.js,v(form)
;}
function required() {
this[0] = new Array("content:testForm:currentconfig", "currentconfig is
required.", new Function("x", "return {}[x];"));
}
---
Now... I'm asking... it's and bug of commons validator libraries or... it's
my error???


--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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



[Shale] Validation...

2005-05-23 Thread Mariano Petrakovsky
I'm installed Shale Framework, because I need use the Strut's validator
under JSF...
I having some troubbles with javascript generation... like "javascript
errors"...
Somebody know what happen?...

(I'm practicing my english... sorry :S)

--
Mariano G. Petrakovsky
Programmer · Software Factory
AXG Tecnonexo -  www.tecnonexo.com

Development facilities:Av. Maipú 1252 8º (C1006ACT) · Buenos Aires ·
Argentina.
Tel.: (54-11) 4878-0005 - Fax: (54-11) 4878-0065.

Headquarters: 1604 Spring Hill Road, Suite 160 Vienna · VA 22182 · USA.
Tel.: (202) 986-7541 - Fax: (202) 787-3891.


· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · · ·
· · · ·




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