Re: i18n input

2004-12-06 Thread Guillaume Cottenceau
Huw Richards huw.richards 'at' oprig.com writes:

 The one problem I had with i18n input was with European locales where , is
 used as the decimal separator. The number would be formatted with , as the
 decimal separator but as the input boxes are just text, the numeric keypad
 which produces , in excel when . is pressed just produces . in the
 number box. I had to rely on an adapted javascript to mask the numbers on
 field entry  exit.

As a side note, if I'm not mistaken, there has been a Red Hat
Linux release with the numeric keypad key . outputting always
, when using the appropriate locale, but this made the users
quite frustrated because many of them are used to using this key
to really mean ., not always decimal separator (the dot at
the end of a sentence, the dot in programming languages, etc).

-- 
Guillaume Cottenceau

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



RE: i18n input

2004-12-06 Thread Simon Matic Langford
huw,

how did you handle this input on the server side? did you have some
cunning scheme
or just a lot of
NumberFormat.getNumberInstance(request.getLocale()).parse(formBean.getFi
eld())?

thanks

simon
 

 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED] 
 Sent: 03 December 2004 23:05
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 The one problem I had with i18n input was with European 
 locales where , is
 used as the decimal separator. The number would be formatted 
 with , as the
 decimal separator but as the input boxes are just text, the 
 numeric keypad
 which produces , in excel when . is pressed just produces 
 . in the
 number box. I had to rely on an adapted javascript to mask 
 the numbers on
 field entry  exit.
 
 -Original Message-
 From: Jim Barrows [mailto:[EMAIL PROTECTED] 
 Sent: Friday, December 03, 2004 11:00 AM
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 
 
  -Original Message-
  From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
  Sent: Friday, December 03, 2004 8:51 AM
  To: 'Struts Users Mailing List'
  Subject: RE: i18n input
  
  
  yeah, I know I can do this, but this is a large system with 
 around 200
  jsps 80 views
  and a number of controllers. doing the display is 
 reasonably simple I
  know, but extremely
  tedious and prone to errors, I was hoping for a more 
 elegant solution
  which also handles
  input...
 
 I believe it does handle input as well... depending on the 
 browser, which
 java has no control over.  
 
   
   Java comes with i18n built in.  You want the JSTL fmt:blah 
   for output and look at the way message resources are handled 
   in struts, as well as read through the i18n documentation on 
   the sun site.
  
  
  
 -
  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]
 
 
 ___ 
 
 CONFIDENTIALITY NOTE 
 
 This message may contain confidential and privileged information. 
 If you think, for any reason, that this message may have been 
 addressed to you in error, you must not disseminate, copy or 
 take any action in reliance on it and we would ask you to notify us 
 immediately by return email to [EMAIL PROTECTED]. 
 
http://www.oprig.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: i18n input

2004-12-06 Thread Huw Richards
Hi

It was something along those lines. 

My business objects tend to have convert methods where I take the strings of
the value object (which have been created in the Action from the form) and
turn them into their correct types. I have a NumberUtil class which I use
for converting locale specific strings into BigDecimal. This NumberUtil
class has a static method which takes a String and a Locale as parameters
and returns a BigDecimal.

Huw

