You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Miguel Paraz <mp...@gmail.com> on 2008/06/25 15:37:09 UTC

UTF-8 Byte Order Marks in .html files

Hi,
I found out - through a lot of trial and error - that if your .html
file has a Byte Order Mark, the <?xml encoding="utf-8" ?> at the top
of the document is ignored.
The document is treated as something else - I'm not sure what.

The effect is that the special output characters become the <?>
unknown characters.

Is this a known issue?
Thanks.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: UTF-8 Byte Order Marks in .html files

Posted by Miguel Paraz <mp...@gmail.com>.
On Thu, Jun 26, 2008 at 4:25 AM, Sven Meier <sv...@meiers.net> wrote:
> Hi,
>
> if your editor prefixes your templates with a BOM(1), Wicket is not able to
> recognize the encoding in your xml declaration, see
> org.apache.wicket.util.io.XmlReader#xmlDecl .
>
> You might want to create a JIRA request, that Wicket should skip a leading
> BOM in the encoding detection.

Hi Sven,
Thanks for pointing this out!

I do not need to file a JIRA request - I just wanted to know the
behavior, since it's not documented in the Wicket internationalization
wikis/blogs I found.

I'm using Notepad++ (on Windows) which has the choices "UTF-8" and
"UTF-8 without BOM," which to a newbie like me makes it appear that
having the BOM is the default.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: UTF-8 Byte Order Marks in .html files

Posted by Sven Meier <sv...@meiers.net>.
Hi,

if your editor prefixes your templates with a BOM(1), Wicket is not able 
to recognize the encoding in your xml declaration, see 
org.apache.wicket.util.io.XmlReader#xmlDecl .

You might want to create a JIRA request, that Wicket should skip a 
leading BOM in the encoding detection.

Regards

Sven

1 - http://de.wikipedia.org/wiki/Byte_Order_Mark

Brill Pappin schrieb:
> Not sure what you mean by BOM (Bill Of Materials?)
>
> However I have seen something odd with documents there were generated 
> on a Mac with little "?" in various places.
>
> - Brill Pappin
>
> On 25-Jun-08, at 2:22 PM, Miguel Paraz wrote:
>
>> On Wed, Jun 25, 2008 at 9:51 PM, Brill Pappin <br...@pappin.ca> wrote:
>>> I think it might be your browser that is not displaying the unicode 
>>> chars.
>>> That you see the odd symbols at all means that the made it to the 
>>> client
>>> side.
>>>
>>> Are you on a Mac?
>>
>> Hi! Thanks for the reply.
>>
>> No, I'm on Firefox 3 on Windows.
>>
>> Do you have an idea why removing the BOM fixes it?
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>> For additional commands, e-mail: users-help@wicket.apache.org
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: UTF-8 Byte Order Marks in .html files

Posted by Brill Pappin <br...@pappin.ca>.
Not sure what you mean by BOM (Bill Of Materials?)

However I have seen something odd with documents there were generated  
on a Mac with little "?" in various places.

- Brill Pappin

On 25-Jun-08, at 2:22 PM, Miguel Paraz wrote:

> On Wed, Jun 25, 2008 at 9:51 PM, Brill Pappin <br...@pappin.ca> wrote:
>> I think it might be your browser that is not displaying the unicode  
>> chars.
>> That you see the odd symbols at all means that the made it to the  
>> client
>> side.
>>
>> Are you on a Mac?
>
> Hi! Thanks for the reply.
>
> No, I'm on Firefox 3 on Windows.
>
> Do you have an idea why removing the BOM fixes it?
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: UTF-8 Byte Order Marks in .html files

Posted by Miguel Paraz <mp...@gmail.com>.
On Wed, Jun 25, 2008 at 9:51 PM, Brill Pappin <br...@pappin.ca> wrote:
> I think it might be your browser that is not displaying the unicode chars.
> That you see the odd symbols at all means that the made it to the client
> side.
>
> Are you on a Mac?

Hi! Thanks for the reply.

No, I'm on Firefox 3 on Windows.

Do you have an idea why removing the BOM fixes it?

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: UTF-8 Byte Order Marks in .html files

Posted by Brill Pappin <br...@pappin.ca>.
I think it might be your browser that is not displaying the unicode  
chars.
That you see the odd symbols at all means that the made it to the  
client side.

Are you on a Mac?

- Brill Pappin

On 25-Jun-08, at 9:37 AM, Miguel Paraz wrote:

> Hi,
> I found out - through a lot of trial and error - that if your .html
> file has a Byte Order Mark, the <?xml encoding="utf-8" ?> at the top
> of the document is ignored.
> The document is treated as something else - I'm not sure what.
>
> The effect is that the special output characters become the <?>
> unknown characters.
>
> Is this a known issue?
> Thanks.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
> For additional commands, e-mail: users-help@wicket.apache.org
>


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org