This thread should help you to use the captcha function from 4images version 1.7.3 also in [MOD] guestbook ->
http://www.4homepages.de/forum/index.php?topic=7409.0Features:
+ switch the captcha function on / off
+ use the words.txt to define your own words
+ create your own backgrounds like in the new version 1.7.3
Note: You need 4images version 1.7.3 to run this modificationFiles which you have to modifi:
- guestbook.php
- guestbook_form.html
- config.php
1. open guestbook.php and find:
// Flood Check
add
above://-----------------captcha function from 4images 1.7.3 ----------------------------
$captcha = (isset($HTTP_POST_VARS['captcha'])) ? un_htmlspecialchars(trim($HTTP_POST_VARS['captcha'])) : "";
//-----------------captcha function from 4images 1.7.3 ----------------------------
find:
if (!$error) {
if ($comment_site =="http://") {
$comment_site = "";
add
above://-----------------captcha function from 4images 1.7.3 ----------------------------
if ($captcha_enable_guestbook && !captcha_validate($captcha)) {
$msg .= (($msg != "") ? "<br />" : "").$lang['captcha_required'];
$error = 1;
}
//-----------------captcha function from 4images 1.7.3 ----------------------------
find:
"lang_comment" => $lang['comment']
(
without >
, < behind)
replace with:
"lang_comment" => $lang['comment'],
"lang_captcha" => $lang['captcha'],
"lang_captcha_desc" => $lang['captcha_desc'],
"captcha_guestbook" => (bool)$captcha_enable_guestbook
2. open guestbook_form.html
find:
<td>{bbcode}</td>
</tr>
add
after:{if captcha_guestbook}
<tr>
<td width="90" valign="top"><b>{lang_captcha}</b></td>
<td>
<a href="javascript:new_captcha_image();"><img src="{url_captcha_image}" border="0" id="captcha_image" /></a>
<br />
<input type="text" name="captcha" size="30" value="" class="commentinput" id="captcha_input" />
<br />
{lang_captcha_desc}
</td>
</tr>
{endif captcha_guestbook}
3. open config.php
find:
define("4IMAGES_ACTIVE", 1);
add
after:$captcha_enable_guestbook = 1;
IŽll hope youŽve got it! Ciao by Flo