-Original Message-
From: Simon Matic Langford [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 06, 2004 5:05 AM
To: 'Struts Users Mailing List'
Subject: RE: i18n input



___

*** WARNING ***

This email has been received from the internet. 
Check any attachments for viruses before opening them. 
___


huw,

how did you handle this input on the server side? did you have some
cunning scheme
or just a lot of
NumberFormat.getNumberInstance(request.getLocale()).parse(formBean.getFi
eld())?

thanks

simon
 

 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED] 
 Sent: 03 December 2004 23:05
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 The one problem I had with i18n input was with European 
 locales where , is
 used as the decimal separator. The number would be formatted 
 with , as the
 decimal separator but as the input boxes are just text, the 
 numeric keypad
 which produces , in excel when . is pressed just produces 
 . in the
 number box. I had to rely on an adapted javascript to mask 
 the numbers on
 field entry  exit.
 
 -Original Message-
 From: Jim Barrows [mailto:[EMAIL PROTECTED] 
 Sent: Friday, December 03, 2004 11:00 AM
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 
 
  -Original Message-
  From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
  Sent: Friday, December 03, 2004 8:51 AM
  To: 'Struts Users Mailing List'
  Subject: RE: i18n input
  
  
  yeah, I know I can do this, but this is a large system with 
 around 200
  jsps 80 views
  and a number of controllers. doing the display is 
 reasonably simple I
  know, but extremely
  tedious and prone to errors, I was hoping for a more 
 elegant solution
  which also handles
  input...
 
 I believe it does handle input as well... depending on the 
 browser, which
 java has no control over.  
 
   
   Java comes with i18n built in.  You want the JSTL fmt:blah 
   for output and look at the way message resources are handled 
   in struts, as well as read through the i18n documentation on 
   the sun site.
  
  
  
 -
  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]
 
 
 ___ 
 
 CONFIDENTIALITY NOTE 
 
 This message may contain confidential and privileged information. 
 If you think, for any reason, that this message may have been 
 addressed to you in error, you must not disseminate, copy or 
 take any action in reliance on it and we would ask you to notify us 
 immediately by return email to [EMAIL PROTECTED]. 
 
http://www.oprig.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]


___ 

CONFIDENTIALITY NOTE 

This message may contain confidential and privileged information. 
If you think, for any reason, that this message may have been 
addressed to you in error, you must not disseminate, copy or 
take any action in reliance on it and we would ask you to notify us 
immediately by return email to [EMAIL PROTECTED]. 

http://www.oprig.com 


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



RE: i18n input

2004-12-06 Thread Simon Matic Langford
hmm, that's what I've been trying to avoid.

I went for a somewhat sicker route :-)

I extended the request processor, so it called a new method called
processTranslate() just
after the validator is called! This then does exactly the same as the
population of the form
beans, but calls a translation routine to convert from the locale
specific format to the system
format which is english (a la BigDecimal). This seems to work fine, but
means there is a separate
xml file to keep up to date, this looks like:

?xml version=1.0?

translations
  !-- Types --
  custom-type name=price formatter=DecimalFormat
application-pattern=0.##
input-pattern value=0.##/
output-pattern value=0.00/
  /custom-type
  custom-type name=ordernumber formatter=DecimalFormat
application-pattern=0
input-pattern value=#,###,###,##0/
output-pattern value=0,000,000,000/
  /custom-type
  custom-type name=quantity formatter=DecimalFormat
application-pattern=0.##
pattern value=0.##/
  /custom-type
  custom-type name=integerquantity formatter=DecimalFormat
application-pattern=0
pattern value=0/
  /custom-type
  custom-type name=percent formatter=DecimalFormat
application-pattern=0.##
pattern value=0.##/
  /custom-type
  custom-type name=date formatter=SimpleDateFormat
application-pattern=dd/MM/
pattern value=dd/MM//
pattern value=dd.MM. language=de country=DE/
pattern value=dd.MM. language=de country=AT/
  /custom-type
  custom-type name=time formatter=SimpleDateFormat
application-pattern=HH:mm
pattern value=HH:mm/
  /custom-type
  !-- Form beans --
  form-bean class=com.pcmsgroup.SomeFormBean
property name=price.value type=price/
property name=quantity.value type=quantity/
  /form-bean
/translations

I've also extended the html:text and bean:write tags to translate back
the other way, which uses the same
translation utility. I gather that FormDef does most of this already,
but we can't use it unfortunately...

Does anyone think this code is useful generally?

Simon

