english/components/com_aicontactsafe/models/message.php
// 		4 - the message is spam and the message is not recorded
the message is spam and the message is not recorded
the message is spam and the message is not recorded
function checkSpam( $body = '' ) {
		$spam_response = 1;
		if ($this->_config_values['activate_spam_control']) {
			$is_spam = false;
			$block_words = explode(';',$this->_config_values['block_words']);
			foreach($block_words as $word) {
				if ( strlen(trim($word)) > 0 && !strpos($body,$word) === false ) {
					$is_spam = true;
					break;
				}
			}
			if ($is_spam) {
				if ($this->_config_values['record_blocked_messages']) {
					$spam_response = 3;
				} else {
					$spam_response = 4;
				}
			} else {
				$spam_response = 2;
			}
		}
		return $spam_response;
	}
function checkSpam ( $ body = '' ) { $ spam_response = 1 ; if ( $ this -> _config_values [ 'activate_spam_control' ] ) { $ is_spam = false ; $ block_words = explode ( ';' , $ this -> _config_values [ 'block_words' ] ) ; foreach ( $ block_words as $ word ) { if ( strlen ( trim ( $ word ) ) > 0 && ! strpos ( $ body , $ word ) === false ) { $ is_spam = true ; break ; } } if ( $ is_spam ) { if ( $ this -> _config_values [ 'record_blocked_messages' ] ) { $ spam_response = 3 ; } else { $ spam_response = 4 ; } } else { $ spam_response = 2 ; } } return $ spam_response ; }
4 - the message is spam and the message is not recorded
4 - the message is spam and the message is not recorded