Autocomplete attribute in Struts tags

2006-12-04 Thread grifoxx

Hi I am developing a web application that allow the user to make online
payments, so my question is:

How can avoid the browser to redisplay or autocomplete an input when a user
type in. For instance in firefox the user can see what other users typed
before.

I know that the html:text or any other struts tag does not use this
attribute but there must be a way to do this because this kind of
information is very important to show it.
-- 
View this message in context: 
http://www.nabble.com/Autocomplete-attribute-in-Struts-tags-tf2756757.html#a7686988
Sent from the Struts - User mailing list archive at Nabble.com.


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



Re: Select row from a Table

2006-10-23 Thread grifoxx

Thank you man.it worked but now I have another question, how can i get
the parameter and pass it to an action class.

Thank you again...


Laurie Harper wrote:
> 
> grifoxx wrote:
>> Hi, I created a table using the iterate tag from struts. What I want to
>> do is
>> to select a row from that table so I have an extra column that has a link
>> called Detail. If the user click on that link I want to display in other
>> page the detail of that row.
>> 
>> To do that I need to get the Order number which is one of the columns, so
>> How can I get that parameter when the user click on the link.
> 
> You don't, you encode it in the link when you render it. For example,
> 
>  paramId="orderNum"
>  paramName="orderBean"
>  paramProperty="orderId"/>
> 
> See the documentation for the html:link tag [1] for the various way of 
> specifying request parameters.
> 
> L.
> 
> [1] http://struts.apache.org/1.2.9/userGuide/struts-html.html#link
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Select-row-from-a-Table-tf2496157.html#a6961729
Sent from the Struts - User mailing list archive at Nabble.com.


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



Select row from a Table

2006-10-23 Thread grifoxx

Hi, I created a table using the iterate tag from struts. What I want to do is
to select a row from that table so I have an extra column that has a link
called Detail. If the user click on that link I want to display in other
page the detail of that row.

To do that I need to get the Order number which is one of the columns, so
How can I get that parameter when the user click on the link.

Thanks a lot
-- 
View this message in context: 
http://www.nabble.com/Select-row-from-a-Table-tf2496157.html#a6958531
Sent from the Struts - User mailing list archive at Nabble.com.


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



Validate two fields

2006-10-06 Thread grifoxx

Hi I am trying to validate to password field so I want to check if they have
the same values.

This my StrutsValidator Class:

package com.sfv;

import javax.servlet.http.HttpServletRequest;

import org.apache.commons.validator.Field;
import org.apache.commons.validator.GenericValidator;
import org.apache.commons.validator.ValidatorAction;
import org.apache.commons.validator.util.ValidatorUtils;
import org.apache.struts.action.*;
import org.apache.struts.validator.Resources;

public class StrutsValidator {
//~ Methods


/**
 * Validates that two fields match.
 * @param bean
 * @param va
 * @param field
 * @param errors
 * @param request

 * @return boolean
 */
   public static boolean validateTwoFields(Object bean, ValidatorAction va,
Field field, ActionErrors errors,
HttpServletRequest request) {
String value = ValidatorUtils.getValueAsString(bean,
field.getProperty());
String sProperty2 = field.getVarValue("secondProperty");
String value2 = ValidatorUtils.getValueAsString(bean, sProperty2);

if (!GenericValidator.isBlankOrNull(value)) {
try {
if (!value.equals(value2)) {
errors.add(field.getKey(),
   Resources.getActionError(request, va, field));

return false;
}
} catch (Exception e) {
errors.add(field.getKey(),
   Resources.getActionError(request, va, field));

return false;
}
}

return true;
}
}


this is my validator rule:

 

and this is what I have i the validation.xml file:




  
  
  
  
 
secondPropertypasswordConfirmed








  

the problem is that is not validating anything.

Can anybody has a suggestion
-- 
View this message in context: 
http://www.nabble.com/Validate-two-fields-tf2398749.html#a6689135
Sent from the Struts - User mailing list archive at Nabble.com.


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



Check a multibox dynamically

2006-10-03 Thread grifoxx

Hi,

I have a multibox tag that gets the labels and velues from the data base and
I also have a bean that contains the data that the user choose. Now I want
to check the boxes each time the user wants to update it's preferences.

1. I display the check boxes with the data comming from the data base
2. I want to compare those values whit the values that the user has
3. If there is a value equals to the value in the current multiboxes, check
them

Can anybody help me

Thanks a lot
-- 
View this message in context: 
http://www.nabble.com/Check-a-multibox-dynamically-tf2379274.html#a6630704
Sent from the Struts - User mailing list archive at Nabble.com.


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