The information contained in this e-mail is intended only for the person
or
entity to which it is addressed and may contain confidential and/or
privileged material. If You are not the intended recipient of this
e-mail,
the use of this information or any disclosure, copying or distribution
is
Prohibited and may be unlawful. If you received this in error, please
contact the sender and delete the material from any computer. The views
expressed in this e-mail may not necessarily be the views of The PCMS
Group
plc and should not be taken as authority to carry out any instruction
contained.
 

 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED] 
 Sent: 06 December 2004 11:55
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 Hi
 
 It was something along those lines. 
 
 My business objects tend to have convert methods where I take 
 the strings of
 the value object (which have been created in the Action from 
 the form) and
 turn them into their correct types. I have a NumberUtil class 
 which I use
 for converting locale specific strings into BigDecimal. This 
 NumberUtil
 class has a static method which takes a String and a Locale 
 as parameters
 and returns a BigDecimal.
 
 Huw
 
 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED] 
 Sent: Monday, December 06, 2004 5:05 AM
 To: 'Struts Users Mailing List'
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 huw,
 
 how did you handle this input on the server side? did you have some
 cunning scheme
 or just a lot of
 NumberFormat.getNumberInstance(request.getLocale()).parse(form
 Bean.getFi
 eld())?
 
 thanks
 
 simon
  
 
  -Original Message-
  From: Huw Richards [mailto:[EMAIL PROTECTED] 
  Sent: 03 December 2004 23:05
  To: Struts Users Mailing List
  Subject: RE: i18n input
  
  
  The one problem I had with i18n input was with European 
  locales where , is
  used as the decimal separator. The number would be formatted 
  with , as the
  decimal separator but as the input boxes are just text, the 
  numeric keypad
  which produces , in excel when . is pressed just produces 
  . in the
  number box. I had to rely on an adapted javascript to mask 
  the numbers on
  field entry  exit.
  
  -Original Message-
  From: Jim Barrows [mailto:[EMAIL PROTECTED] 
  Sent: Friday, December 03, 2004 11:00 AM
  To: Struts Users Mailing List
  Subject: RE: i18n input
  
  
  
  ___
  
  *** WARNING ***
  
  This email has

RE: i18n input

2004-12-06 Thread Simon Matic Langford
I changed the implementation of the validateNumber etc validation
functions in
struts to versions which take account of locale, but driven off the same
file.

the translator assumes that by the time it has got it for population, it
will be 
correct, if there is any error, then it reverts back to the entered
value rather
than throw an exception...

simon
 

 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED] 
 Sent: 06 December 2004 16:05
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 So does your translation code handle user input errors, like 
 a number/date
 in wrong format or does it make a best guess? 
 
 Do you keep your translations.xml file upto date by hand or use ant to
 generate at build time? My app has hundreds of forms with multiple
 date/number fields.
 
 I hadn't thought of extending the html:input  bean:write 
 tags to include a
 locale for formatting. Great idea! I convert the BigDecimals 
 into a locale
 formatted String for html:input and use the formatKey 
 variable of bean:write
 for display.
 
 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED] 
 Sent: Monday, December 06, 2004 7:03 AM
 To: 'Struts Users Mailing List'
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 hmm, that's what I've been trying to avoid.
 
 I went for a somewhat sicker route :-)
 
 I extended the request processor, so it called a new method called
 processTranslate() just
 after the validator is called! This then does exactly the same as the
 population of the form
 beans, but calls a translation routine to convert from the locale
 specific format to the system
 format which is english (a la BigDecimal). This seems to work 
 fine, but
 means there is a separate
 xml file to keep up to date, this looks like:
 
 ?xml version=1.0?
 
 translations
   !-- Types --
   custom-type name=price formatter=DecimalFormat
 application-pattern=0.##
 input-pattern value=0.##/
 output-pattern value=0.00/
   /custom-type
   custom-type name=ordernumber formatter=DecimalFormat
 application-pattern=0
 input-pattern value=#,###,###,##0/
 output-pattern value=0,000,000,000/
   /custom-type
   custom-type name=quantity formatter=DecimalFormat
 application-pattern=0.##
 pattern value=0.##/
   /custom-type
   custom-type name=integerquantity formatter=DecimalFormat
 application-pattern=0
 pattern value=0/
   /custom-type
   custom-type name=percent formatter=DecimalFormat
 application-pattern=0.##
 pattern value=0.##/
   /custom-type
   custom-type name=date formatter=SimpleDateFormat
 application-pattern=dd/MM/
 pattern value=dd/MM//
 pattern value=dd.MM. language=de country=DE/
 pattern value=dd.MM. language=de country=AT/
   /custom-type
   custom-type name=time formatter=SimpleDateFormat
 application-pattern=HH:mm
 pattern value=HH:mm/
   /custom-type
   !-- Form beans --
   form-bean class=com.pcmsgroup.SomeFormBean
 property name=price.value type=price/
 property name=quantity.value type=quantity/
   /form-bean
 /translations
 
 I've also extended the html:text and bean:write tags to translate back
 the other way, which uses the same
 translation utility. I gather that FormDef does most of this already,
 but we can't use it unfortunately...
 
 Does anyone think this code is useful generally?
 
 Simon
 
 The information contained in this e-mail is intended only for 
 the person
 or
 entity to which it is addressed and may contain confidential and/or
 privileged material. If You are not the intended recipient of this
 e-mail,
 the use of this information or any disclosure, copying or distribution
 is
 Prohibited and may be unlawful. If you received this in error, please
 contact the sender and delete the material from any computer. 
 The views
 expressed in this e-mail may not necessarily be the views of The PCMS
 Group
 plc and should not be taken as authority to carry out any instruction
 contained.
  
 
  -Original Message-
  From: Huw Richards [mailto:[EMAIL PROTECTED] 
  Sent: 06 December 2004 11:55
  To: Struts Users Mailing List
  Subject: RE: i18n input
  
  
  Hi
  
  It was something along those lines. 
  
  My business objects tend to have convert methods where I take 
  the strings of
  the value object (which have been created in the Action from 
  the form) and
  turn them into their correct types. I have a NumberUtil class 
  which I use
  for converting locale specific strings into BigDecimal. This 
  NumberUtil
  class has a static method which

RE: i18n input

2004-12-06 Thread Huw Richards
So does your translation code handle user input errors, like a number/date
in wrong format or does it make a best guess? 

Do you keep your translations.xml file upto date by hand or use ant to
generate at build time? My app has hundreds of forms with multiple
date/number fields.

I hadn't thought of extending the html:input  bean:write tags to include a
locale for formatting. Great idea! I convert the BigDecimals into a locale
formatted String for html:input and use the formatKey variable of bean:write
for display.

-Original Message-
From: Simon Matic Langford [mailto:[EMAIL PROTECTED] 
Sent: Monday, December 06, 2004 7:03 AM
To: 'Struts Users Mailing List'
Subject: RE: i18n input



___

*** WARNING ***

This email has been received from the internet. 
Check any attachments for viruses before opening them. 
___


hmm, that's what I've been trying to avoid.

I went for a somewhat sicker route :-)

I extended the request processor, so it called a new method called
processTranslate() just
after the validator is called! This then does exactly the same as the
population of the form
beans, but calls a translation routine to convert from the locale
specific format to the system
format which is english (a la BigDecimal). This seems to work fine, but
means there is a separate
xml file to keep up to date, this looks like:

?xml version=1.0?

translations
  !-- Types --
  custom-type name=price formatter=DecimalFormat
application-pattern=0.##
input-pattern value=0.##/
output-pattern value=0.00/
  /custom-type
  custom-type name=ordernumber formatter=DecimalFormat
application-pattern=0
input-pattern value=#,###,###,##0/
output-pattern value=0,000,000,000/
  /custom-type
  custom-type name=quantity formatter=DecimalFormat
application-pattern=0.##
pattern value=0.##/
  /custom-type
  custom-type name=integerquantity formatter=DecimalFormat
application-pattern=0
pattern value=0/
  /custom-type
  custom-type name=percent formatter=DecimalFormat
application-pattern=0.##
pattern value=0.##/
  /custom-type
  custom-type name=date formatter=SimpleDateFormat
application-pattern=dd/MM/
pattern value=dd/MM//
pattern value=dd.MM. language=de country=DE/
pattern value=dd.MM. language=de country=AT/
  /custom-type
  custom-type name=time formatter=SimpleDateFormat
application-pattern=HH:mm
pattern value=HH:mm/
  /custom-type
  !-- Form beans --
  form-bean class=com.pcmsgroup.SomeFormBean
property name=price.value type=price/
property name=quantity.value type=quantity/
  /form-bean
/translations

I've also extended the html:text and bean:write tags to translate back
the other way, which uses the same
translation utility. I gather that FormDef does most of this already,
but we can't use it unfortunately...

Does anyone think this code is useful generally?

Simon

The information contained in this e-mail is intended only for the person
or
entity to which it is addressed and may contain confidential and/or
privileged material. If You are not the intended recipient of this
e-mail,
the use of this information or any disclosure, copying or distribution
is
Prohibited and may be unlawful. If you received this in error, please
contact the sender and delete the material from any computer. The views
expressed in this e-mail may not necessarily be the views of The PCMS
Group
plc and should not be taken as authority to carry out any instruction
contained.
 

 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED] 
 Sent: 06 December 2004 11:55
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 Hi
 
 It was something along those lines. 
 
 My business objects tend to have convert methods where I take 
 the strings of
 the value object (which have been created in the Action from 
 the form) and
 turn them into their correct types. I have a NumberUtil class 
 which I use
 for converting locale specific strings into BigDecimal. This 
 NumberUtil
 class has a static method which takes a String and a Locale 
 as parameters
 and returns a BigDecimal.
 
 Huw
 
 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED] 
 Sent: Monday, December 06, 2004 5:05 AM
 To: 'Struts Users Mailing List'
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 huw,
 
 how did you handle this input on the server side? did you have some
 cunning scheme
 or just a lot of
 NumberFormat.getNumberInstance

