[opencms-dev] different behavior while handling special characters

Harish.Chakravarthy at sjsu.edu Harish.Chakravarthy at sjsu.edu
Fri Feb 20 22:24:01 CET 2004


Hi Everyone,

I am see different behavior while handling special characters when 
form method=post and form method=post enctype=multipart/form-data. 
I am using utf-8 encoding

Case I:
1.A I have a form with method=post
    name : San José                               // Note accent mark

1.B In CmsRequestHttpServlet.getParameter(), I print the value received -
    name : San José                              // accent mark has 
changed

1.C Write this value to Mysql DB (name field is of type varchar)
    name field in table has value:  San José     // Same as input

1.D When I view this field in edit mode (EditBackoffice)
    name : San Jos?                              // Accent is  replace by 
a ?

Case II:

2.A I have a form with method=post enctype=multipart/form-data
    name : San José                               // Note accent mark

2.B In CmsRequestHttpServlet.getParameter(), I print the value received -
    name : San JosÃé    // this values is different from 1.B for the same 
name input

2.C Write this value to Mysql DB (name field is of type varchar)
    name field in table has value:  San José     // Different from input

2.D When I view this field in edit mode (EditBackoffice)
    name : San José                               // works !

Any idea, as to what is happening here.

Thanks
Harish
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20040220/e63eb572/attachment.htm>


More information about the opencms-dev mailing list