[BETA] Antispam for all fields (updated: 10-01-2009:V1.3.1)

A place for MOD Authors to post and receive feedback on MODs still in development. No MODs within this forum should be used within a live environment! No new topics are allowed in this forum.
Forum rules
READ: phpBB.com Board-Wide Rules and Regulations

IMPORTANT: MOD Development Forum rules

On February 1, 2009 this forum will be set to read only as part of retiring of phpBB2.
User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Wed Jun 28, 2006 4:59 am

:!: Fix for 1.1.3 till 1.1.4 comes out ( within 48 hours )

edit:

1.1.4 released
Upgrade instructions are in the 1.1.4 zipfile
Last edited by Ramon Fincken on Wed Jun 28, 2006 2:41 pm, edited 1 time in total.
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Wed Jun 28, 2006 2:39 pm

:!: ** upgrade 1.1.3 -> 1.1.4 28032006
* Added a function for group check. Was left out in V 1.1.3
Upgrade instructions are in the 1.1.4 zipfile
Thanks to Stephen W. Thomas for posting the error!
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
Nigelman
Registered User
Posts: 210
Joined: Sun Jun 12, 2005 3:59 pm
Contact:

I'm getting a parse error

Post by Nigelman » Sun Jul 02, 2006 3:54 pm

I know I did this right.......am getting this error in my admin section on the left.

Parse error: syntax error, unexpected T_IF in /home/fukuokaf/public_html/fishingjapan/admin/admin_users.php on line 1135

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Sun Jul 02, 2006 3:58 pm

here's line

1016 till
1129 from a pre-modded admin_users.php 2.0.21 file

please compare it with yours, this is a working one..

