Why am I seeing the Unicode Replacement Character in text inputs but not textareas for the same character?
I have the letter Ü (U+00DC) rendering properly in textareas but I'm seeing the Unicode replacement character in text inputs and divs. I've got the utf-8 meta tag on my site.开发者_运维技巧
Any ideas why?
Thanks
I resolved the issue by adding UTF-8 syntax to mysql, apache headers, php code and anywhere else I could think of.
The major difference between a text input and a text area is that the value of a text area is within a block (<textarea>[value]</textarea>
) and is the value of an attribute in a text input (<input value="[value]">
). My best guess is that most likely your browser is parsing and translating the unicode replacement when it comes to text within an element block and not doing so for text of an attribute.
精彩评论