IE6ユーザへのアップデートをスマートに促すことが可能な「ie6update.js」
2009年07月31日-
スポンサード リンク
IE6 Update
IE6ユーザへのアップデートをスマートに促すことが可能な「ie6update.js」。
Windowsユーザの方ならご存知の、ブラウザ最上部に表示される情報バーのようにやんわりとアップデートを促してくれるJavaScriptコードです。

最近、海外のサイトを見ているとこの仕組みを使ったサイトをよく見かけますよね。
実装は、サイト上に掲載されているコードを貼り付けるだけで実装できるという容易さもGood!

コードは以下で、googleのホスティングするjQueryコードなどを読み込むものになっています。
<!--[if IE 6]>
<script type="text/javascript">
/*Load jQuery if not already loaded*/ if(typeof jQuery == 'undefined'){ document.write("<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></"+"script>"); var __noconflict = true; }
var IE6UPDATE_OPTIONS = {
icons_path: "http://static.ie6update.com/hosted/ie6update/images/"
}
</script>
<script type="text/javascript" src="http://static.ie6update.com/hosted/ie6update/ie6update.js"></script>
<![endif]-->
日本語にしたい場合は、コードをダウンロードして自分のサーバに設置することも出来るので、その方法で実装できます。
追記) 次のように記述することで日本語に簡単にできるみたいです。
<!--[if IE 6]>
<script type="text/javascript">
/*Load jQuery if not already loaded*/ if(typeof jQuery == 'undefined'){ document.write("<script type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js\"></"+"script>"); var __noconflict = true; }
var IE6UPDATE_OPTIONS = {
icons_path: "http://static.ie6update.com/hosted/ie6update/images/",
message: "このサイトを快適に閲覧するにはInternet Explorerのアップグレードが必要です。ここをクリックして最新版をダウンロードし、インストールしてください...",
url: "http://www.microsoft.com/japan/windows/internet-explorer/default.aspx"
}
</script>
<script type="text/javascript"
src="http://static.ie6update.com/hosted/ie6update/ie6update.js"></script>
<![endif]-->
coolmint さん、ありがとうございました。
関連エントリ
IE6ユーザへのアップデートをスマートに促すことが可能な「ie6update.js」。
Windowsユーザの方ならご存知の、ブラウザ最上部に表示される情報バーのようにやんわりとアップデートを促してくれるJavaScriptコードです。

最近、海外のサイトを見ているとこの仕組みを使ったサイトをよく見かけますよね。
実装は、サイト上に掲載されているコードを貼り付けるだけで実装できるという容易さもGood!

コードは以下で、googleのホスティングするjQueryコードなどを読み込むものになっています。
<!--[if IE 6]>
<script type="text/javascript">
/*Load jQuery if not already loaded*/ if(typeof jQuery == 'undefined'){ document.write("<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js"></"+"script>"); var __noconflict = true; }
var IE6UPDATE_OPTIONS = {
icons_path: "http://static.ie6update.com/hosted/ie6update/images/"
}
</script>
<script type="text/javascript" src="http://static.ie6update.com/hosted/ie6update/ie6update.js"></script>
<![endif]-->
追記) 次のように記述することで日本語に簡単にできるみたいです。
<!--[if IE 6]>
<script type="text/javascript">
/*Load jQuery if not already loaded*/ if(typeof jQuery == 'undefined'){ document.write("<script type=\"text/javascript\" src=\"http://ajax.googleapis.com/ajax/libs/jquery/1.3.2/jquery.min.js\"></"+"script>"); var __noconflict = true; }
var IE6UPDATE_OPTIONS = {
icons_path: "http://static.ie6update.com/hosted/ie6update/images/",
message: "このサイトを快適に閲覧するにはInternet Explorerのアップグレードが必要です。ここをクリックして最新版をダウンロードし、インストールしてください...",
url: "http://www.microsoft.com/japan/windows/internet-explorer/default.aspx"
}
</script>
<script type="text/javascript"
src="http://static.ie6update.com/hosted/ie6update/ie6update.js"></script>
<![endif]-->
coolmint さん、ありがとうございました。
関連エントリ
スポンサード リンク
Advertisements
SITE PROFILE
最新のブログ記事(新着順)
- CSSのみで実装された500種類のローディングアニメーション「CSS Loaders」
- 画像ホバーで様々なエフェクトをかけられる「Izmir」
- CSSのbox-shadowをGUIで生成できる「CSS Box Shadows Generator」
- 好きな画像や文字を埋め込んだQRコードをリアルタイムで作れるWEBツール
- 約7500種の汎用ピクトグラムアイコン集「Phosphor Icons」
- ほぼCSSで実装されたUIフレームワーク「Ellegant CSS」
- TailwindCSSベースの150種類以上のUIライブラリ「SailboatUI」
- 1700種類以上のSVGアイコン「MingCute Icon」
- 2000種類以上の汎用ピクトグラムアイコン集「Atlas Icons」
- かわいい手書き風フォント「うさぎとまんげつのサンセリフ」
- 過去のエントリ