Solved

HTML Entities and Browsers

Posted on 2007-03-21
4
371 Views
Last Modified: 2012-06-27
Hi Experts,

I am generating HTML pages from XML. I would like to know whether the XML entities and HTML are same.

ie., For instance, XML "Thin Space" has the entity code " ", I would like to know whether I have to code this XML entity as "&#x02009" or "&#02009" in HTML without the 'x'.

I am seeing a difference in recognizing the entities in Firefox and in IE. For Instance, the entity "Thin Space" is reflected as a "Thin Space" in Firefox but it is displayed as a box character in IE. The Character Encoding selected in both the browsers are UTF-8.

Please advice.

Regards
Vijay T. Prabakar
0
Comment
Question by:CIPL-Senthil
4 Comments
 
LVL 60

Accepted Solution

by:
Geert Bormans earned 250 total points
ID: 18769547
yes, they are the same.
The number is the character referenece in the unicode standard
Every modern browser should be able to show the exact glyph based on the entity

Of course the particulara glyph needs to be supported in the font-family/size/weight/decoration combination you use

FireFox points by default to a font family that supports most of the unicode characters
IE shows a box, because it has no glyph available
You can swithch the default characterset to a unicode set in the browser
but you can't expect that all your users would do so

If you encounter a problem with a character in IE,
it might be wise to work around that one
eg. a thin space could be replaced by a space in a span with a smaller font-size

cheers

Geert
0
 
LVL 75

Assisted Solution

by:Michel Plungjan
Michel Plungjan earned 250 total points
ID: 19347831
and this?

 

should work in all browsers in all codepages?
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Foreword (July, 2015) Since I first wrote this article, years ago, a great many more people have begun using the internet.  They are coming online from every part of the globe, learning, reading, shopping and spending money at an ever-increasing ra…
This is a PowerShell web interface I use to manage some task as a network administrator. Clicking an action button on the left frame will display a form in the middle frame to input some data in textboxes, process this data in PowerShell and display…
The viewer will receive an overview of the basics of CSS showing inline styles. In the head tags set up your style tags: (CODE) Reference the nav tag and set your properties.: (CODE) Set the reference for the UL element and styles for it to ensu…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now