Code: Select all

		$template->assign_vars(array(
			'USERNAME' => $username,
			'EMAIL' => $email,
			'YIM' => $yim,
			'ICQ' => $icq,
			'MSN' => $msn,
			'AIM' => $aim,
			'OCCUPATION' => $occupation,
			'INTERESTS' => $interests,
			'LOCATION' => $location,
			'WEBSITE' => $website,
			'SIGNATURE' => str_replace('<br />', "\n", $signature),
			'VIEW_EMAIL_YES' => ($viewemail) ? 'checked="checked"' : '',
			'VIEW_EMAIL_NO' => (!$viewemail) ? 'checked="checked"' : '',
			'HIDE_USER_YES' => (!$allowviewonline) ? 'checked="checked"' : '',
			'HIDE_USER_NO' => ($allowviewonline) ? 'checked="checked"' : '',
			'NOTIFY_PM_YES' => ($notifypm) ? 'checked="checked"' : '',
			'NOTIFY_PM_NO' => (!$notifypm) ? 'checked="checked"' : '',
			'POPUP_PM_YES' => ($popuppm) ? 'checked="checked"' : '',
			'POPUP_PM_NO' => (!$popuppm) ? 'checked="checked"' : '',
			'ALWAYS_ADD_SIGNATURE_YES' => ($attachsig) ? 'checked="checked"' : '',
			'ALWAYS_ADD_SIGNATURE_NO' => (!$attachsig) ? 'checked="checked"' : '',
			'NOTIFY_REPLY_YES' => ( $notifyreply ) ? 'checked="checked"' : '',
			'NOTIFY_REPLY_NO' => ( !$notifyreply ) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_BBCODE_YES' => ($allowbbcode) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_BBCODE_NO' => (!$allowbbcode) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_HTML_YES' => ($allowhtml) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_HTML_NO' => (!$allowhtml) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_SMILIES_YES' => ($allowsmilies) ? 'checked="checked"' : '',
			'ALWAYS_ALLOW_SMILIES_NO' => (!$allowsmilies) ? 'checked="checked"' : '',
			'AVATAR' => $avatar,
			'LANGUAGE_SELECT' => language_select($user_lang),
			'TIMEZONE_SELECT' => tz_select($user_timezone),
			'STYLE_SELECT' => style_select($user_style, 'style'),
			'DATE_FORMAT' => $user_dateformat,
			'ALLOW_PM_YES' => ($user_allowpm) ? 'checked="checked"' : '',
			'ALLOW_PM_NO' => (!$user_allowpm) ? 'checked="checked"' : '',
			'ALLOW_AVATAR_YES' => ($user_allowavatar) ? 'checked="checked"' : '',
			'ALLOW_AVATAR_NO' => (!$user_allowavatar) ? 'checked="checked"' : '',
			'USER_ACTIVE_YES' => ($user_status) ? 'checked="checked"' : '',
			'USER_ACTIVE_NO' => (!$user_status) ? 'checked="checked"' : '', 
			'RANK_SELECT_BOX' => $rank_select_box,

			'L_USERNAME' => $lang['Username'],
			'L_USER_TITLE' => $lang['User_admin'],
			'L_USER_EXPLAIN' => $lang['User_admin_explain'],
			'L_NEW_PASSWORD' => $lang['New_password'], 
			'L_PASSWORD_IF_CHANGED' => $lang['password_if_changed'],
			'L_CONFIRM_PASSWORD' => $lang['Confirm_password'],
			'L_PASSWORD_CONFIRM_IF_CHANGED' => $lang['password_confirm_if_changed'],
			'L_SUBMIT' => $lang['Submit'],
			'L_RESET' => $lang['Reset'],
			'L_ICQ_NUMBER' => $lang['ICQ'],
			'L_MESSENGER' => $lang['MSNM'],
			'L_YAHOO' => $lang['YIM'],
			'L_WEBSITE' => $lang['Website'],
			'L_AIM' => $lang['AIM'],
			'L_LOCATION' => $lang['Location'],
			'L_OCCUPATION' => $lang['Occupation'],
			'L_BOARD_LANGUAGE' => $lang['Board_lang'],
			'L_BOARD_STYLE' => $lang['Board_style'],
			'L_TIMEZONE' => $lang['Timezone'],
			'L_DATE_FORMAT' => $lang['Date_format'],
			'L_DATE_FORMAT_EXPLAIN' => $lang['Date_format_explain'],
			'L_YES' => $lang['Yes'],
			'L_NO' => $lang['No'],
			'L_INTERESTS' => $lang['Interests'],
			'L_ALWAYS_ALLOW_SMILIES' => $lang['Always_smile'],
			'L_ALWAYS_ALLOW_BBCODE' => $lang['Always_bbcode'],
			'L_ALWAYS_ALLOW_HTML' => $lang['Always_html'],
			'L_HIDE_USER' => $lang['Hide_user'],
			'L_ALWAYS_ADD_SIGNATURE' => $lang['Always_add_sig'],
			
			'L_SPECIAL' => $lang['User_special'],
			'L_SPECIAL_EXPLAIN' => $lang['User_special_explain'],
			'L_USER_ACTIVE' => $lang['User_status'],
			'L_ALLOW_PM' => $lang['User_allowpm'],
			'L_ALLOW_AVATAR' => $lang['User_allowavatar'],
			
			'L_AVATAR_PANEL' => $lang['Avatar_panel'],
			'L_AVATAR_EXPLAIN' => $lang['Admin_avatar_explain'],
			'L_DELETE_AVATAR' => $lang['Delete_Image'],
			'L_CURRENT_IMAGE' => $lang['Current_Image'],
			'L_UPLOAD_AVATAR_FILE' => $lang['Upload_Avatar_file'],
			'L_UPLOAD_AVATAR_URL' => $lang['Upload_Avatar_URL'],
			'L_AVATAR_GALLERY' => $lang['Select_from_gallery'],
			'L_SHOW_GALLERY' => $lang['View_avatar_gallery'],
			'L_LINK_REMOTE_AVATAR' => $lang['Link_remote_Avatar'],

			'L_SIGNATURE' => $lang['Signature'],
			'L_SIGNATURE_EXPLAIN' => sprintf($lang['Signature_explain'], $board_config['max_sig_chars'] ),
			'L_NOTIFY_ON_PRIVMSG' => $lang['Notify_on_privmsg'],
			'L_NOTIFY_ON_REPLY' => $lang['Always_notify'],
			'L_POPUP_ON_PRIVMSG' => $lang['Popup_on_privmsg'],
			'L_PREFERENCES' => $lang['Preferences'],
			'L_PUBLIC_VIEW_EMAIL' => $lang['Public_view_email'],
			'L_ITEMS_REQUIRED' => $lang['Items_required'],
			'L_REGISTRATION_INFO' => $lang['Registration_info'],
			'L_PROFILE_INFO' => $lang['Profile_info'],
			'L_PROFILE_INFO_NOTICE' => $lang['Profile_info_warn'],
			'L_EMAIL_ADDRESS' => $lang['Email_address'],
			'S_FORM_ENCTYPE' => $form_enctype,

			'HTML_STATUS' => $html_status,
			'BBCODE_STATUS' => sprintf($bbcode_status, '<a href="../' . append_sid("faq.$phpEx?mode=bbcode") . '" target="_phpbbcode">', '</a>'), 
			'SMILIES_STATUS' => $smilies_status,

			'L_DELETE_USER' => $lang['User_delete'],
			'L_DELETE_USER_EXPLAIN' => $lang['User_delete_explain'],
			'L_SELECT_RANK' => $lang['Rank_title'],

			'S_HIDDEN_FIELDS' => $s_hidden_fields,
			'S_PROFILE_ACTION' => append_sid("admin_users.$phpEx")."&UUL=".$userdata['user_level'])
		);
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