Re: i18n input

2004-12-03 Thread Hubert Rabago
FormDef can help you with this.  https://formdef.dev.java.net. 
There's a locale.war sample app download which can work with different
locales.  It doesn't have support for BigDecimals, though (not yet,
anyway).
For displaying them on the screen, experiment bean:write with
format/formatKey/locale attributes.  If you use FormDef to specify
format keys, you can use the same key for form input and display.

Hubert


On Fri, 3 Dec 2004 09:49:52 -, Simon Matic Langford
[EMAIL PROTECTED] wrote:
 Is there a general pattern for localised input, ie being able to enter
 numbers and dates formatted for Germany but getting them formatted for
 Java on the server side for constructing BigDecimals etc, aside from
 using utilities in the java.text package? What about for displaying back
 the other way?
 
 I saw a post about this a couple of weeks ago but there was not
 response...
 
 Thanks
 
 Simon
 
 The information contained in this e-mail is intended only for the person
 or
 entity to which it is addressed and may contain confidential and/or
 privileged material. If You are not the intended recipient of this
 e-mail,
 the use of this information or any disclosure, copying or distribution
 is
 Prohibited and may be unlawful. If you received this in error, please
 contact the sender and delete the material from any computer. The views
 expressed in this e-mail may not necessarily be the views of The PCMS
 Group
 plc and should not be taken as authority to carry out any instruction
 contained.
 


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



