Wierd Facebook bot behavior, and how I got rid of useless 404 requests

For some reason Facebook bot, you know.. the one that officially doesn't exist and its purpose is unknown, is still requesting images that for months now have been deleted. These images where created on the fly just to post them on somebody's wall, but who cares after so many months? These images are deleted, but this bot cannot understand that after numerous 404 responses. Watchdog is crucial for serious other purposes, and I wanted to avoid useless 404 logs. So, what I made was that I created an .htaccess file within the directory that these files existed with the following code:

<IfModule mod_rewrite.c>

  RewriteEngine on

  

  RewriteCond %{REQUEST_FILENAME} !-f

  RewriteRule ^ ../not-found-placeholder.jpg [L]

</IfModule>

 

So, what this htaccess does? For files that could not be found within current directory or any of its subdirectories, a different file is served. The image "not-found-placeholder.jpg" is served which lives in the parent directory.
 
 

Linked In Profile