Blogtrottr
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 發問中
Yahoo!奇摩知識+ - 分類問答 - 電腦網路 - 發問中
寫綱頁時,怎樣做,才不能右CLICK被儲存圖片?
Jun 27th 2013, 03:37


有至少三個方法

1. 使用Flash介面:圖片可以嵌入Flash檔案中,此時右鍵只能設定Flash的運行或控制播放影格與大小(可以自行禁止)

缺點:需要開啟Flash觀看圖片(在iOS不行)、Flash檔案需要容納所有圖片,大小增加

2. 使用JavaScript,以防止使用者按右鍵打開選單,然後另存圖片

若用此法,使用者仍可以運用Print Screen或把網頁另存新檔(包括當中圖片),來儲存所需圖片

3. 寫出伺服器代碼,以便伺服器拒絕使用者下載圖片的要求

Flash:
Flash介面可以把部分圖片內容放置到空間外,強迫瀏覽者拖曳圖片來觀看全圖,以免被Print Screen
Flash檔案的大小增加,就不利瀏覽者下載整個檔案(尤其是3G用戶),觀看有關圖片更費時

JavaScript:
如果使用JavaScript防止使用者按右鍵打開選單,則使用者可以關閉JavaScript解除此限制

但無論使用哪種方法,瀏覽者都可以從暫存資料夾中下載所需檔案。因此只有不公開到互聯網方可完全防止他人儲存圖片!

所需網頁代碼可參考
http://tw.knowledge.yahoo.com/question/question?qid=1511071700151

參考資料: http://tw.knowledge.yahoo.com/question/question?qid=1511071700151

This entry passed through the Full-Text RSS service — if this is your content and you're reading it on someone else's site, please read the FAQ at fivefilters.org/content-only/faq.php#publishers. Five Filters recommends: 'You Say What You Like, Because They Like What You Say' - http://www.medialens.org/index.php/alerts/alert-archive/alerts-2013/731-you-say-what-you-like-because-they-like-what-you-say.html

You are receiving this email because you subscribed to this feed at blogtrottr.com.

If you no longer wish to receive these emails, you can unsubscribe from this feed, or manage all your subscriptions
arrow
arrow
    全站熱搜
    創作者介紹
    創作者 sdfgdf2 的頭像
    sdfgdf2

    中文名字日文翻譯, 中文翻譯日文名字, 名字日文翻譯, 日文翻譯名字, 日文翻譯字典發音, 日文翻譯網 漢字,

    sdfgdf2 發表在 痞客邦 留言(0) 人氣()