[ Index ]

PHP Cross Reference of MyBB

title

Body

[close]

/inc/plugins/ -> akismet.php (summary)

MyBB 1.6 Copyright 2010 MyBB Group, All Rights Reserved

File Size: 1505 lines (41 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 3 files
 inc/adminfunctions_templates.php
 inc/functions_upload.php
 inc/class_parser.php

Defines 1 class

Akismet:: (13 methods):
  Akismet()
  check()
  submit_spam()
  submit_ham()
  validate_api_key()
  format_post()
  build_query_string()
  connect()
  fetch_response()
  disconnect()
  set_error()
  error_exists()
  errors_exist()

Defines 13 functions

  akismet_info()
  akismet_install()
  akismet_is_installed()
  akismet_activate()
  akismet_deactivate()
  akismet_uninstall()
  akismet_key()
  akismet_show_confirm_page()
  akismet_moderation_start()
  akismet_postbit()
  akismet_verify()
  akismet_fake_draft()
  akismet_redirect_thread()
  akismet_redirect_forum()
  akismet_action_handler()
  akismet_admin_nav()
  akismet_admin_permissions()
  akismet_admin()

Class: Akismet  - X-Ref

This class is Copyright 2009 Ryan Gordon (Tikitiki)
Built to communicate with the akismet server

Akismet($url, $api_key, $post)   X-Ref
Initilize the Akismet class

param: string The board url.
param: int The API Key used to validate your use of Akismet.
param: array Array of the post that is going to be validated by Akismet.

check()   X-Ref
Checks a post against the Akismet server

return: boolean True if the comment passed spam validation.

submit_spam()   X-Ref
Submits a spam post to the Akismet server


submit_ham()   X-Ref
Submits a ham post to the Akismet server


validate_api_key()   X-Ref
Validate a API Key against the Akismet server

return: boolean True if the API Key passed.

format_post()   X-Ref
Formats the comment array to the Akismet API Standards


build_query_string()   X-Ref
Builds a query string to work with Akismet

return: string The built query string

connect()   X-Ref
Connects to the Akismet server

return: boolean True on success.

fetch_response($request, $path)   X-Ref
Sends a request to the Akismet server

param: string The request uri.
param: string The path to what is being checked (e.x. 'comment-spam').
return: mixed The response on success, false otherwise.

disconnect()   X-Ref
Disconnects from the Akismet server


set_error($error_code)   X-Ref
Append an error onto the error array

param: string The error message.
param: int The error code of the error.
return: boolean Always true.

error_exists($error_code)   X-Ref
Check if a specified error exists with the error array

param: int The error code
return: boolean True if error exists.

errors_exist()   X-Ref
Checks if there are any errors stored in the error array

return: boolean True if there errors.

Functions
Functions that are not part of a class:

akismet_info()   X-Ref
No description

akismet_install()   X-Ref
ADDITIONAL PLUGIN INSTALL/UNINSTALL ROUTINES

_install():
Called whenever a plugin is installed by clicking the "Install" button in the plugin manager.
If no install routine exists, the install button is not shown and it assumed any work will be
performed in the _activate() routine.

function hello_install()
{
}

_is_installed():
Called on the plugin management page to establish if a plugin is already installed or not.
This should return TRUE if the plugin is installed (by checking tables, fields etc) or FALSE
if the plugin is not installed.

function hello_is_installed()
{
global $db;
if($db->table_exists("hello_world"))
{
return true;
}
return false;
}

_uninstall():
Called whenever a plugin is to be uninstalled. This should remove ALL traces of the plugin
from the installation (tables etc). If it does not exist, uninstall button is not shown.

function hello_uninstall()
{
}

_activate():
Called whenever a plugin is activated via the Admin CP. This should essentially make a plugin
"visible" by adding templates/template changes, language changes etc.

function hello_activate()
{
}

_deactivate():
Called whenever a plugin is deactivated. This should essentially "hide" the plugin from view
by removing templates/template changes etc. It should not, however, remove any information
such as tables, fields etc - that should be handled by an _uninstall routine. When a plugin is
uninstalled, this routine will also be called before _uninstall() if the plugin is active.

function hello_deactivate()
{
}

akismet_is_installed()   X-Ref
No description

akismet_activate()   X-Ref
No description

akismet_deactivate()   X-Ref
No description

akismet_uninstall()   X-Ref
No description

akismet_key()   X-Ref
No description

akismet_show_confirm_page()   X-Ref
No description

akismet_moderation_start()   X-Ref
No description

akismet_postbit(&$post)   X-Ref
No description

akismet_verify(&$post)   X-Ref
No description

akismet_fake_draft(&$post)   X-Ref
No description

akismet_redirect_thread()   X-Ref
No description

akismet_redirect_forum()   X-Ref
No description

akismet_action_handler(&$action)   X-Ref
No description

akismet_admin_nav(&$sub_menu)   X-Ref
No description

akismet_admin_permissions(&$admin_permissions)   X-Ref
No description

akismet_admin()   X-Ref
No description



Generated: Tue Oct 8 19:19:50 2013 Cross-referenced by PHPXref 0.7.1