tags:

views:

751

answers:

5

Hi!

Inside an asp.net page, shoul I use

<html><title>My page's title from México</title></html>

Or

<html><title>My page's title from M&eacute;xico</title></html>

Both examples have same output. Since asp.net encodes all my pages to utf-8 there is no need to use html entities, is that right?

Thanks a lot.

+3  A: 

The second example will ensure compatibility with ASCII standards of HTML transmition. So my vote is for the second example, so you don't have to ensure the HTML is output and encoded as UTF-8 all the way through all the proxy servers and any other kind of caching and translation that might occur.

Nick Berardi
+2  A: 

You're correct; As long as there's unicode at both ends of the pipe, it really doesn't matter. Personally, I would use the first simply because it's more readable.

And, honestly, unicode has been widespread for some time. I personally believe that it's time to leave anyone who can't handle UTF-8 behind.

DannySmurf
A: 

Thanks to both of you.

@Nick, do you have any example of an ASCII standard from an HTML transmition?

Back in the asp days, I always used the HTML entities. When I started using asp.net, I kept with it but more as an habit. Now I guess, both usage can be justified. I think it depends on how widespread your web application has to be. Since in my case, it's only an intranet application, the first example should be good enough.

jdecuyper
A: 
Andrew G. Johnson
+2  A: 

The ASCII table is set of characters, arguable the first standardized set of characters back in the days when you could only spare 1 byte per character. http://asciitable.com/ But I did some looking around at the extended character set of ASCII and it appears that the character you are referencing is an ASCII character. So there really isn't a problem which ever way you choose to display your title.

My revised answer is go for less expensive one according to space (i.e. the first one)

Nick Berardi
I know this is old, but e acute is not an ASCII character.
Matthew Flaschen