cancel
Showing results for 
Search instead for 
Did you mean: 

About Task forms encoding...

jcosano
Champ in-the-making
Champ in-the-making
Since I installed RC1 I have problems with Activiti Explorer and encoding.

I need use ISO-8859-15

I put in catalina.bat (windows environment)

set JAVA_OPTS=%JAVA_OPTS% %LOGGING_CONFIG% -Dfile.encoding=ISO-8859-15

but no works…

I put "bin" and "conf" folder (tomcat)  from activiti beta2 (that works fine for me) but error continue…

You known if application force a UTF-8 encoding?

thanks!
15 REPLIES 15

jcosano
Champ in-the-making
Champ in-the-making
Problem is only with task forms…

Users with special characters are showed fine (at Activiti Explorer right top)… or when i'm seeing directly to table in Probe…

frederikherema1
Star Contributor
Star Contributor
Explorer and Probe uses UTF-8 as output for rendering all templates, using freemarker. This adds a "charset=utf-8" to the content-type header.

DeploymentResources and Forms aren't fetched through the freemarker, but are streamed directly from the raw bytes in the database.
Here, no charset is defined (content-type is just "text/html" instead of "text/html;charset=utf-8") and probably this is why the forms don't show up as they should (your browser will use the default encoding for this, being you platform encoding).

Can you send an example form/process so we can reproduce this easily so we can create an issue for this?

jcosano
Champ in-the-making
Champ in-the-making
Sample init.form

      <table border ="2" bordercolor="#990000" align="center"><tr><td>
      <table border="0" align="center">
   <tr>
    <td colspan="2" align="center" bgcolor="#990000">
    <font color="#FFFFFF"><strong>Informació de l'alta:</strong></font>
    </td>
      </tr>
   <tr>
    <td>Unitat:</td>
    <td>
   <select name="subunitat">
    <option value="AUTOMÓVILES">AUTOMÓVILES </option>
    <option value="HISTÒRIA">HISTÒRIA</option>   
   </select>
    </td>
      </tr>
   </table>
   </td></tr></table>

jcosano
Champ in-the-making
Champ in-the-making
If you need a complete project, I can do it…

but I think that if you put this code in any of your forms is enough.

frederikherema1
Star Contributor
Star Contributor
The form will do, thanks Smiley Wink

jcosano
Champ in-the-making
Champ in-the-making
Conflictive words:

Informació
Automóviles
Història
Sueño
Plaça
Güell

frederikherema1
Star Contributor
Star Contributor
You should escape these characters, using &Oacute; and &Ograve; according to HTML-specs to be safe.

jcosano
Champ in-the-making
Champ in-the-making
Yes.. but If I have a text box (or textarea) then  I can't force to an user that use this html encoding…

This solve labels but not info introduced by an application user.

frederikherema1
Star Contributor
Star Contributor
I see…

* Can you try this:  fill in "Informació" in the "Employee name:" field of the example process "Vacation request" when starting the process.
* Go to Tasks and claim the unassigned task
* Does the task-description look good? (should be something like Vacation request by Informació)
* Click on "Complete Form", top of form has description that should look like this: Informació would like to take 1 day(s) of vacation -> does it?

Currently, the JSON and rendered form doesn't escape any characters to HTML escape-sequences.