Changeset 1012

Show
Ignore:
Timestamp:
03/25/04 20:18:20 (4 years ago)
Author:
saxmatt
Message:

Additional plugin API hooks, extending moderation scheme to more fully cover trackbacks and pingbacks, cleanup of XML-RPC file.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/wp-admin/post.php

    r1005 r1012  
    379379        } // end if moving from draft/private to published 
    380380        if ($post_status == 'publish') { 
     381            do_action('publish_post', $post_ID); 
    381382            // Trackback time. 
    382383            $to_ping = trim($wpdb->get_var("SELECT to_ping FROM $tableposts WHERE ID = $post_ID")); 
     
    408409        } 
    409410        header ('Location: ' . $location); 
     411        do_action('edit_post', $post_ID); 
    410412        break; 
    411413 
     
    449451        if (strstr($sendback, 'post.php')) $sendback = get_settings('siteurl') .'/wp-admin/post.php'; 
    450452        header ('Location: ' . $sendback); 
    451  
     453        do_action('delete_post', $post_ID); 
    452454        break; 
    453455 
     
    677679        if (!empty($referredby)) header('Location: ' . $referredby); 
    678680        else header ("Location: edit.php?p=$comment_post_ID&c=1#comments"); 
    679  
     681        do_action('edit_comment', $post_ID); 
    680682        break; 
    681683 
  • trunk/wp-comments-post.php

    r997 r1012  
    101101    } 
    102102 
     103    do_action('comment_post', $comment_ID); 
     104 
    103105    if ($email == '') 
    104106        $email = ' '; // this to make sure a cookie is set for 'no email' 
  • trunk/wp-includes/functions.php

    r1011 r1012  
    15681568 
    15691569function check_comment($author, $email, $url, $comment, $user_ip) { 
     1570    if (1 == get_settings('comment_moderation')) return false; 
    15701571    $words = explode("\n", get_settings('moderation_keys') ); 
    15711572    foreach ($words as $word) { 
  • trunk/wp-trackback.php

    r1003 r1012  
    8787            wp_notify_postauthor($comment_ID, 'trackback'); 
    8888        trackback_response(0); 
     89        do_action('trackback_post', $comment_ID); 
    8990    } 
    9091}