RE: i18n input

2004-12-03 Thread Simon Matic Langford
yeah,

I've looked at formdef, unfortunately I'm using an extension to struts
which prevents me using this, is there anything else?

simon
 

 -Original Message-
 From: Hubert Rabago [mailto:[EMAIL PROTECTED] 
 Sent: 03 December 2004 14:53
 To: Struts Users Mailing List
 Subject: Re: i18n input
 
 
 FormDef can help you with this.  https://formdef.dev.java.net. 
 There's a locale.war sample app download which can work with different
 locales.  It doesn't have support for BigDecimals, though (not yet,
 anyway).
 For displaying them on the screen, experiment bean:write with
 format/formatKey/locale attributes.  If you use FormDef to specify
 format keys, you can use the same key for form input and display.
 
 Hubert
 
 
 On Fri, 3 Dec 2004 09:49:52 -, Simon Matic Langford
 [EMAIL PROTECTED] wrote:
  Is there a general pattern for localised input, ie being 
 able to enter
  numbers and dates formatted for Germany but getting them 
 formatted for
  Java on the server side for constructing BigDecimals etc, aside from
  using utilities in the java.text package? What about for 
 displaying back
  the other way?
  
  I saw a post about this a couple of weeks ago but there was not
  response...
  
  Thanks
  
  Simon
  
  The information contained in this e-mail is intended only 
 for the person
  or
  entity to which it is addressed and may contain confidential and/or
  privileged material. If You are not the intended recipient of this
  e-mail,
  the use of this information or any disclosure, copying or 
 distribution
  is
  Prohibited and may be unlawful. If you received this in 
 error, please
  contact the sender and delete the material from any 
 computer. The views
  expressed in this e-mail may not necessarily be the views 
 of The PCMS
  Group
  plc and should not be taken as authority to carry out any 
 instruction
  contained.
  
 
 
 -
 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: i18n input

