reCaptcha, a plugin for Movable Type
- Authors: Six Apart
- Copyright: 2009 Six Apart Ltd.
- License: MIT
- Site: http://www.movabletype.org/
Overview
Captcha plugin powered by reCaptcha: https://developers.google.com/recaptcha/.
Requirements
- MT 4.x
Features
- Provides captcha powered by reCaptcha v2.
Documentation
http://www.tildemark.com/adding-captcha-to-comments-in-movable-type-4/
- Register for an account on reCaptcha and follow the links to "add a new site" to get the "reCaptcha public key" and "reCaptcha private key".
- Install the reCaptcha plugin.
- Go the Blog menu Tools > Plugins and open the settings for the reCaptcha plugin.
- Enter the keys into the respective public and private fields and click "Save Changes".
- Go to Blog menu Preferences > Comment.
- Select "reCaptcha" as the value for "CAPTCHA Provider" and click "Save Changes".
- Edit the template containing the commenting form. In the default templates this is th "Comment Form" template.
Look for one of the following blocks of code (from default templates in MT4.0x and MT4.1x):
<mt:If tag="MTCaptchaFields">
<mt:IfCommentsAccepted><mt:IfRegistrationAllowed><mt:Else><$mt:CaptchaFields$></mt:IfRegistrationAllowed></mt:IfCommentsAccepted>
<div id="comments-open-captcha">
</div>
</mt:If>
...or this code (from default templates in MT4.2x+):
<div id="comments-open-captcha"></div>
Replace this with this code:
<mt:If tag="MTCaptchaFields">
<div id="comments-open-captcha"><$mt:CaptchaFields$></div>
</mt:If>
Note: The
mt:If
tag will remove the catcha if the "CAPTCHA Provider" setting is changed to "none" in Movable Type.
Open the Javascript index template and remove the following code or place it in a mt:Ignore
block. (This code was in the default templates in MT4.0x and MT4.1x):
<mt:If tag="MTCaptchaFields">
captcha_timer = setInterval('delayShowCaptcha()', 1000);
</mt:If>
...or remove/comment out mtShowCaptcha() call in mtCommentFormOnFocus function
function mtCommentFormOnFocus() {
// if CAPTCHA is enabled, this causes the captcha image to be
// displayed if it hasn't been already.
mtShowCaptcha(); <---- this
}
- Rebuild index and individual entry archives.
Installation
- Move the
reCaptcha
plugin directory to the MTplugins
directory.
Should look like this when installed:
$MT_HOME/
plugins/
reCaptcha/
Troubleshooting
Add the following MT config directive to write validation requests and responses to the Activity log:
ReCaptchaDebug 1
Support
This plugin is not an official Six Apart release, and as such support for this plugin is not available.