[ Index ] |
|
Code source de b2evolution 2.1.0-beta |
[Code source] [Imprimer] [Statistiques]
This file implements the basic Antispam plugin. This file is part of the b2evolution project - {@link http://b2evolution.net/}
Author: | blueyed: Daniel HAHLER - {@link http://daniel.hahler.de/} |
Copyright: | (c)2003-2007 by Francois PLANQUE - {@link http://fplanque.net/} |
Version: | $Id: _basic_antispam.plugin.php,v 1.30 2007/06/25 11:02:32 fplanque Exp $ |
Poids: | 713 lignes (21 kb) |
Inclus ou requis: | 0 fois |
Référencé: | 0 fois |
Nécessite: | 0 fichiers |
basic_antispam_plugin:: (17 méthodes):
PluginInit()
GetDefaultSettings()
ItemCanComment()
GetSpamKarmaForComment()
BeforeEnable()
BeforeTrackbackInsert()
BeforeCommentFormInsert()
FilterCommentAuthor()
FilterCommentAuthorUrl()
FilterCommentContent()
apply_nofollow()
AfterInstall()
AppendHitLog()
double_check_referer()
is_referer_linking_us()
is_duplicate_comment()
PluginVersionChanged()
Classe: basic_antispam_plugin - X-Ref
Basic Antispam PluginPluginInit( & $params ) X-Ref |
Init |
GetDefaultSettings() X-Ref |
Pas de description |
ItemCanComment( & $params ) X-Ref |
We check if this is an anonymous visitor and do not allow comments, if we're setup to do so. |
GetSpamKarmaForComment( & $params ) X-Ref |
Handle max_number_of_links_feedback setting. Try to detect as many links as possible |
BeforeEnable() X-Ref |
Disable/Enable events according to settings. "AppendHitLog" gets enabled according to check_url_referers setting. "BeforeTrackbackInsert" gets disabled, if we do not check for duplicate content. |
BeforeTrackbackInsert( & $params ) X-Ref |
- Check for duplicate trackbacks. |
BeforeCommentFormInsert( & $params ) X-Ref |
Check for duplicate comments. |
FilterCommentAuthor( & $params ) X-Ref |
If we use "makelink", handle nofollow rel attrib. |
FilterCommentAuthorUrl( & $params ) X-Ref |
Handle nofollow in author URL (if it's made clickable) |
FilterCommentContent( & $params ) X-Ref |
Handle nofollow rel attrib in comment content. |
apply_nofollow( & $data, $Comment ) X-Ref |
Do we want to apply rel="nofollow" tag? return: boolean |
AfterInstall() X-Ref |
Check if the deprecated hit_doublecheck_referer setting is set and then do not disable the AppendHitLog event. Also removes the old setting. |
AppendHitLog( & $params ) X-Ref |
Check if our Host+URI is in the referred page, preferrably through {@link register_shutdown_function()}. return: boolean true, if we handle {@link Hit::record_the_hit() recording of the Hit} ourself |
double_check_referer( $referer ) X-Ref |
This function gets called (as a {@link register_shutdown_function() shutdown function}, if possible) and checks if the referering URL's content includes the current URL - if not it is probably spam! On success, this methods records the hit. |
is_referer_linking_us( $referer, $uri ) X-Ref |
Check the content of a given URL (referer), if the requested URI (with different hostname variations) is present. param: string param: string URI to append to matching pattern for hostnames return: boolean |
is_duplicate_comment( $Comment ) X-Ref |
Simple check for duplicate comment/content from same author param: Comment |
PluginVersionChanged( & $params ) X-Ref |
A little housekeeping. return: true |
Généré le : Thu Nov 29 23:58:50 2007 | par Balluche grâce à PHPXref 0.7 |
![]() |