<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>IE | ウダ2Blog</title>
	<atom:link href="https://uda2.com/blog/tag/ie/feed/" rel="self" type="application/rss+xml" />
	<link>https://uda2.com/blog</link>
	<description>大阪でフリーランスとしてWEB制作している管理人が気になった技術をメモったり、作ったツールの紹介などを綴っているブログです。</description>
	<lastBuildDate>Tue, 30 Oct 2018 16:00:08 +0000</lastBuildDate>
	<language>ja</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9</generator>
	<item>
		<title>文字コードを疑え！</title>
		<link>https://uda2.com/blog/utf/</link>
					<comments>https://uda2.com/blog/utf/#respond</comments>
		
		<dc:creator><![CDATA[uda2]]></dc:creator>
		<pubDate>Tue, 24 Feb 2015 02:12:24 +0000</pubDate>
				<category><![CDATA[制作日記]]></category>
		<category><![CDATA[IE]]></category>
		<category><![CDATA[文字コード]]></category>
		<guid isPermaLink="false">http://uda2.com/blog/?p=1663</guid>

					<description><![CDATA[<p>毎回では無いがPHPのようにサーバで生成されるページのデザイン等を修正するのに一旦HTMLとして保存し、静的ページとして保存してスタイルシートやJavaScriptを修正を進めたりする事もある。 今日もログイン後のページ</p>
The post <a href="https://uda2.com/blog/utf/">文字コードを疑え！</a> first appeared on <a href="https://uda2.com/blog">ウダ2Blog</a>.]]></description>
										<content:encoded><![CDATA[<p>毎回では無いがPHPのようにサーバで生成されるページのデザイン等を修正するのに一旦HTMLとして保存し、静的ページとして保存してスタイルシートやJavaScriptを修正を進めたりする事もある。<br />
今日もログイン後のページの修正でログインが面倒なのでダウンロードしたHTMLをInternetExplorerで確認しながら修正を進めていき一段落が付いたのでFireFoxとChromeで確認してみると「SyntaxError: illegal character」（OperaだとUncaught SyntaxError: Unexpected token ILLEGAL）というエラーが現れスクリプトエラーになって動作しなくなった。<br />
ネットで検索しても解決法は見つからず小一時間ほど悩んでいたが、ふとエディタのウインドウ下のバーに見慣れない文字に気づいた。<br />
「UTF-16LE」<br />
作ったのは「UTF-8」でHTMLの宣言も「UTF-8」にしてるが、Internet Explorerで「ソースの表示」から「ファイル」の「上書き保存」とするとUTF-16LEで保存されるようだ（ちなみにOSはWindows2000から内部文字コードがUTF-16らしいが、少なくともInternetExplorer8までは正常な文字コード（UTF-8）で保存される）。<br />
IE以外は「UTF-16LE」のHTMLから見て「UTF-8」の外部ファイルを「UTF-16LE」と勘違いして読み込もうとして文字化けしてそれが不正な文字（illegal character）としてエラーになっていたようで、エディタにて「UTF-8」に戻したら直った。</p>
<p>ちなみにInternetExplorerでもソースを表示せずに「ファイル」「名前を付けて保存」からだと文字コードを選択可能ですし、標準でソースの文字コードが選択されてるので問題無いです。</p>The post <a href="https://uda2.com/blog/utf/">文字コードを疑え！</a> first appeared on <a href="https://uda2.com/blog">ウダ2Blog</a>.]]></content:encoded>
					
					<wfw:commentRss>https://uda2.com/blog/utf/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
