If you are running Apache for your web server, and mod_rewrite is installed (this is a pretty typicaly module on all installations) this is actually pretty easy. RewriteEngine on RewriteCond %{HTTP_HOST}
The AskApache blog has a great comprehensive guide to .htaccess. A must read for anyone who does a lot of work with Apache. http://www.askapache.com/htaccess/apache-htaccess.html
If you upload those new fancy-shmancy file formats to your web server – namely .docx, .pptx and .xlsx – and you are running Apache; chances are that your web server doesn’t
The goal here is to watermark all images in a certain directory, except for thumbnails or other selection. You can either do this on each file prior to placing on your webserver –