2004-12-03 Thread Jim Barrows

 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
 Sent: Friday, December 03, 2004 2:50 AM
 To: [EMAIL PROTECTED]
 Subject: i18n input
 
 
 Is there a general pattern for localised input, ie being able to enter
 numbers and dates formatted for Germany but getting them formatted for
 Java on the server side for constructing BigDecimals etc, aside from
 using utilities in the java.text package? What about for 
 displaying back
 the other way?

Java comes with i18n built in.  You want the JSTL fmt:blah for output and look 
at the way message resources are handled in struts, as well as read through the 
i18n documentation on the sun site.

 
 I saw a post about this a couple of weeks ago but there was not
 response...
 
 
 Thanks
 
 Simon
 
 
 The information contained in this e-mail is intended only for 
 the person
 or
 entity to which it is addressed and may contain confidential and/or
 privileged material. If You are not the intended recipient of this
 e-mail,
 the use of this information or any disclosure, copying or distribution
 is
 Prohibited and may be unlawful. If you received this in error, please
 contact the sender and delete the material from any computer. 
 The views
 expressed in this e-mail may not necessarily be the views of The PCMS
 Group
 plc and should not be taken as authority to carry out any instruction
 contained.
  
 
 

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



RE: i18n input

2004-12-03 Thread Simon Matic Langford
yeah, I know I can do this, but this is a large system with around 200
jsps 80 views
and a number of controllers. doing the display is reasonably simple I
know, but extremely
tedious and prone to errors, I was hoping for a more elegant solution
which also handles
input...
 
 Java comes with i18n built in.  You want the JSTL fmt:blah 
 for output and look at the way message resources are handled 
 in struts, as well as read through the i18n documentation on 
 the sun site.


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



RE: i18n input

2004-12-03 Thread Jim Barrows


 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
 Sent: Friday, December 03, 2004 8:51 AM
 To: 'Struts Users Mailing List'
 Subject: RE: i18n input
 
 
 yeah, I know I can do this, but this is a large system with around 200
 jsps 80 views
 and a number of controllers. doing the display is reasonably simple I
 know, but extremely
 tedious and prone to errors, I was hoping for a more elegant solution
 which also handles
 input...

I believe it does handle input as well... depending on the browser, which java 
has no control over.  

  
  Java comes with i18n built in.  You want the JSTL fmt:blah 
  for output and look at the way message resources are handled 
  in struts, as well as read through the i18n documentation on 
  the sun site.
 
 
 -
 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: i18n input

