3

Ok, so I want to have the characters from below in my html page. Seems easy, except I can't find the HTML encoding for them.

alt text

Note: I would like to do this without having sized elements, plain ol' text would be fine ^_^.

Cheers.

Barrie Reader
  • 10,647
  • 11
  • 71
  • 139

5 Answers5

6

You can see that they have a unicode number of the selected character - at the bottom of the picture ("U+266A: Eighth Note").

Simply use the last portion in a unicode character entity: ♪ - ♪

If your page is already UTF-8, you can simply paste it in.

Oded
  • 489,969
  • 99
  • 883
  • 1,009
4

Try encoding it as █ - that should do the trick!

Ryano
  • 2,125
  • 3
  • 20
  • 28
3

In a UTF-8 encoded page, just copy and paste them as-is.

Otherwise, use the number that the dialog gives you for each character, e.g. ♪

However, when working with rather exotic characters, be very wary of font support. See e.g. this question for background: Unicode support in Web standard fonts

This page gives some information about support for the characters you want to use. They seem to be relatively well supported, but a test on Linux and Mac machines won't hurt.

Community
  • 1
  • 1
Pekka
  • 442,112
  • 142
  • 972
  • 1,088
  • I just want to add that most webframeworks (e.g. PHP) deliver UTF-8 encoded HTML if you save the template as UTF-8 encoded. You should use an editor that uses this as default encoding. – Richard Metzler Nov 16 '10 at 09:57
2

Here is one comprehensive entity reference. If you want to convert symbols into their entity counterparts, I suggest using this converter.

niksy
  • 625
  • 1
  • 7
  • 19
1

My suggestion is to use hexadecimal reference. ( it's easy dont worry :) )

for example, the first character you have highlighted in red got ascii value of 175, which is AF in hex.

So in short you can encode it using %AF, and so on...

is it clear mate? Let me know if you need further explanation or help about this :)

Edit: my post is meant for url encoding.

Oliver M Grech
  • 3,071
  • 1
  • 21
  • 36