-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathjetpack.php
67 lines (58 loc) · 3.56 KB
/
jetpack.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
67
<?php
/*
* Plugin Name: Jetpack by WordPress.com
* Plugin URI: http://wordpress.org/extend/plugins/jetpack/
* Description: Bring the power of the WordPress.com cloud to your self-hosted WordPress. Jetpack enables you to connect your blog to a WordPress.com account to use the powerful features normally only available to WordPress.com users.
* Author: Automattic
* Version: 2.3.3
* Author URI: http://jetpack.me
* License: GPL2+
* Text Domain: jetpack
* Domain Path: /languages/
*/
defined( 'JETPACK__API_BASE' ) or define( 'JETPACK__API_BASE', 'https://jetpack.wordpress.com/jetpack.' );
define( 'JETPACK__API_VERSION', 1 );
define( 'JETPACK__MINIMUM_WP_VERSION', '3.3' );
defined( 'JETPACK_CLIENT__AUTH_LOCATION' ) or define( 'JETPACK_CLIENT__AUTH_LOCATION', 'header' );
defined( 'JETPACK_CLIENT__HTTPS' ) or define( 'JETPACK_CLIENT__HTTPS', 'AUTO' );
define( 'JETPACK__VERSION', '2.3.3' );
define( 'JETPACK__PLUGIN_DIR', plugin_dir_path( __FILE__ ) );
defined( 'JETPACK__GLOTPRESS_LOCALES_PATH' ) or define( 'JETPACK__GLOTPRESS_LOCALES_PATH', JETPACK__PLUGIN_DIR . 'locales.php' );
define( 'JETPACK_MASTER_USER', true );
// Constants for expressing human-readable intervals
// in their respective number of seconds.
// Introduced in WordPress 3.5, specified here for backward compatability.
defined( 'MINUTE_IN_SECONDS' ) or define( 'MINUTE_IN_SECONDS', 60 );
defined( 'HOUR_IN_SECONDS' ) or define( 'HOUR_IN_SECONDS', 60 * MINUTE_IN_SECONDS );
defined( 'DAY_IN_SECONDS' ) or define( 'DAY_IN_SECONDS', 24 * HOUR_IN_SECONDS );
defined( 'WEEK_IN_SECONDS' ) or define( 'WEEK_IN_SECONDS', 7 * DAY_IN_SECONDS );
defined( 'YEAR_IN_SECONDS' ) or define( 'YEAR_IN_SECONDS', 365 * DAY_IN_SECONDS );
// @todo: Abstract out the admin functions, and only include them if is_admin()
// @todo: Only include things like class.jetpack-sync.php if we're connected.
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-client.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-data.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-client-server.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-sync.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-options.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-user-agent.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-post-images.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-error.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-debugger.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.jetpack-heartbeat.php' );
require_once( JETPACK__PLUGIN_DIR . 'class.photon.php' );
require_once( JETPACK__PLUGIN_DIR . 'functions.photon.php' );
require_once( JETPACK__PLUGIN_DIR . 'functions.compat.php' );
require_once( JETPACK__PLUGIN_DIR . 'functions.gallery.php' );
register_activation_hook( __FILE__, array( 'Jetpack', 'plugin_activation' ) );
register_deactivation_hook( __FILE__, array( 'Jetpack', 'plugin_deactivation' ) );
add_action( 'init', array( 'Jetpack', 'init' ) );
add_action( 'init', array( 'Jetpack_Heartbeat', 'init' ), 100 );
add_action( 'plugins_loaded', array( 'Jetpack', 'load_modules' ), 100 );
add_filter( 'jetpack_static_url', array( 'Jetpack', 'staticize_subdomain' ) );
/*
if ( is_admin() && ! Jetpack::check_identity_crisis() ) {
Jetpack_Sync::sync_options( __FILE__, 'db_version', 'jetpack_active_modules', 'active_plugins' );
}
*/
Jetpack_Sync::sync_options( __FILE__, 'widget_twitter' );