Make WordPress Core


Ignore:
Timestamp:
02/25/2015 01:49:26 AM (9 years ago)
Author:
azaozz
Message:

PressThis v2, first run. Props michael-arestad, stephdau, marcelomazza, DrewAPicture, iseulde, afercia, kraftbj, rachelbaker, AramZS, dd32. See #31373.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/ajax-actions.php

    r31511 r31534  
    29552955    wp_send_json_success( $status );
    29562956}
     2957
     2958/**
     2959 * AJAX handler for saving a post from Ptrss This.
     2960 *
     2961 * @since 4.2.0
     2962 */
     2963function wp_ajax_press_this_save_post() {
     2964    if ( empty( $GLOBALS['wp_press_this'] ) ) {
     2965        include( ABSPATH . 'wp-admin/includes/class-wp-press-this.php' );
     2966    }
     2967
     2968    $GLOBALS['wp_press_this']->save_post();
     2969}
     2970
     2971/**
     2972 * AJAX handler for creating new category from Ptrss This.
     2973 *
     2974 * @since 4.2.0
     2975 */
     2976function wp_ajax_press_this_add_category() {
     2977    if ( empty( $GLOBALS['wp_press_this'] ) ) {
     2978        include( ABSPATH . 'wp-admin/includes/class-wp-press-this.php' );
     2979    }
     2980
     2981    $GLOBALS['wp_press_this']->add_category();
     2982}
Note: See TracChangeset for help on using the changeset viewer.