Phono Paul
Registered User
Posts: 4
Joined: Tue Jul 04, 2006 6:42 am

Post by Phono Paul » Tue Jul 04, 2006 6:49 am

Hi, probably a foolish question, but even if a user is in the "approved user" group and bypasses the antispam checker, their post still gets censored by the the word list, ie "Poker" is replaced with "MAPS" (or "beep" etc).

I guess I can get around this by copying the banned word into the replace field in the word list, but is there a cleaner solution? Have I missed something obvious?!

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Tue Jul 04, 2006 7:17 am

Phono Paul wrote: Hi, probably a foolish question, but even if a user is in the "approved user" group and bypasses the antispam checker, their post still gets censored by the the word list, ie "Poker" is replaced with "MAPS" (or "beep" etc).

I guess I can get around this by copying the banned word into the replace field in the word list, but is there a cleaner solution? Have I missed something obvious?!


Hello Paul,

that's absolutely true.

However if you make your list for really nasty words there's nothing to worry about.
But I think in a future release I'll use a seperate wordlist so this won't happen. ( I will provide a 2 second automatically script to copy all the words into the new databasetable ).

Ramon
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

Phono Paul
Registered User
Posts: 4
Joined: Tue Jul 04, 2006 6:42 am

Post by Phono Paul » Tue Jul 04, 2006 10:30 am

Thanks for your reply, and you beat me to it because that's exactly what I've done! I created an identical table to phpbb_words called phpbb_spamwords and populated it from the banned words list.

The mod works beautifully, by the way (so cheers!), but within a day of implemented it someone decided to mention casinos in a legitimate context! So yes, great mod but I think a separate spam table is in order.

User avatar
AleSSaNDRo
Registered User
Posts: 118
Joined: Thu Mar 18, 2004 5:05 pm
Location: Milano
Contact:

Post by AleSSaNDRo » Tue Jul 04, 2006 11:27 am

in admin_users.php after insert nickname to edit:

Code: Select all

Warning: validate_spam(includes/functions_antispam_config.php): failed to open stream: No such file or directory in /usr/public_html//forum/includes/functions_antispam.php on line 20

Warning: validate_spam(): Failed opening 'includes/functions_antispam_config.php' for inclusion (include_path='.:/usr/local/lib/php') in /usr/public_html/forum/includes/functions_antispam.php on line 20
WebMaster of MondoWeb.net - Crea il tuo forum gratis (free hosting forum)
I'm italian! :) Sorry for my bad english :oops:

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Wed Jul 05, 2006 8:34 am

@Paul: thanks for the input !!

@AleSSaNDRo: when does this happen?
Is the mod working allright on the board itself like Pauls installation ( You got the very same install instructions/files )

Rfn
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
AleSSaNDRo
Registered User
Posts: 118
Joined: Thu Mar 18, 2004 5:05 pm
Location: Milano
Contact:

