The following code is used to prevent HotLinking to jpg, jpeg, gif, png, and bmp file types.
RewriteEngine on RewriteCond %{HTTP_REFERER} !^$ RewriteCond %{HTTP_REFERER} !^http://(www.)?my-website.com/.*$ [NC] RewriteRule .(jpg|jpeg|gif|png|bmp)$ - [F]