[
https://issues.apache.org/jira/browse/WOOKIE-93?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13125978#comment-13125978
]
Paul Sharples edited comment on WOOKIE-93 at 10/12/11 5:15 PM:
---------------------------------------------------------------
Verified. I created a widget to test this. In the index.html start page i set
the following..
<meta http-equiv="Content-Type" content="application/x-shockwave-flash;" />
In the config.xml...
<content src="index.html" encoding="GB2312" type="text/html" />
Once imported into wookie the line in index.html had changed to...
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
This is because in the W3CWidgetFactory class we only have utf-8 set as a valid
encoding. For a test I changed line 94 of the W3CWidgetFactory class to read..
this.encodings = new String[]{"UTF-8","GB2312"};
and then recompiled and ran the test again. This time the result in index.html
was...
<meta http-equiv="Content-Type" content="text/html;charset=GB2312" />
..and the page had a different type font. All as expected.
The only thing I think we should change, is to pick the default encoding/s out
of a properties file, rather then have a string array in the W3CWidgetFactory
class.
was (Author: psharples):
Verified. I created a widget to test this. In the index.html start page i
set the following..
<meta http-equiv="Content-Type" content="application/x-shockwave-flash;" />
In the config.xml...
<content src="index.html" encoding="GB2312" type="text/html" />
Once imported into wookie the line in index.html had changed to...
<meta http-equiv="Content-Type" content="text/html;charset=utf-8" />
This is because in the W3CWidgetFactory class we only have utf-8 set as a valid
encoding. For a test I changed line 94 of the W3CWidgetFactory class to read..
this.encodings = new String[]{"UTF-8","GB2312"};
and then recompiled and ran the test again. This time the result in index.html
was...
<meta http-equiv="Content-Type" content="text/html;charset=GB2312" />
..and the page had a different type font. All as expected.
The only thing I think we should change, is to pick the default encoding out of
a properties file, rather then have a string array in the W3CWidgetFactory
class.
> Implementing charset selection for start files
> ----------------------------------------------
>
> Key: WOOKIE-93
> URL: https://issues.apache.org/jira/browse/WOOKIE-93
> Project: Wookie
> Issue Type: Sub-task
> Reporter: Scott Wilson
> Assignee: Scott Wilson
> Fix For: 0.9.1
>
> Original Estimate: 2h
> Time Spent: 2h
> Remaining Estimate: 0h
>
> When a start file is returned, it should let a charset defined in config.xml
> where present override the default charset.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira