PluginProbe
Jetpack – WP Security, Backup, Speed, & Growth / 6.2
Jetpack – WP Security, Backup, Speed, & Growth v6.2
16.2-beta 12.0.3 12.1.3 12.2.3 12.3.2 12.4.2 12.5.2 12.6.4 12.7.3 12.8.3 12.9.5 13.0.2 13.1.5 13.2.4 13.3.3 13.4.5 13.5.2 13.6.2 13.7.2 13.8.3 13.9.2 14.0.1 14.1.1 14.2.2 14.3.1 All 501 releases
jetpack / modules / manage.php
manage.php
38 lines 1.3 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?php
2 /**
3 * Module Name: Manage
4 * Module Description: Manage all of your sites from a centralized dashboard.
5 * Jumpstart Description: Helps you remotely manage plugins, turn on automated updates, and more from <a href="https://wordpress.com/plugins/" target="_blank">wordpress.com</a>.
6 * Sort Order: 1
7 * Recommendation Order: 3
8 * First Introduced: 3.4
9 * Requires Connection: Yes
10 * Auto Activate: Yes
11 * Module Tags: Centralized Management, Recommended
12 * Feature: General
13 * Additional Search Queries: manage, management, remote
14 */
15 add_action( 'customize_register', 'add_wpcom_to_allowed_redirect_hosts' );
16
17 // Add wordpress.com to the safe redirect whitelist if the Manage module is enabled
18 // so the customizer can `return` to wordpress.com if invoked from there.
19 function add_wpcom_to_allowed_redirect_hosts( $domains ) {
20 if ( Jetpack::is_module_active( 'manage' ) ) {
21 add_filter( 'allowed_redirect_hosts', 'allow_wpcom_domain' );
22 }
23 }
24
25 // Return $domains, with 'wordpress.com' appended.
26 function allow_wpcom_domain( $domains ) {
27 if ( empty( $domains ) ) {
28 $domains = array();
29 }
30 $domains[] = 'wordpress.com';
31 return array_unique( $domains );
32 }
33
34 Jetpack::module_configuration_screen( 'manage', 'jetpack_manage_config_screen' );
35 function jetpack_manage_config_screen() {
36 include ( JETPACK__PLUGIN_DIR . 'modules/manage/confirm-admin.php' );
37 }
38