css - how to disable dragging of an html element (especially "img")? -
i have image don't want drag-able or selectable no drag other places on page. how done?
it impossible prevent store image (or other resources) on computer others have mentioned.
but trick make harder (impossible inexperienced people guess) use css , background images:
<div style='background: url("myimage.gif");'></div>
the image on background of <div>
block , cannot dragged or right clicked in order save it.
using coding knowledge possible ind out myimage.gif
part, can added after base url in order download image , save it. example if html page @ http://www.example.com/mypage.html image found @ http://www.example.com/myimage.gif
as mentioned still possible save image, inexperienced people lot harder.
note: in example image put in html tag, proper use of css file, harder find inexperienced people.
Comments
Post a Comment