-
-
Notifications
You must be signed in to change notification settings - Fork 11
/
pubsubhubbub.php
executable file
·66 lines (52 loc) · 2.11 KB
/
pubsubhubbub.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<?php
/**
* Plugin Name: WebSub (FKA. PubSubHubbub)
* Plugin URI: https://github.com/pubsubhubbub/wordpress-pubsubhubbub/
* Description: A better way to tell the world when your blog is updated.
* Version: 3.2.1
* Author: PubSubHubbub Team
* Author URI: https://github.com/pubsubhubbub/wordpress-pubsubhubbub
* License: MIT
* License URI: http://opensource.org/licenses/MIT
* Text Domain: pubsubhubbub
* Domain Path: /languages
*/
/**
* Initialize plugin
*/
function pubsubhubbub_init() {
require_once( dirname( __FILE__ ) . '/includes/functions.php' );
/**
* Publisher integration
*/
require_once( dirname( __FILE__ ) . '/includes/class-pubsubhubbub-publisher.php' );
add_action( 'publish_post', array( 'PubSubHubbub_Publisher', 'publish_post' ) );
//add_action( 'comment_post', array( 'PubSubHubbub_Publisher', 'publish_comment' ) );
/**
* Admin panel
*/
require_once( dirname( __FILE__ ) . '/includes/class-pubsubhubbub-admin.php' );
add_action( 'init', array( 'PubSubHubbub_Admin', 'register_settings' ) );
add_action( 'admin_menu', array( 'Pubsubhubbub_Admin', 'add_plugin_menu' ) );
/**
* Feed integrations
*/
require_once( dirname( __FILE__ ) . '/includes/class-pubsubhubbub-topics.php' );
add_action( 'atom_head', array( 'Pubsubhubbub_Topics', 'add_atom_link_tag' ) );
add_action( 'rdf_header', array( 'Pubsubhubbub_Topics', 'add_rss_link_tag' ) );
add_action( 'rss2_head', array( 'Pubsubhubbub_Topics', 'add_rss_link_tag' ) );
add_action( 'comments_atom_head', array( 'Pubsubhubbub_Topics', 'add_atom_link_tag' ) );
add_action( 'commentsrss2_head', array( 'Pubsubhubbub_Topics', 'add_rss_link_tag' ) );
add_action( 'rdf_ns', array( 'Pubsubhubbub_Topics', 'add_rss_ns_link' ) );
add_action( 'template_redirect', array( 'Pubsubhubbub_Topics', 'template_redirect' ) );
/**
* Main class
*/
require_once( dirname( __FILE__ ) . '/includes/class-pubsubhubbub.php' );
add_action( 'init', array( 'PubSubHubbub', 'load_textdomain' ) );
/**
* Deprecated functions
*/
require_once( dirname( __FILE__ ) . '/includes/deprecated.php' );
}
add_action( 'plugins_loaded', 'pubsubhubbub_init' );