<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>BasilSunshine.com &#187; PHP</title>
	<atom:link href="http://basilsunshine.com/tag/php/feed/" rel="self" type="application/rss+xml" />
	<link>http://basilsunshine.com</link>
	<description>Good coffee, great spew.</description>
	<lastBuildDate>Fri, 11 Dec 2009 21:01:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Creating Anti-Spam Bot Verifications for Web Forms</title>
		<link>http://basilsunshine.com/2009/04/26/creating-anti-spam-bot-verifications-for-web-forms/</link>
		<comments>http://basilsunshine.com/2009/04/26/creating-anti-spam-bot-verifications-for-web-forms/#comments</comments>
		<pubDate>Sun, 26 Apr 2009 13:30:46 +0000</pubDate>
		<dc:creator>bazz</dc:creator>
				<category><![CDATA[Webmaster Tips]]></category>
		<category><![CDATA[anti-spam]]></category>
		<category><![CDATA[captcha]]></category>
		<category><![CDATA[CAPTCHA images]]></category>
		<category><![CDATA[human verification]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[ReCAPTCHA]]></category>
		<category><![CDATA[spam bots]]></category>
		<category><![CDATA[verification]]></category>
		<category><![CDATA[verification form]]></category>
		<category><![CDATA[verification image]]></category>
		<category><![CDATA[web forms]]></category>

		<guid isPermaLink="false">http://basilsunshine.com/?p=154</guid>
		<description><![CDATA[I have been recently asked how to create one of these web form verifications things (CAPTCHA images) which will confirm that a real human is sending your form, rather than a bot sending you ads for Viagra and other happy pills.]]></description>
			<content:encoded><![CDATA[<p><img class="alignright size-full wp-image-155" title="spam" src="http://basilsunshine.com/wp-content/uploads/2009/04/spam.jpg" alt="spam" width="300" height="343" />I have been recently asked how to create one of these web form verifications things (particularly, featuring CAPTCHA images) which will confirm that a real human is submitting your form, rather than a bot sending you ads for Viagra and other happy pills. I can tell you firsthand that some sort of verification is necessary, as I recently posted a form without one and indeed, my inbox runneth over.</p>
<p>There are a few ways to create one of these verifications. The most common way is to install a PHP script on your server which creates a CAPTCHA image. Google has released such a script under a GNU General Public License, which you can <a href="http://code.google.com/p/anti-spam-verification-image/" target="_blank">download here</a>. Another way is to use a third party service such as <a href="http://recaptcha.net/whyrecaptcha.html" target="_blank">ReCAPTCHA</a>, which is a little simpler to implement. ReCAPTCHA also makes a <a href="http://recaptcha.net/plugins/wordpress/" target="_blank">cool Wordpress plugin</a> which protects your comment form. It also has the ability to hide your email address until a CAPTCHA image is solved, which may be an alternative to using a web form in some cases. (As an aside, it is really interesting to note that every time someone solves a ReCAPTCHA, it is helping a computer somewhere over at Carnegie Mellon University learn to digitize books better&#8230; How space age is that?)</p>
<p>However, even this can be complicated for those who are not technically inclined or for those of us who are technically inclined but too lazy to bother. Some of us would prefer not to rely on a third party solution if possible. Another group are those humans who hate those damn things because they are often incomprehensible, cause eye strain, or in some strange happenstance of the Universe, seem to curse at you (see <a href="http://basilsunshine.com/2009/04/01/fail-blog-contribution/">this post</a> and <a href="http://basilsunshine.com/2009/04/21/fail-blog-part-ii/">this post</a>).</p>
<p><a href="http://www.amazon.com/gp/product/B00095NPYY?ie=UTF8&amp;tag=basilsunshine-com-20&amp;linkCode=as2&amp;camp=1789&amp;creative=390957&amp;creativeASIN=B00095NPYY"><img class="alignleft size-full wp-image-169" title="webmastersign" src="http://basilsunshine.com/wp-content/uploads/2009/04/webmastersign.jpg" alt="webmastersign" width="105" height="160" /></a>As an alternative, I have seen a few web forms using a simple mathematical problem, which presumably only a human can calculate. Usually it is something like &#8220;1+1 = ?&#8221; and the user has to input the proper value in order to send the form. I like to take this a step further and make it a word problem, preferably related to the content of the site,  if possible. If it is slightly amusing and causes a little head-scratching, even better. For example, take a look at my <a href="http://basilsunshine.com/contact">contact page</a>. The disadvantage is that word problems could be confusing for those who don&#8217;t speak English well (or those with a serious math disability) so I have made my form so that it will accept any value as long as something is entered. If I wanted to take it a step further, I could filter my email so that only emails with the correct value get through, or force the right value to be entered on the form in the first place. Spammers may eventually figure this out, so I may have to change the problems occasionally and force the right value in the future. But I am banking on my estimation that most spammers are too lazy to bother, when there are so many juicy unprotected forms out there for the pickings.</p>
<p class="buymebeer"><form action="https://www.paypal.com/cgi-bin/webscr" target="paypal" method="post"><input type="hidden" name="cmd" value="_xclick" /><input type="hidden" name="business" value="bazz@basilsunshine.com" /><input type="hidden" name="return" value="" /><input type="hidden" name="item_name" value="Buy Me a Beer for Creating Anti-Spam Bot Verifications for Web Forms" /><input type="hidden" name="currency_code" value="USD" /><input type="hidden" name="amount" value="" /><input type="image" src="http://basilsunshine.com/wp-content/plugins/buy-me-beer/icon_cafe.gif" align="left" alt="" title="" hspace="3" /></form><a href="https://www.paypal.com/cgi-bin/webscr?cmd=_xclick&amp;business=bazz@basilsunshine.com&amp;currency_code=USD&amp;amount=&amp;return=&amp;item_name=Buy+Me+a+Beer+for+Creating+Anti-Spam+Bot+Verifications+for+Web+Forms" target="paypal">Like the post? Click here to buy me a decaf cappuccino!</a></p><hr /><small>Copyright &copy; 2009 Silver Hare LLC<br /> This feed is for personal, non-commercial use only. <br /> The use of this feed on other websites breaches copyright. If this content is not in your news reader, it makes the page you are viewing an infringement of the copyright. (Digital Fingerprint:<br /> 15464b5462222222045646b44 (38.107.191.106) )</small><a class="a2a_dd addtoany_share_save" href="http://www.addtoany.com/share_save?&amp;linkurl=http%3A%2F%2Fbasilsunshine.com%2F2009%2F04%2F26%2Fcreating-anti-spam-bot-verifications-for-web-forms%2F&amp;linkname=Creating%20Anti-Spam%20Bot%20Verifications%20for%20Web%20Forms"><img src="http://basilsunshine.com/wp-content/plugins/add-to-any/share_save_120_16.png" width="120" height="16" alt="Share/Save/Bookmark"/></a>]]></content:encoded>
			<wfw:commentRss>http://basilsunshine.com/2009/04/26/creating-anti-spam-bot-verifications-for-web-forms/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
