Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-01-25 10:18:08

Sencer
Developer emeritus
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

asy_captcha (Anti-Spam), Txp 4.0.3 and up

Name: asy_captcha
Description: CAPTCHA – Image verification for Comments
Version: 1.0

Requirements: Textpattern 4.0.3 and up; zlib (is by default in the core of PHP)

<hr />

Download: http://www.sencer.de/code/txp/asy_captcha.txt

<hr />

What’s a CAPTCHA? What does the plugin do?

Take a look at this CAPTCHA-explanation.
The plugin will show an image with some characters in it, and an input-box. When the user enters the captcha-code correctly, the comment is saved as visible, meaning it appears live right away. If, after the third try the verification code is still wrong, the comment is sent into the moderation queue and has to be manually validated.

How do I use this plugin?

Simply turn it on. :) If you are not happy with the text, styling etc., you can completely customize it. Use these tags to output what you need:
<txp:asy_captcha_image class="" />
<txp:asy_captcha_input class="" size="" tab="" />
You should also wrap the whole block related to the captcha into <txp:if_comments_preview>, because the tags will not output anything if it’s not a preview.

How do I configure the plugin?

There’s not much of a configuration available for now. If you understand a little bit of PHP, you can open the plugin to edit, and play with these values in function asy_captcha_conf():

$asy_captcha_conf['max_try'] = 3;
$asy_captcha_conf['max_try_action'] = MODERATE; //or SPAM
$asy_captcha_conf['length'] = 5;
$asy_captcha_conf['difficulty'] = 1; //valid: 0,1,2
<hr />

P.S.: This is the exact same plugin that was mentioned in the release notes for 4.0.3, but somehow I forgot to open a topic for it here. Ooops.
Please report if you trouble installing and using the plugin. Thanks.

Offline

#2 2006-01-26 20:20:39

roelof
Member
Registered: 2005-03-27
Posts: 647

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Hello,

I have only one question.
Can this plugin work together with the zem-contact Plugin.
If so, how can i do this.

Roelof

Offline

#3 2006-01-26 20:42:51

Sencer
Developer emeritus
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

No, it can’t. Someone with PHP knowledge would have to code that.

Offline

#4 2006-02-28 21:40:06

bartekk
Member
Registered: 2004-11-09
Posts: 57

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

I can’t install this plugin.

I get folowing error:

Notice: unserialize(): Error at offset 0 of 12651 bytes in /home/www/textpattern/include/txp_plugin.php on line 152

what is wrong?

Offline

#5 2006-03-01 09:14:05

Sencer
Developer emeritus
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Do you meet ll the requirements, like e.g. the most recent Textpattern version (4.0.3)?

Offline

#6 2006-03-01 09:24:42

bartekk
Member
Registered: 2004-11-09
Posts: 57

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Oh, I see. I thought i have 4.0.3 installed but it is 4.0.2. Sorry for that.
I will update txp and try again.

Thanks

Offline

#7 2006-03-19 10:38:22

thebombsite
Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Can the background be changed or the text contrast?


Stuart – The BombsiteProText ThemesTextgarden

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#8 2006-03-19 11:16:21

Sencer
Developer emeritus
From: cgn, de
Registered: 2004-03-23
Posts: 1,803
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

The image is constructed/generated bit by bit, so unless you want to study the png-spec and write code, your only options are $asy_captcha_conf['difficulty'] = 1; //valid: 0,1,2 as mentioned above. (difficulty 0 enhances the contrast somewhat, difficlty 2 distorts the characters more)

The main objective was to have a plugin that works across as many servers as possible. There are prettier captcha’s posible, if GD library and Truetype fonts are available. Since all the image stuff is encapsulated in a class with a simple interface, other plugin authors should be able to adapt the plugin to do that.

Offline

#9 2006-03-19 11:42:22

thebombsite
Plugin Author
From: Exmouth, England
Registered: 2004-08-24
Posts: 3,251
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Have you any idea how much of that I understood Sencer? ;)

I’ll modify the “difficulty” then and see what I get. Thanks.


Stuart – The BombsiteProText ThemesTextgarden

In a Time of Universal Deceit
Telling the Truth is Revolutionary.

Offline

#10 2006-03-24 16:42:03

jtlapp
Member
From: Austin, TX
Registered: 2006-03-19
Posts: 59
Website

Re: asy_captcha (Anti-Spam), Txp 4.0.3 and up

Thank you Sencer. I would not be using TXP without this plugin. I’ve no interest in learning the GD APIs or in finding an appropriate character distortion.

I’d like one tweak though: I prefer not asking users to enter the code in uppercase. How do I generate the encoded png data for the lowercase letters? I know you say how they are encoded, but I was hoping for a tool or procedure that does the trick. Thanks!

~joe

Offline

Board footer

Powered by FluxBB