/    Sign up×
Community /Pin to ProfileBookmark

Unicode character question

Does anyone have an example of how to
1. specify unicode character sets and
2. use the unicodes to display the desired characters.

I have looked at: [url]http://unicode.org/[/url]
but I have yet to find a javascript specific example.
I have ‘googled’ the word, but most examples use server side solutions (?) with php, etc.

I’m not looking in the right place or I don’t understand what I’m looking at.
I have tried:
1. document.write(‘u+code’)
2. document.write(ucode) // where ucode is a specified variable value

I was trying using the ‘utf-8’ and ‘utf-16’ character sets in the <meta…> statement just after the <head> tag.

Any small example that works better than my feable attempts would be helpful.

Thanks.

to post a comment
JavaScript

1 Comments(s)

Copy linkTweet thisAlerts:
@FangFeb 04.2007 — document.write('u0055u006Eu0069u0063u006Fu0064u0065');
BabelMap is useful for all the codes
×

Success!

Help @JMRKER spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 4.29,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...