2004-12-03 Thread Huw Richards
The one problem I had with i18n input was with European locales where , is
used as the decimal separator. The number would be formatted with , as the
decimal separator but as the input boxes are just text, the numeric keypad
which produces , in excel when . is pressed just produces . in the
number box. I had to rely on an adapted javascript to mask the numbers on
field entry  exit.

-Original Message-
From: Jim Barrows [mailto:[EMAIL PROTECTED] 
Sent: Friday, December 03, 2004 11:00 AM
To: Struts Users Mailing List
Subject: RE: i18n input



___

*** WARNING ***

This email has been received from the internet. 
Check any attachments for viruses before opening them. 
___




 -Original Message-
 From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
 Sent: Friday, December 03, 2004 8:51 AM
 To: 'Struts Users Mailing List'
 Subject: RE: i18n input
 
 
 yeah, I know I can do this, but this is a large system with around 200
 jsps 80 views
 and a number of controllers. doing the display is reasonably simple I
 know, but extremely
 tedious and prone to errors, I was hoping for a more elegant solution
 which also handles
 input...

I believe it does handle input as well... depending on the browser, which
java has no control over.  

  
  Java comes with i18n built in.  You want the JSTL fmt:blah 
  for output and look at the way message resources are handled 
  in struts, as well as read through the i18n documentation on 
  the sun site.
 
 
 -
 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]


___ 

CONFIDENTIALITY NOTE 

This message may contain confidential and privileged information. 
If you think, for any reason, that this message may have been 
addressed to you in error, you must not disseminate, copy or 
take any action in reliance on it and we would ask you to notify us 
immediately by return email to [EMAIL PROTECTED]. 

http://www.oprig.com 


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



RE: i18n input

2004-12-03 Thread Jim Barrows


 -Original Message-
 From: Huw Richards [mailto:[EMAIL PROTECTED]
 Sent: Friday, December 03, 2004 4:05 PM
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 The one problem I had with i18n input was with European 
 locales where , is
 used as the decimal separator. The number would be formatted 
 with , as the
 decimal separator but as the input boxes are just text, the 
 numeric keypad
 which produces , in excel when . is pressed just produces 
 . in the
 number box. I had to rely on an adapted javascript to mask 
 the numbers on
 field entry  exit.

Browser issue I believe which is not all that surprising I suppose.  
Normally Swing/AWT handle I18N quite well, the problem with web apps (any 
language) is the browser and what it thinks it should be doing.

 
 -Original Message-
 From: Jim Barrows [mailto:[EMAIL PROTECTED] 
 Sent: Friday, December 03, 2004 11:00 AM
 To: Struts Users Mailing List
 Subject: RE: i18n input
 
 
 
 ___
 
 *** WARNING ***
 
 This email has been received from the internet. 
 Check any attachments for viruses before opening them. 
 ___
 
 
 
 
  -Original Message-
  From: Simon Matic Langford [mailto:[EMAIL PROTECTED]
  Sent: Friday, December 03, 2004 8:51 AM
  To: 'Struts Users Mailing List'
  Subject: RE: i18n input
  
  
  yeah, I know I can do this, but this is a large system with 
 around 200
  jsps 80 views
  and a number of controllers. doing the display is 
 reasonably simple I
  know, but extremely
  tedious and prone to errors, I was hoping for a more 
 elegant solution
  which also handles
  input...
 
 I believe it does handle input as well... depending on the 
 browser, which
 java has no control over.  
 
   
   Java comes with i18n built in.  You want the JSTL fmt:blah 
   for output and look at the way message resources are handled 
   in struts, as well as read through the i18n documentation on 
   the sun site.
  
  
  
 -
  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]
 
 
 ___ 
 
 CONFIDENTIALITY NOTE 
 
 This message may contain confidential and privileged information. 
 If you think, for any reason, that this message may have been 
 addressed to you in error, you must not disseminate, copy or 
 take any action in reliance on it and we would ask you to notify us 
 immediately by return email to [EMAIL PROTECTED]. 
 
 http://www.oprig.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]