HTML の IMG タグの SRC に存在しない画像を指定した場合、IE などでは「×」印がでてしまいます(alt タグを書いておいても IE では×印はなくなりません)。それを画像などの読み込みに失敗したときに発生するイベント「onError」を使ってIMG タグ自体を消してしまう方法が以下です。 (応用で代替画像を表示することも可能) <div id="img1" class="img_div"> <img src="../../parts/ktai_imgs/200901docomo.jpg" onError="document.getElementById('img1').innerHTML='';" /> </div> <div id="img2" class="img_div"> <img src="../../parts/ktai_imgs/200901docomo_n
.htaccessを使用して、他のサイトが画像などのファイルを無許可で使用するのを禁止する方法をThe Web Squeezeから紹介します。 Stop Image Hotlinking with .htaccess 「.htaccess」に、下記を記述します。 ※必要の無い箇所は、削除・修正して使用してください。 ※「.htaccess」を修正する場合は、必ずバックアップをしてください。 ※有効範囲は、設置ディレクトリの配下です。 <textarea name="code" class="html" cols="60" rows="5"> #Stop Image Hotlinking RewriteEngine on RewriteCond %{HTTP_REFERER} !^http(s)?://(www\.)?yourdomain.com [NC] RewriteCond %{HTT
yamaokaです。 webページの表示を高速化する手法にはいろいろありますが、 その一つとして遅延読み込みという手法があります。 初期状態で表示する必要のない要素については読み込まず、 必要になったタイミングで読み込み、表示するようにする手法です。 ページの読み込みにかかる時間の大半を 画像の読み込みが占めている場合が多いので、 画像の読み込みを遅延させるという手法が多く取られます。 検討するべきケース では、画像の遅延読み込みはどのような場合に検討されるべきでしょうか。 最初から表示されている必要がない画像が存在し、その画像のサイズが大きかったり、 そうした画像の数が多い場合は検討してみる価値があると思います。 例えば、次のようなケースです。 初期状態では表示されないブロックに属する画像が存在し、 JavaScriptで表示するかしないかを切り替えているような場合 ページのずーっと下の
2006年10月03日05:50 カテゴリ perl+javascript - IEでdata:スキームを有効に! やろうと思えばできるものですねえ。 [JavaScript] dataスキームURI生成(画像データのBase64変換) 残念ながら Internet Explorer は data スキームに対応していないので利用できません。 [を] HTMLファイルに文字列として画像データを埋め込む表示は IE6 ではだめだけど、Firefox だとOK。今は亡きMac IEでも見れました。以下、data:スキームによるアイコンが二つ。 要は、中で駄目なら外に出してしまえばいいということです。inside outなので、dataを裏返してatadとしています。 atad.cgi #!/usr/local/bin/perl -T # # $Id: atad.cgi,v 0.1 2006/1
This webpage was generated by the domain owner using Sedo Domain Parking. Disclaimer: Sedo maintains no relationship with third party advertisers. Reference to any specific service or trade mark is not controlled by Sedo nor does it constitute or imply its association, endorsement or recommendation.
XMLHttpRequest を使って取得したバイナリーデータ(画像)をブラウザに表示してみました。firefox のみ。 JavaScriptでバイナリを扱う & XPCOMを使ってローカルのデータベースにアクセス with Firefox の記事を読んでいて、そういや Ajax ではどうなん?と思ってやってみた。 ■ 他に参考にしたのは以下の記事。 [comp]JavaScriptでバイナリファイルの中身にアクセスできた ■ base64 エンコードには下記のコードを使いました。 JavaScript で Base64 の符号化と復号化 <html><head> <script type="text/javascript" src="base64.js"></script> <script type="text/javascript"> load_url = function(url)
Downloading Binary Streams with Javascript XMLHttpRequest (or How to do Binary Ajax) I've been fiddling around trying to download a binary stream using the object XmlHttpRequest (XHR) of Javascript in Mozilla Firefox. What I wanted was to be able to create a byte array containing the original bytes of the downloaded binary file. This mechanism would be used to implement a ROM loader, without modi
An alternative to image-only CSS maps has been published. If you're looking for an easier way of creating image maps involving a single image, you may be interested in reading CSS Image Maps, Redux Below is a sample image map that's built entirely using CSS and XHTML. While I've added support for Javascript (item titles are simply displayed beneath the image), I've disabled it in this example -- I
Note: If you registered before January 2013, you can login to the tools with your existing WW login. Otherwise, please register a new account for the tools. For four years we have operated Webmasterworld under the quiet terms of a contributionware site. It continues to be our goal to raise the quality of material available on Webmasterworld and to remain an independent site that serves the communi
Enterprise Strategy Group: Go-to-market Expertise to Help You Win
知っておきたい 7の賢いGoogle検索Tips 管理人 @ 7月 27日 07:43am 検索Tips Google検索を賢く利用すると、様々な情報を簡単に抽出することができます。 顔写真、ウェブカメラ、匿名プロキシ、音楽ファイル、無料素材などなど、知らないと損するGoogle検索Tipsを7つ紹介します。 世界中のウェブカメラにアクセス Google検索を利用して世界中のウェブカメラにアクセスすることができます。 次の検索構文を入力するだけです。 Axis Webcams: inurl:/view.shtml inurl:view/index.shtml inurl:view/indexFrame.shtml inurl:axis-cgi/jpg inurl:axis-cgi/mjpg Cannon Webcams: sample/LvAppl/ MOBOTIX Webcams: co
リリース、障害情報などのサービスのお知らせ
最新の人気エントリーの配信
処理を実行中です
j次のブックマーク
k前のブックマーク
lあとで読む
eコメント一覧を開く
oページを開く