UseBB Community

UseBB support, discussion and development

CAPCHA 1.0.9

Moderators: Gaia.

Post Reply

Page: 1

Author Post
Member
Registered: Oct 2008
Posts: 43
Location: United Kingdom
I needed a simple capch for my forum, found one on the internet and thort i would share with you :D

i found this at http://www.phpcaptcha.org all i have done is intergrate it into usebb :D

FILE CHANGES

open your_template_folder/various.tpl.php

find
<tr>
<td class="fieldtitle">{l_PasswordAgain}</td><td>{passwd2_input}</td>
</tr>

add after
<tr>
<td class="fieldtitle">CAPCHA</td><td>{capcha}</td>
</tr>


open sources/panel_register.php
find
'passwd2_input'       => '<input type="password" name="passwd2" size="25" maxlength="255" />',

add after
'capcha'       => '<input type="text" name="code" size="25" maxlength="255" /> <img src="sources/capcha/securimage_show.php" />'',


FILE UPLOADS

Then upload this file to your sources folder


http://rapidshare.com/files/295450537/capcha.zip.html

if you haveny problms pm me :D
Member
Registered: Oct 2008
Posts: 43
Location: United Kingdom
screen shot
User posted image
Member
Registered: Oct 2008
Posts: 43
Location: United Kingdom
woops i forgot to add this :P :S

OPEN sources/panel_register.php
FIND

			if ( empty($_POST['passwd1']) || empty($_POST['passwd2']) || !preg_match(PWD_PREG, $_POST['passwd1']) || $_POST['passwd1'] != $_POST['passwd2'] )
$errors[] = $lang['Password'];

Add after
//capcha verification		
require_once 'sources/capcha/securimage.php';

$image = new Securimage();
if ($image->check($_POST['code']) == true) {
} else {
$template->parse('msgbox', 'global', array(
'box_title' => $lang['Error'],
'content' => 'capcha was wrong!')
);
}

Post Reply

Page: 1

UseBB Community is powered by UseBB 1 Forum Software