问题
How to display Korean Text in a webpage. i have been using these meta tags and headers
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="content-language" content="ko"/>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1"/>
ini_set('default_charset', 'UTF-8');
header('Content-Type: text/html;charset=utf-8');
But nothing works.. please help!!
NOTE: I tried every tag 1 at a time not all at once.
回答1:
Use:
ini_set('default_charset', 'UTF-8');
header('Content-Type: text/html;charset=utf-8');
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
and make sure your editor is configured to save using UTF-8, and make sure that any other systems involved (e.g. databases) are configured to use utf-8.
回答2:
Your example has two META tags - one is UTF-8 and the other is ISO-8859-1.
来源:https://stackoverflow.com/questions/2107249/php-displaying-korean-text-in-a-webpage