Class Pingback

Description

Habari Pingback plugin, enables pingback support between sites.

Located in /system/plugins/pingback/pingback.plugin.php (line 9)

Pluggable
   |
   --Plugin
      |
      --Pingback
Method Summary
void action_plugin_activation ( $file)
void action_post_insert_after (post $post)
void info ()
void pingback_all_links (string $content, string $source_uri, [Post $post = NULL], [boolean $force = false])
void send_pingback (string $source_uri, string $target_uri, [Post $post = NULL])
string xmlrpc_pingback__ping (array $params)
Variables

Inherited Variables

Inherited from Pluggable

Pluggable::$info
Pluggable::$plugin_id
Methods
action_add_template_vars (line 86)

Add the Pingback header on single post/page requests Not to the entire site. Clever.

  • access: public
void action_add_template_vars ()
action_plugin_activation (line 32)

Register the Pingback event type with the event log

  • access: public
void action_plugin_activation ( $file)
  • $file
action_plugin_deactivation (line 43)

Unregister the Pingback event type on deactivation

  • todo: Should we be doing this?
  • access: public
void action_plugin_deactivation ( $file)
  • $file
action_post_insert_after (line 54)

Pingback links from the post content when a post is inserted into the database.

  • access: public
void action_post_insert_after (post $post)
  • post $post: The post from which to send pingbacks
action_post_update_after (line 73)

Pingback mentioned links when a post is updated.

  • access: public
void action_post_update_after (Post $post)
  • Post $post: The post is updated We invoke this function regardless of what might have been updated in the post because:
      • the pingback_all_links function keeps track of links its already pinged, so if the content hasnt changed no pings will be sent`
    info (line 15)

    Provide plugin info to the system

    • access: public
    void info ()

    Redefinition of:
    Plugin::info()
    Returns information about this plugin
    pingback_all_links (line 295)

    Scan all links in the content and send them a Pingback.

    • access: public
    void pingback_all_links (string $content, string $source_uri, [Post $post = NULL], [boolean $force = false])
    • string $content: The post content to search
    • string $source_uri: The source of the content
    • Post $post: The post object of the source of the ping
    • boolean $force: If true, force the system to ping all links even if that had been pinged before
    send_pingback (line 235)

    Send a single Pingback

    • todo: If receive error code of already pinged, add to the successful.
    • access: public
    void send_pingback (string $source_uri, string $target_uri, [Post $post = NULL])
    • string $source_uri: The URI source of the ping (here)
    • string $target_uri: The URI destination of the ping (there, the site linked to in the content)
    • Post $post: The post object that is initiating the ping, used to track the pings that were sent
    xmlrpc_pingback__ping (line 102)

    Receive a Pingback via XMLRPC

    • return: The success state of the pingback
    • access: public
    string xmlrpc_pingback__ping (array $params)
    • array $params: An array of XMLRPC parameters from the remote call

    Inherited Methods

    Inherited From Plugin

    Plugin::__construct()
    Plugin::add_template()
    Plugin::info()
    Plugin::_plugin_available_templates()
    Plugin::_plugin_include_template_file()

    Inherited From Pluggable

    Pluggable::__construct()
    Pluggable::get_db_schema()
    Pluggable::get_file()
    Pluggable::get_url()
    Pluggable::load()
    Pluggable::load_text_domain()
    Pluggable::plugin_id()

    Documentation generated on Thu, 30 Oct 2008 20:31:22 +0100 by phpDocumentor 1.3.2