Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Web CMS (TeamSite)
handle special characteres?
motlnt
hi all,
I am facing this issue in rendering the special characters on the HTML screen...
one of my callout from the new DCR screen is showing special characters as junk characters..
this callout makes a sql query and brings up following results:
Analys av pensionsåtaganden
Befattnings- och organisationsfrågor
Beräkningar enligt IAS, USGAAP, m fl
Flexibla förmåner
Fusioner och förvärv
Gruppförsäkring
while showing in the HTML it shows junk characters like a 'square' for characters 'å' and '?' for 'örvä'
I am using following code to render them on HTML:
my $html_services;
open(HTML_SERVICES, "<$HTML_SERVICES_PATH");
while( <HTML_SERVICES> ) {
$html_services .= $_;
}
close(HTML_SERVICES);
# Substituting values in the html.
$html_services =~ s|__SVC_AREA_OPTIONS__|$svc_area_options|g;
any comments?
my env:TS 6.5
win2k3 ent edition
thx in advance...
Find more posts tagged with
Comments
Adam Stoller
Two thoughts come to mind:
First - change:
open(HTML_SERVICES, "<$HTML_SERVICES_PATH");
to:
open(HTML_SERVICES,
'<:utf8',
"$HTML_SERVICES_PATH");
Second, make sure that your browser is set to use UTF-8 encoding (actually, you might be able to do that with a meta tag too - but I don't remember the syntax off-hand)
Hope that helps.
--fish
Senior Consultant, Quotient Inc.
http://www.quotient-inc.com
jed
I think this is the correct meta tag:
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=UTF-8" />
--
Jed Michnowicz
jedm@sun.com
Content Management Engineering
Sun Microsystems
Johnny
This
post
shows how to handle UTF-8 files without needing to alter the "open" statement.
John Cuiuli
motlnt
it worked!!
thx for comments...