Post by AleSSaNDRo » Wed Jul 05, 2006 8:39 am

I have do all instructions of antispam_1.1.4.txt and there is that problem after i go in Administration, "Manage", insert one nickname and click to "submit".

Those errors appears up details of nickname.




EDIT: I have resolved with correction to
function validate_spam($txt)
{
global $db,$userdata,$HTTP_GET_VARS,$phpEx;

// 1.1.3
// Grab settings
include('PATH/includes/functions_antispam_config.'.$phpEx);
WebMaster of MondoWeb.net - Crea il tuo forum gratis (free hosting forum)
I'm italian! :) Sorry for my bad english :oops:

Phono Paul
Registered User
Posts: 4
Joined: Tue Jul 04, 2006 6:42 am

Post by Phono Paul » Thu Jul 06, 2006 2:51 pm

In the interest of "helping" further, I am getting error messages when I do various admin functions, specifically changing a user's permissions (although I think there may be others).

Example:

Code: Select all

Warning: validate_spam(includes/functions_antispam_config.php): failed to open stream: No such file or directory in [etc...]/includes/functions_antispam.php on line 20

Warning: validate_spam(includes/functions_antispam_config.php): failed to open stream: No such file or directory in [etc...]/includes/functions_antispam.php on line 20

Warning: validate_spam(includes/functions_antispam_config.php): failed to open stream: No such file or directory in [etc...]/includes/functions_antispam.php on line 20

Warning: validate_spam(): Failed opening 'includes/functions_antispam_config.php' for inclusion (include_path='.:/usr/lib/php:/usr/local/lib/php') in [etc...]/includes/functions_antispam.php on line 20

Warning: Cannot modify header information - headers already sent by (output started at [etc...]/includes/functions_antispam.php:20) in [etc...]/admin/page_header_admin.php on line 143

Warning: Cannot modify header information - headers already sent by (output started at [etc...]/includes/functions_antispam.php:20) in [etc...]/admin/page_header_admin.php on line 145

Warning: Cannot modify header information - headers already sent by (output started at [etc...]/includes/functions_antispam.php:20) in [etc...]/admin/page_header_admin.php on line 146
Note that everything still works okay (so I'm not unduly concerned! The benefits of this far outweigh some ugliness in admin) and this may be a result of my tinkering elsewhere, but thought it worth mentioning nevertheless.

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Thu Jul 06, 2006 2:58 pm

Thanks guys! Both of you!!

well... thats why this mod is 'still beta' however it works correctly...

Is all changed info still saved when you see this error in the admin panel?

AleSSaNDRo, could you provide me the info you exactly entered by PM ?
Were all your admin problems solved thereafter?

Ramon
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Sun Jul 09, 2006 1:24 pm

:!: ** Fix for the error in the admin panel. 09072006
:!: Fix for 1.1.4 till 1.1.5 comes out ( within 48 hours )


edit:

:!: 1.1.5 released
Upgrade instructions are in the 1.1.5 zipfile
Last edited by Ramon Fincken on Sun Jul 09, 2006 11:00 pm, edited 2 times in total.
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Sun Jul 09, 2006 1:31 pm

:!: ** upgrade 1.1.4 -> 1.1.5 09072006
* Applied a fix for 'Warning: validate_spam(): Failed opening ' error in admin panel
Upgrade instructions are in the 1.15 zipfile
Thanks to Paul and AleSSaNDRo for posting the error!
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

User avatar
Ramon Fincken
Registered User
Posts: 4835
Joined: Thu Oct 14, 2004 1:04 am
Location: NL, The Netherlands Amsterdam area @GMT +1
Contact:

Post by Ramon Fincken » Wed Jul 19, 2006 6:18 pm

removed
Last edited by Ramon Fincken on Sun Aug 20, 2006 6:26 pm, edited 2 times in total.
Dutch quality fully managed WordPress hosting - ManagedWPHosting.nl

Before changing a file, some code or installing a MOD >> Make a backup first!

Do you like my mods? paypal me $1 :) forumsoftware[AT}creativepulses[DOT}nl [/size]
PhpBBantispam.com || Instant find your mod here

Locked

Return to “[2.0.x] MODs in Development”