Hi, When I did a "site:mysite.com" check on Google today, I noticed that it also indexed the image directory (mysite.com/images/). I don't want Google or other crawlers index it like this that's why I put a robots.txt file such as the following: User-agent: * Disallow: /images/ Will this prevent my images appearing on image search results (as single files)?
Yes, that should do it. However you should note that some webmaster are trying to do SEO for images as well . It's just another source of SE traffic.
Well, I want my images appear on image search results but as you see on this search: http://www.google.com/search?q=site:configureweb.com, my image directory (www.configureweb.com/img/posts/) is also indexed and I don't want this. How can I prevent that?
User-agent: * Disallow: /img/ Disallow: /images/ Will forbid all robots.txt obeying search engine crawlers from your images in /img/ and /images/.
User-agent: * Disallow: /img/ Disallow: /images/ will good you can easily ristrict your image folder.
In theory you can block a part or whole website by roots.txt. But as a matter of fact Robots file is just a set of directives for the robots not to index certain files, while it is to be remembered that robots may not follow your directive. If you do not wish your image folder to be crawled you can password protect it.