-
diff --git a/src/_index.php b/src/_index.php
index 86334797d6..8ec930efd2 100644
a
|
b
|
|
14 | 14 | define( 'WP_USE_THEMES', true ); |
15 | 15 | |
16 | 16 | /** Loads the WordPress Environment and Template */ |
17 | | require( dirname( __FILE__ ) . '/wp-blog-header.php' ); |
| 17 | require( __DIR__ . '/wp-blog-header.php' ); |
-
diff --git a/src/index.php b/src/index.php
index 9e8f9ec856..80cc9c13b9 100644
a
|
b
|
|
8 | 8 | |
9 | 9 | /** Define ABSPATH as this file's directory */ |
10 | 10 | if ( ! defined( 'ABSPATH' ) ) { |
11 | | define( 'ABSPATH', dirname( __FILE__ ) . '/' ); |
| 11 | define( 'ABSPATH', __DIR__ . '/' ); |
12 | 12 | } |
13 | 13 | |
14 | 14 | if ( file_exists( ABSPATH . 'wp-includes/js/dist/edit-post.js' ) ) { |
-
diff --git a/src/js/_enqueues/vendor/tinymce/wp-tinymce.php b/src/js/_enqueues/vendor/tinymce/wp-tinymce.php
index 3d7b2347f6..fa89ca9272 100644
a
|
b
|
|
11 | 11 | */ |
12 | 12 | error_reporting( 0 ); |
13 | 13 | |
14 | | $basepath = dirname( __FILE__ ); |
| 14 | $basepath = __DIR__; |
15 | 15 | |
16 | 16 | function get_file( $path ) { |
17 | 17 | |
-
diff --git a/src/wp-activate.php b/src/wp-activate.php
index 7107352d53..7bf2bc36c3 100644
a
|
b
|
|
9 | 9 | define( 'WP_INSTALLING', true ); |
10 | 10 | |
11 | 11 | /** Sets up the WordPress Environment. */ |
12 | | require( dirname( __FILE__ ) . '/wp-load.php' ); |
| 12 | require( __DIR__ . '/wp-load.php' ); |
13 | 13 | |
14 | | require( dirname( __FILE__ ) . '/wp-blog-header.php' ); |
| 14 | require( __DIR__ . '/wp-blog-header.php' ); |
15 | 15 | |
16 | 16 | if ( ! is_multisite() ) { |
17 | 17 | wp_redirect( wp_registration_url() ); |
-
diff --git a/src/wp-admin/_index.php b/src/wp-admin/_index.php
index 9389409e88..e771483d37 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | /** Load WordPress dashboard API */ |
13 | 13 | require_once( ABSPATH . 'wp-admin/includes/dashboard.php' ); |
-
diff --git a/src/wp-admin/about.php b/src/wp-admin/about.php
index f5d86a9892..dc053e5e52 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | /* translators: Page title of the About WordPress page in the admin. */ |
13 | 13 | $title = _x( 'About', 'page title' ); |
-
diff --git a/src/wp-admin/admin-ajax.php b/src/wp-admin/admin-ajax.php
index 7d9266d80f..897abd63f4 100644
a
|
b
|
|
19 | 19 | } |
20 | 20 | |
21 | 21 | /** Load WordPress Bootstrap */ |
22 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 22 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
23 | 23 | |
24 | 24 | /** Allow for cross-domain requests (from the front end). */ |
25 | 25 | send_origin_headers(); |
-
diff --git a/src/wp-admin/admin-header.php b/src/wp-admin/admin-header.php
index 631bc67ef3..85d38258e9 100644
a
|
b
|
|
8 | 8 | |
9 | 9 | header( 'Content-Type: ' . get_option( 'html_type' ) . '; charset=' . get_option( 'blog_charset' ) ); |
10 | 10 | if ( ! defined( 'WP_ADMIN' ) ) { |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | } |
13 | 13 | |
14 | 14 | /** |
-
diff --git a/src/wp-admin/admin-post.php b/src/wp-admin/admin-post.php
index 48e76feec5..a7fe166be0 100644
a
|
b
|
|
16 | 16 | if ( defined( 'ABSPATH' ) ) { |
17 | 17 | require_once( ABSPATH . 'wp-load.php' ); |
18 | 18 | } else { |
19 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 19 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
20 | 20 | } |
21 | 21 | |
22 | 22 | /** Allow for cross-domain requests (from the front end). */ |
-
diff --git a/src/wp-admin/admin.php b/src/wp-admin/admin.php
index 5f8916ed41..9942733e04 100644
a
|
b
|
|
31 | 31 | define( 'WP_LOAD_IMPORTERS', true ); |
32 | 32 | } |
33 | 33 | |
34 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 34 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
35 | 35 | |
36 | 36 | nocache_headers(); |
37 | 37 | |
-
diff --git a/src/wp-admin/async-upload.php b/src/wp-admin/async-upload.php
index 4d37f7f644..7e1f2655e7 100644
a
|
b
|
|
17 | 17 | if ( defined( 'ABSPATH' ) ) { |
18 | 18 | require_once( ABSPATH . 'wp-load.php' ); |
19 | 19 | } else { |
20 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 20 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
21 | 21 | } |
22 | 22 | |
23 | 23 | require_once( ABSPATH . 'wp-admin/admin.php' ); |
-
diff --git a/src/wp-admin/comment.php b/src/wp-admin/comment.php
index ee7a514be4..1b593ad285 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | $parent_file = 'edit-comments.php'; |
13 | 13 | $submenu_file = 'edit-comments.php'; |
-
diff --git a/src/wp-admin/credits.php b/src/wp-admin/credits.php
index 8940a78481..46adc6d48b 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
11 | | require_once( dirname( __FILE__ ) . '/includes/credits.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/includes/credits.php' ); |
12 | 12 | |
13 | 13 | $title = __( 'Credits' ); |
14 | 14 | |
-
diff --git a/src/wp-admin/customize.php b/src/wp-admin/customize.php
index d0f39a5ba5..eaea4b32b2 100644
a
|
b
|
|
10 | 10 | define( 'IFRAME_REQUEST', true ); |
11 | 11 | |
12 | 12 | /** Load WordPress Administration Bootstrap */ |
13 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 13 | require_once( __DIR__ . '/admin.php' ); |
14 | 14 | |
15 | 15 | if ( ! current_user_can( 'customize' ) ) { |
16 | 16 | wp_die( |
-
diff --git a/src/wp-admin/edit-comments.php b/src/wp-admin/edit-comments.php
index 0bd3b7a09d..4f2946dabd 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | if ( ! current_user_can( 'edit_posts' ) ) { |
12 | 12 | wp_die( |
13 | 13 | '<h1>' . __( 'You need a higher level of permission.' ) . '</h1>' . |
-
diff --git a/src/wp-admin/edit-tags.php b/src/wp-admin/edit-tags.php
index 80ab3ffdd8..692b080e15 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! $taxnow ) { |
13 | 13 | wp_die( __( 'Invalid taxonomy.' ) ); |
-
diff --git a/src/wp-admin/edit.php b/src/wp-admin/edit.php
index a8c2265d20..769c83589a 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! $typenow ) { |
13 | 13 | wp_die( __( 'Invalid post type.' ) ); |
-
diff --git a/src/wp-admin/erase-personal-data.php b/src/wp-admin/erase-personal-data.php
index dc80022eef..b5e6a40f3c 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'erase_others_personal_data' ) || ! current_user_can( 'delete_users' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to erase data on this site.' ) ); |
-
diff --git a/src/wp-admin/export-personal-data.php b/src/wp-admin/export-personal-data.php
index a4eef779c2..fcf0e63b2d 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'export_others_personal_data' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to export personal data on this site.' ) ); |
-
diff --git a/src/wp-admin/export.php b/src/wp-admin/export.php
index 759723456e..ba3e57d55d 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'export' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to export the content of this site.' ) ); |
-
diff --git a/src/wp-admin/freedoms.php b/src/wp-admin/freedoms.php
index fe8f1868f9..b836b290ca 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | // This file was used to also display the Privacy tab on the About screen from 4.9.6 until 5.3.0. |
13 | 13 | if ( isset( $_GET['privacy-notice'] ) ) { |
-
diff --git a/src/wp-admin/import.php b/src/wp-admin/import.php
index 6da936405f..a0b60fcde9 100644
a
|
b
|
|
9 | 9 | define( 'WP_LOAD_IMPORTERS', true ); |
10 | 10 | |
11 | 11 | /** Load WordPress Bootstrap */ |
12 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 12 | require_once( __DIR__ . '/admin.php' ); |
13 | 13 | |
14 | 14 | if ( ! current_user_can( 'import' ) ) { |
15 | 15 | wp_die( __( 'Sorry, you are not allowed to import content into this site.' ) ); |
-
diff --git a/src/wp-admin/includes/class-ftp.php b/src/wp-admin/includes/class-ftp.php
index 3bfa469d20..3d19172371 100644
a
|
b
|
function PopError(){ |
903 | 903 | $mod_sockets = extension_loaded( 'sockets' ); |
904 | 904 | } |
905 | 905 | |
906 | | require_once dirname( __FILE__ ) . "/class-ftp-" . ( $mod_sockets ? "sockets" : "pure" ) . ".php"; |
| 906 | require_once __DIR__ . "/class-ftp-" . ( $mod_sockets ? "sockets" : "pure" ) . ".php"; |
907 | 907 | |
908 | 908 | if ( $mod_sockets ) { |
909 | 909 | class ftp extends ftp_sockets {} |
-
diff --git a/src/wp-admin/index.php b/src/wp-admin/index.php
index 6db93a9df4..d874b11df0 100644
a
|
b
|
|
6 | 6 | * please refer to wp-admin/_index.php. |
7 | 7 | */ |
8 | 8 | |
9 | | if ( file_exists( dirname( __FILE__ ) . '/../wp-includes/js/dist/edit-post.js' ) ) { |
10 | | require_once dirname( __FILE__ ) . '/_index.php'; |
| 9 | if ( file_exists( __DIR__ . '/../wp-includes/js/dist/edit-post.js' ) ) { |
| 10 | require_once __DIR__ . '/_index.php'; |
11 | 11 | return; |
12 | 12 | } |
13 | 13 | |
14 | | require_once dirname( dirname( __FILE__ ) ) . '/index.php'; |
| 14 | require_once dirname( __DIR__) . '/index.php'; |
-
diff --git a/src/wp-admin/install-helper.php b/src/wp-admin/install-helper.php
index c13f302784..72894a14c6 100644
a
|
b
|
|
35 | 35 | */ |
36 | 36 | |
37 | 37 | /** Load WordPress Bootstrap */ |
38 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 38 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
39 | 39 | |
40 | 40 | if ( ! function_exists( 'maybe_create_table' ) ) : |
41 | 41 | /** |
-
diff --git a/src/wp-admin/install.php b/src/wp-admin/install.php
index 68408c9c41..85e3259e1e 100644
a
|
b
|
|
33 | 33 | define( 'WP_INSTALLING', true ); |
34 | 34 | |
35 | 35 | /** Load WordPress Bootstrap */ |
36 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 36 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
37 | 37 | |
38 | 38 | /** Load WordPress Administration Upgrade API */ |
39 | 39 | require_once( ABSPATH . 'wp-admin/includes/upgrade.php' ); |
-
diff --git a/src/wp-admin/link-add.php b/src/wp-admin/link-add.php
index ff617d5777..d2159dc724 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_links' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to add links to this site.' ) ); |
-
diff --git a/src/wp-admin/link-manager.php b/src/wp-admin/link-manager.php
index e8418ea0ec..38cfb9c9e3 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | if ( ! current_user_can( 'manage_links' ) ) { |
12 | 12 | wp_die( __( 'Sorry, you are not allowed to edit the links for this site.' ) ); |
13 | 13 | } |
-
diff --git a/src/wp-admin/link.php b/src/wp-admin/link.php
index ef5b26a515..284eb5f855 100644
a
|
b
|
|
10 | 10 | */ |
11 | 11 | |
12 | 12 | /** Load WordPress Administration Bootstrap */ |
13 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 13 | require_once( __DIR__ . '/admin.php' ); |
14 | 14 | |
15 | 15 | wp_reset_vars( array( 'action', 'cat_id', 'link_id' ) ); |
16 | 16 | |
-
diff --git a/src/wp-admin/load-scripts.php b/src/wp-admin/load-scripts.php
index bdb5fa5cec..49e0319cab 100644
a
|
b
|
|
9 | 9 | |
10 | 10 | /** Set ABSPATH for execution */ |
11 | 11 | if ( ! defined( 'ABSPATH' ) ) { |
12 | | define( 'ABSPATH', dirname( dirname( __FILE__ ) ) . '/' ); |
| 12 | define( 'ABSPATH', dirname( __DIR__) . '/' ); |
13 | 13 | } |
14 | 14 | |
15 | 15 | define( 'WPINC', 'wp-includes' ); |
-
diff --git a/src/wp-admin/load-styles.php b/src/wp-admin/load-styles.php
index 8b3cc0d75f..5e324c0df6 100644
a
|
b
|
|
9 | 9 | |
10 | 10 | /** Set ABSPATH for execution */ |
11 | 11 | if ( ! defined( 'ABSPATH' ) ) { |
12 | | define( 'ABSPATH', dirname( dirname( __FILE__ ) ) . '/' ); |
| 12 | define( 'ABSPATH', dirname( __DIR__) . '/' ); |
13 | 13 | } |
14 | 14 | |
15 | 15 | define( 'WPINC', 'wp-includes' ); |
-
diff --git a/src/wp-admin/maint/repair.php b/src/wp-admin/maint/repair.php
index 070a91b118..b298684e7d 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | define( 'WP_REPAIRING', true ); |
9 | 9 | |
10 | | require_once( dirname( dirname( dirname( __FILE__ ) ) ) . '/wp-load.php' ); |
| 10 | require_once(dirname( dirname( __DIR__) ) . '/wp-load.php' ); |
11 | 11 | |
12 | 12 | header( 'Content-Type: text/html; charset=utf-8' ); |
13 | 13 | ?> |
-
diff --git a/src/wp-admin/media-new.php b/src/wp-admin/media-new.php
index 0cc82a5fd4..de4b2335b5 100644
a
|
b
|
|
10 | 10 | */ |
11 | 11 | |
12 | 12 | /** Load WordPress Administration Bootstrap */ |
13 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 13 | require_once( __DIR__ . '/admin.php' ); |
14 | 14 | |
15 | 15 | if ( ! current_user_can( 'upload_files' ) ) { |
16 | 16 | wp_die( __( 'Sorry, you are not allowed to upload files.' ) ); |
-
diff --git a/src/wp-admin/media-upload.php b/src/wp-admin/media-upload.php
index 2354cf629d..4b0eaa2629 100644
a
|
b
|
|
14 | 14 | } |
15 | 15 | |
16 | 16 | /** Load WordPress Administration Bootstrap */ |
17 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 17 | require_once( __DIR__ . '/admin.php' ); |
18 | 18 | |
19 | 19 | if ( ! current_user_can( 'upload_files' ) ) { |
20 | 20 | wp_die( __( 'Sorry, you are not allowed to upload files.' ), 403 ); |
-
diff --git a/src/wp-admin/media.php b/src/wp-admin/media.php
index 1e09eda2f8..8d8c039cec 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | $parent_file = 'upload.php'; |
13 | 13 | $submenu_file = 'upload.php'; |
-
diff --git a/src/wp-admin/moderation.php b/src/wp-admin/moderation.php
index ae375df3e7..0e1c95cff5 100644
a
|
b
|
|
7 | 7 | * @package WordPress |
8 | 8 | * @subpackage Administration |
9 | 9 | */ |
10 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 10 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
11 | 11 | wp_redirect( admin_url( 'edit-comments.php?comment_status=moderated' ) ); |
12 | 12 | exit; |
-
diff --git a/src/wp-admin/ms-admin.php b/src/wp-admin/ms-admin.php
index 35e21e971a..2e1478d2fe 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url() ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/ms-delete-site.php b/src/wp-admin/ms-delete-site.php
index 3cb1574356..a8e4c2e117 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! is_multisite() ) { |
13 | 13 | wp_die( __( 'Multisite support is not enabled.' ) ); |
-
diff --git a/src/wp-admin/ms-edit.php b/src/wp-admin/ms-edit.php
index 5c405e6f73..00a2d9353b 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url() ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/ms-options.php b/src/wp-admin/ms-options.php
index 6bf5eb6b1b..34d6fcec67 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url( 'settings.php' ) ); |
-
diff --git a/src/wp-admin/ms-sites.php b/src/wp-admin/ms-sites.php
index 79602cb07f..1025bac1be 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url( 'sites.php' ) ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/ms-themes.php b/src/wp-admin/ms-themes.php
index 4b86ac9684..94b51035cf 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url( 'themes.php' ) ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/ms-upgrade-network.php b/src/wp-admin/ms-upgrade-network.php
index 892ab964c7..3730349eb8 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url( 'upgrade.php' ) ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/ms-users.php b/src/wp-admin/ms-users.php
index 1b00514ec3..cd0a0e54de 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_redirect( network_admin_url( 'users.php' ) ); |
13 | 13 | exit; |
-
diff --git a/src/wp-admin/my-sites.php b/src/wp-admin/my-sites.php
index 0d925b4184..79dbf9690b 100644
a
|
b
|
|
7 | 7 | * @since 3.0.0 |
8 | 8 | */ |
9 | 9 | |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! is_multisite() ) { |
13 | 13 | wp_die( __( 'Multisite support is not enabled.' ) ); |
-
diff --git a/src/wp-admin/nav-menus.php b/src/wp-admin/nav-menus.php
index 3312a30443..e15fc492f0 100644
a
|
b
|
|
10 | 10 | */ |
11 | 11 | |
12 | 12 | /** Load WordPress Administration Bootstrap */ |
13 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 13 | require_once( __DIR__ . '/admin.php' ); |
14 | 14 | |
15 | 15 | // Load all the nav menu interface functions |
16 | 16 | require_once( ABSPATH . 'wp-admin/includes/nav-menu.php' ); |
-
diff --git a/src/wp-admin/network.php b/src/wp-admin/network.php
index a3409622a0..2c57d7aadf 100644
a
|
b
|
|
13 | 13 | define( 'WP_INSTALLING_NETWORK', true ); |
14 | 14 | |
15 | 15 | /** WordPress Administration Bootstrap */ |
16 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 16 | require_once( __DIR__ . '/admin.php' ); |
17 | 17 | |
18 | 18 | if ( ! current_user_can( 'setup_network' ) ) { |
19 | 19 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
… |
… |
|
30 | 30 | } |
31 | 31 | } |
32 | 32 | |
33 | | require_once( dirname( __FILE__ ) . '/includes/network.php' ); |
| 33 | require_once( __DIR__ . '/includes/network.php' ); |
34 | 34 | |
35 | 35 | // We need to create references to ms global tables to enable Network. |
36 | 36 | foreach ( $wpdb->tables( 'ms_global' ) as $table => $prefixed_table ) { |
-
diff --git a/src/wp-admin/network/about.php b/src/wp-admin/network/about.php
index 829fa1beef..892f2937d2 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/about.php' ); |
-
diff --git a/src/wp-admin/network/admin.php b/src/wp-admin/network/admin.php
index 693fa5aa11..e746f3ac9a 100644
a
|
b
|
|
10 | 10 | define( 'WP_NETWORK_ADMIN', true ); |
11 | 11 | |
12 | 12 | /** Load WordPress Administration Bootstrap */ |
13 | | require_once( dirname( dirname( __FILE__ ) ) . '/admin.php' ); |
| 13 | require_once(dirname( __DIR__) . '/admin.php' ); |
14 | 14 | |
15 | 15 | // Do not remove this check. It is required by individual network admin pages. |
16 | 16 | if ( ! is_multisite() ) { |
-
diff --git a/src/wp-admin/network/credits.php b/src/wp-admin/network/credits.php
index 75ee6e7337..db3de9c9bc 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/credits.php' ); |
-
diff --git a/src/wp-admin/network/edit.php b/src/wp-admin/network/edit.php
index 51381e40bf..107d886c24 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | $action = ( isset( $_GET['action'] ) ) ? $_GET['action'] : ''; |
14 | 14 | |
-
diff --git a/src/wp-admin/network/freedoms.php b/src/wp-admin/network/freedoms.php
index 9afbe82f34..c209054715 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/freedoms.php' ); |
-
diff --git a/src/wp-admin/network/index.php b/src/wp-admin/network/index.php
index fbc169bd21..bbbf19c495 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | /** Load WordPress dashboard API */ |
14 | 14 | require_once( ABSPATH . 'wp-admin/includes/dashboard.php' ); |
-
diff --git a/src/wp-admin/network/plugin-editor.php b/src/wp-admin/network/plugin-editor.php
index 7171e7252c..11f5af2459 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/plugin-editor.php' ); |
-
diff --git a/src/wp-admin/network/plugin-install.php b/src/wp-admin/network/plugin-install.php
index f771f63a88..d1ed6ce76f 100644
a
|
b
|
|
12 | 12 | } |
13 | 13 | |
14 | 14 | /** Load WordPress Administration Bootstrap */ |
15 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 15 | require_once( __DIR__ . '/admin.php' ); |
16 | 16 | |
17 | 17 | require( ABSPATH . 'wp-admin/plugin-install.php' ); |
-
diff --git a/src/wp-admin/network/plugins.php b/src/wp-admin/network/plugins.php
index 56c3debd01..49b5316912 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/plugins.php' ); |
-
diff --git a/src/wp-admin/network/privacy.php b/src/wp-admin/network/privacy.php
index 5cba05d37d..a126cd586f 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/privacy.php' ); |
-
diff --git a/src/wp-admin/network/profile.php b/src/wp-admin/network/profile.php
index 240ef980a4..f070b2021b 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/profile.php' ); |
-
diff --git a/src/wp-admin/network/settings.php b/src/wp-admin/network/settings.php
index c100a665f3..206432aa0f 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | /** WordPress Translation Installation API */ |
14 | 14 | require_once( ABSPATH . 'wp-admin/includes/translation-install.php' ); |
-
diff --git a/src/wp-admin/network/setup.php b/src/wp-admin/network/setup.php
index 9a642bbb92..e9d77e1643 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/network.php' ); |
-
diff --git a/src/wp-admin/network/site-info.php b/src/wp-admin/network/site-info.php
index 2bcc1c58a3..419cbb9999 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_sites' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to edit this site.' ) ); |
-
diff --git a/src/wp-admin/network/site-new.php b/src/wp-admin/network/site-new.php
index d86058e0f4..4cf1e21274 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | /** WordPress Translation Installation API */ |
14 | 14 | require_once( ABSPATH . 'wp-admin/includes/translation-install.php' ); |
-
diff --git a/src/wp-admin/network/site-settings.php b/src/wp-admin/network/site-settings.php
index 7c3cae7200..7694d9dc09 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_sites' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to edit this site.' ) ); |
-
diff --git a/src/wp-admin/network/site-themes.php b/src/wp-admin/network/site-themes.php
index fc1a79805f..21494a4f0e 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_sites' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to manage themes for this site.' ) ); |
-
diff --git a/src/wp-admin/network/site-users.php b/src/wp-admin/network/site-users.php
index 5113025776..bff3495727 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_sites' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to edit this site.' ), 403 ); |
-
diff --git a/src/wp-admin/network/sites.php b/src/wp-admin/network/sites.php
index bfd5a1d4bd..5f5ae820c0 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_sites' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to access this page.' ), 403 ); |
-
diff --git a/src/wp-admin/network/theme-editor.php b/src/wp-admin/network/theme-editor.php
index c28c9675cc..e5083855d8 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/theme-editor.php' ); |
-
diff --git a/src/wp-admin/network/theme-install.php b/src/wp-admin/network/theme-install.php
index 486c74780b..9647412046 100644
a
|
b
|
|
12 | 12 | } |
13 | 13 | |
14 | 14 | /** Load WordPress Administration Bootstrap */ |
15 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 15 | require_once( __DIR__ . '/admin.php' ); |
16 | 16 | |
17 | 17 | require( ABSPATH . 'wp-admin/theme-install.php' ); |
-
diff --git a/src/wp-admin/network/themes.php b/src/wp-admin/network/themes.php
index f7711f034d..2d7bda8932 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_network_themes' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to manage network themes.' ) ); |
-
diff --git a/src/wp-admin/network/update-core.php b/src/wp-admin/network/update-core.php
index 55f2aca32a..492321cb9a 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/update-core.php' ); |
-
diff --git a/src/wp-admin/network/update.php b/src/wp-admin/network/update.php
index 62dc7a96e7..d32d49490c 100644
a
|
b
|
|
12 | 12 | } |
13 | 13 | |
14 | 14 | /** Load WordPress Administration Bootstrap */ |
15 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 15 | require_once( __DIR__ . '/admin.php' ); |
16 | 16 | |
17 | 17 | require( ABSPATH . 'wp-admin/update.php' ); |
-
diff --git a/src/wp-admin/network/upgrade.php b/src/wp-admin/network/upgrade.php
index e594a17555..39cca1f165 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require_once( ABSPATH . WPINC . '/http.php' ); |
14 | 14 | |
-
diff --git a/src/wp-admin/network/user-edit.php b/src/wp-admin/network/user-edit.php
index ef3c2720f1..c594c19e24 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/user-edit.php' ); |
-
diff --git a/src/wp-admin/network/user-new.php b/src/wp-admin/network/user-new.php
index 2bb2de1ed7..54f42dad22 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'create_users' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to add users to this network.' ) ); |
-
diff --git a/src/wp-admin/network/users.php b/src/wp-admin/network/users.php
index 9c5bcc0ca4..c49c642798 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'manage_network_users' ) ) { |
14 | 14 | wp_die( __( 'Sorry, you are not allowed to access this page.' ), 403 ); |
-
diff --git a/src/wp-admin/options-discussion.php b/src/wp-admin/options-discussion.php
index b9e037a00e..21a7a8820e 100644
a
|
b
|
|
6 | 6 | * @subpackage Administration |
7 | 7 | */ |
8 | 8 | /** WordPress Administration Bootstrap */ |
9 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 9 | require_once( __DIR__ . '/admin.php' ); |
10 | 10 | |
11 | 11 | if ( ! current_user_can( 'manage_options' ) ) { |
12 | 12 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
-
diff --git a/src/wp-admin/options-general.php b/src/wp-admin/options-general.php
index d5c3d167c4..8937d0944f 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | /** WordPress Translation Installation API */ |
13 | 13 | require_once( ABSPATH . 'wp-admin/includes/translation-install.php' ); |
-
diff --git a/src/wp-admin/options-media.php b/src/wp-admin/options-media.php
index 4cc5e4c5ef..04596b01c7 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
-
diff --git a/src/wp-admin/options-permalink.php b/src/wp-admin/options-permalink.php
index 2b6e08101c..5b83e8f55b 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
-
diff --git a/src/wp-admin/options-privacy.php b/src/wp-admin/options-privacy.php
index 875809843f..c02279d161 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_privacy_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage privacy on this site.' ) ); |
-
diff --git a/src/wp-admin/options-reading.php b/src/wp-admin/options-reading.php
index 662954ea24..3a289b00f1 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
-
diff --git a/src/wp-admin/options-writing.php b/src/wp-admin/options-writing.php
index 1ea19cd129..46751294eb 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage options for this site.' ) ); |
-
diff --git a/src/wp-admin/options.php b/src/wp-admin/options.php
index 1aaad130b4..4e57d672b9 100644
a
|
b
|
|
16 | 16 | */ |
17 | 17 | |
18 | 18 | /** WordPress Administration Bootstrap */ |
19 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 19 | require_once( __DIR__ . '/admin.php' ); |
20 | 20 | |
21 | 21 | $title = __( 'Settings' ); |
22 | 22 | $this_file = 'options.php'; |
-
diff --git a/src/wp-admin/plugin-editor.php b/src/wp-admin/plugin-editor.php
index 0b44fbb499..70007b87f1 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( is_multisite() && ! is_network_admin() ) { |
13 | 13 | wp_redirect( network_admin_url( 'plugin-editor.php' ) ); |
-
diff --git a/src/wp-admin/plugin-install.php b/src/wp-admin/plugin-install.php
index 52dd791684..9d8f750e37 100644
a
|
b
|
|
13 | 13 | /** |
14 | 14 | * WordPress Administration Bootstrap. |
15 | 15 | */ |
16 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 16 | require_once( __DIR__ . '/admin.php' ); |
17 | 17 | |
18 | 18 | if ( ! current_user_can( 'install_plugins' ) ) { |
19 | 19 | wp_die( __( 'Sorry, you are not allowed to install plugins on this site.' ) ); |
-
diff --git a/src/wp-admin/plugins.php b/src/wp-admin/plugins.php
index eb80edcd4b..7a2c875b31 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'activate_plugins' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage plugins for this site.' ) ); |
-
diff --git a/src/wp-admin/post-new.php b/src/wp-admin/post-new.php
index a93a11bffe..04a6833cca 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** Load WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | /** |
13 | 13 | * @global string $post_type |
-
diff --git a/src/wp-admin/post.php b/src/wp-admin/post.php
index 5f8634980b..59e3db60d5 100644
a
|
b
|
|
9 | 9 | */ |
10 | 10 | |
11 | 11 | /** WordPress Administration Bootstrap */ |
12 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 12 | require_once( __DIR__ . '/admin.php' ); |
13 | 13 | |
14 | 14 | $parent_file = 'edit.php'; |
15 | 15 | $submenu_file = 'edit.php'; |
-
diff --git a/src/wp-admin/press-this.php b/src/wp-admin/press-this.php
index 0f00dee40b..0a1ce62df3 100644
a
|
b
|
|
9 | 9 | define( 'IFRAME_REQUEST', true ); |
10 | 10 | |
11 | 11 | /** WordPress Administration Bootstrap */ |
12 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 12 | require_once( __DIR__ . '/admin.php' ); |
13 | 13 | |
14 | 14 | function wp_load_press_this() { |
15 | 15 | $plugin_slug = 'press-this'; |
-
diff --git a/src/wp-admin/privacy-policy-guide.php b/src/wp-admin/privacy-policy-guide.php
index f3d8703f88..4a875c24f8 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'manage_privacy_options' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to manage privacy on this site.' ) ); |
-
diff --git a/src/wp-admin/privacy.php b/src/wp-admin/privacy.php
index 075f6b89bf..5dbf4c8f46 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | $title = __( 'Privacy' ); |
13 | 13 | |
-
diff --git a/src/wp-admin/profile.php b/src/wp-admin/profile.php
index 577925aba7..6e340d8b55 100644
a
|
b
|
|
15 | 15 | define( 'IS_PROFILE_PAGE', true ); |
16 | 16 | |
17 | 17 | /** Load User Editing Page */ |
18 | | require_once( dirname( __FILE__ ) . '/user-edit.php' ); |
| 18 | require_once( __DIR__ . '/user-edit.php' ); |
-
diff --git a/src/wp-admin/revision.php b/src/wp-admin/revision.php
index 2d435a6c34..fa3563fac0 100644
a
|
b
|
|
10 | 10 | */ |
11 | 11 | |
12 | 12 | /** WordPress Administration Bootstrap */ |
13 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 13 | require_once( __DIR__ . '/admin.php' ); |
14 | 14 | |
15 | 15 | require ABSPATH . 'wp-admin/includes/revision.php'; |
16 | 16 | |
-
diff --git a/src/wp-admin/setup-config.php b/src/wp-admin/setup-config.php
index f9be50f05a..7060f830f2 100644
a
|
b
|
|
27 | 27 | error_reporting( 0 ); |
28 | 28 | |
29 | 29 | if ( ! defined( 'ABSPATH' ) ) { |
30 | | define( 'ABSPATH', dirname( dirname( __FILE__ ) ) . '/' ); |
| 30 | define( 'ABSPATH', dirname( __DIR__) . '/' ); |
31 | 31 | } |
32 | 32 | |
33 | 33 | require( ABSPATH . 'wp-settings.php' ); |
-
diff --git a/src/wp-admin/site-health-info.php b/src/wp-admin/site-health-info.php
index 34471a0968..b8169acc55 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | $title = __( 'Site Health Info' ); |
13 | 13 | |
-
diff --git a/src/wp-admin/site-health.php b/src/wp-admin/site-health.php
index 9e3a847f6a..8191a15647 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | if ( isset( $_GET['tab'] ) && 'debug' === $_GET['tab'] ) { |
10 | | require_once( dirname( __FILE__ ) . '/site-health-info.php' ); |
| 10 | require_once( __DIR__ . '/site-health-info.php' ); |
11 | 11 | return; |
12 | 12 | } |
13 | 13 | |
14 | 14 | /** WordPress Administration Bootstrap */ |
15 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 15 | require_once( __DIR__ . '/admin.php' ); |
16 | 16 | |
17 | 17 | $title = __( 'Site Health Status' ); |
18 | 18 | |
-
diff --git a/src/wp-admin/term.php b/src/wp-admin/term.php
index ec8b359d5d..21207d4238 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( empty( $_REQUEST['tag_ID'] ) ) { |
14 | 14 | $sendback = admin_url( 'edit-tags.php' ); |
-
diff --git a/src/wp-admin/theme-editor.php b/src/wp-admin/theme-editor.php
index c958353e1f..43c9d56b72 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( is_multisite() && ! is_network_admin() ) { |
13 | 13 | wp_redirect( network_admin_url( 'theme-editor.php' ) ); |
-
diff --git a/src/wp-admin/theme-install.php b/src/wp-admin/theme-install.php
index b77e85054a..4cd6eaaef0 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | require( ABSPATH . 'wp-admin/includes/theme-install.php' ); |
12 | 12 | |
13 | 13 | wp_reset_vars( array( 'tab' ) ); |
-
diff --git a/src/wp-admin/themes.php b/src/wp-admin/themes.php
index 082819611b..4b9835a7c5 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'switch_themes' ) && ! current_user_can( 'edit_theme_options' ) ) { |
13 | 13 | wp_die( |
-
diff --git a/src/wp-admin/tools.php b/src/wp-admin/tools.php
index bbc95ee4fa..0028923e91 100644
a
|
b
|
|
19 | 19 | } |
20 | 20 | |
21 | 21 | /** WordPress Administration Bootstrap */ |
22 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 22 | require_once( __DIR__ . '/admin.php' ); |
23 | 23 | |
24 | 24 | // The privacy policy guide used to be outputted from here. Since WP 5.3 it is in wp-admin/privacy-policy-guide.php. |
25 | 25 | if ( isset( $_GET['wp-privacy-policy-guide'] ) ) { |
-
diff --git a/src/wp-admin/update-core.php b/src/wp-admin/update-core.php
index e2696ebf62..2c6a7d6395 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_enqueue_style( 'plugin-install' ); |
13 | 13 | wp_enqueue_script( 'plugin-install' ); |
-
diff --git a/src/wp-admin/update.php b/src/wp-admin/update.php
index 5a70aa87d9..e778fe6046 100644
a
|
b
|
|
11 | 11 | } |
12 | 12 | |
13 | 13 | /** WordPress Administration Bootstrap */ |
14 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 14 | require_once( __DIR__ . '/admin.php' ); |
15 | 15 | |
16 | 16 | include_once( ABSPATH . 'wp-admin/includes/class-wp-upgrader.php' ); |
17 | 17 | |
-
diff --git a/src/wp-admin/upgrade.php b/src/wp-admin/upgrade.php
index 67555f4fe9..5a8f928552 100644
a
|
b
|
|
15 | 15 | define( 'WP_INSTALLING', true ); |
16 | 16 | |
17 | 17 | /** Load WordPress Bootstrap */ |
18 | | require( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 18 | require(dirname( __DIR__) . '/wp-load.php' ); |
19 | 19 | |
20 | 20 | nocache_headers(); |
21 | 21 | |
-
diff --git a/src/wp-admin/upload.php b/src/wp-admin/upload.php
index f399eaf446..d013beb155 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( ! current_user_can( 'upload_files' ) ) { |
13 | 13 | wp_die( __( 'Sorry, you are not allowed to upload files.' ) ); |
-
diff --git a/src/wp-admin/user-edit.php b/src/wp-admin/user-edit.php
index 70f6ef1a3d..33e20ec249 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | wp_reset_vars( array( 'action', 'user_id', 'wp_http_referer' ) ); |
13 | 13 | |
-
diff --git a/src/wp-admin/user-new.php b/src/wp-admin/user-new.php
index d8c76e6758..2ee610530f 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | if ( is_multisite() ) { |
13 | 13 | if ( ! current_user_can( 'create_users' ) && ! current_user_can( 'promote_users' ) ) { |
-
diff --git a/src/wp-admin/user/about.php b/src/wp-admin/user/about.php
index b7943550e9..97e66bb808 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/about.php' ); |
-
diff --git a/src/wp-admin/user/admin.php b/src/wp-admin/user/admin.php
index 9df8f2029e..93140ff994 100644
a
|
b
|
|
9 | 9 | |
10 | 10 | define( 'WP_USER_ADMIN', true ); |
11 | 11 | |
12 | | require_once( dirname( dirname( __FILE__ ) ) . '/admin.php' ); |
| 12 | require_once(dirname( __DIR__) . '/admin.php' ); |
13 | 13 | |
14 | 14 | if ( ! is_multisite() ) { |
15 | 15 | wp_redirect( admin_url() ); |
-
diff --git a/src/wp-admin/user/credits.php b/src/wp-admin/user/credits.php
index 2b4021acb9..0dc832b26c 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/credits.php' ); |
-
diff --git a/src/wp-admin/user/freedoms.php b/src/wp-admin/user/freedoms.php
index d2b77b5615..2dc15917c8 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/freedoms.php' ); |
-
diff --git a/src/wp-admin/user/index.php b/src/wp-admin/user/index.php
index 7cff6a7053..0df579db61 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/index.php' ); |
-
diff --git a/src/wp-admin/user/privacy.php b/src/wp-admin/user/privacy.php
index 8b28eea618..c0d02d3e63 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/privacy.php' ); |
-
diff --git a/src/wp-admin/user/profile.php b/src/wp-admin/user/profile.php
index 2f70709906..75eb433570 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/profile.php' ); |
-
diff --git a/src/wp-admin/user/user-edit.php b/src/wp-admin/user/user-edit.php
index 0819573f6f..f38d5c698b 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Load WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | require( ABSPATH . 'wp-admin/user-edit.php' ); |
-
diff --git a/src/wp-admin/users.php b/src/wp-admin/users.php
index 884b143a15..8eb2c8b82d 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** WordPress Administration Bootstrap */ |
11 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 11 | require_once( __DIR__ . '/admin.php' ); |
12 | 12 | |
13 | 13 | if ( ! current_user_can( 'list_users' ) ) { |
14 | 14 | wp_die( |
-
diff --git a/src/wp-admin/widgets.php b/src/wp-admin/widgets.php
index 6882b53232..40b98e77cb 100644
a
|
b
|
|
7 | 7 | */ |
8 | 8 | |
9 | 9 | /** WordPress Administration Bootstrap */ |
10 | | require_once( dirname( __FILE__ ) . '/admin.php' ); |
| 10 | require_once( __DIR__ . '/admin.php' ); |
11 | 11 | |
12 | 12 | /** WordPress Administration Widgets API */ |
13 | 13 | require_once( ABSPATH . 'wp-admin/includes/widgets.php' ); |
-
diff --git a/src/wp-blog-header.php b/src/wp-blog-header.php
index a8b1efc7b5..4d1ce36fa9 100644
a
|
b
|
|
10 | 10 | $wp_did_header = true; |
11 | 11 | |
12 | 12 | // Load the WordPress library. |
13 | | require_once( dirname( __FILE__ ) . '/wp-load.php' ); |
| 13 | require_once( __DIR__ . '/wp-load.php' ); |
14 | 14 | |
15 | 15 | // Set up the WordPress query. |
16 | 16 | wp(); |
-
diff --git a/src/wp-comments-post.php b/src/wp-comments-post.php
index fe03cb7296..70ce9756f9 100644
a
|
b
|
|
18 | 18 | } |
19 | 19 | |
20 | 20 | /** Sets up the WordPress Environment. */ |
21 | | require( dirname( __FILE__ ) . '/wp-load.php' ); |
| 21 | require( __DIR__ . '/wp-load.php' ); |
22 | 22 | |
23 | 23 | nocache_headers(); |
24 | 24 | |
-
diff --git a/src/wp-cron.php b/src/wp-cron.php
index 1a944c216e..e4aeb3d6b5 100644
a
|
b
|
|
38 | 38 | |
39 | 39 | if ( ! defined( 'ABSPATH' ) ) { |
40 | 40 | /** Set up WordPress environment */ |
41 | | require_once( dirname( __FILE__ ) . '/wp-load.php' ); |
| 41 | require_once( __DIR__ . '/wp-load.php' ); |
42 | 42 | } |
43 | 43 | |
44 | 44 | /** |
-
diff --git a/src/wp-includes/ID3/getid3.lib.php b/src/wp-includes/ID3/getid3.lib.php
index 1d51e8c4f3..f1b9fb7b34 100644
a
|
b
|
public static function GetDataImageSize($imgData, &$imageinfo=array()) { |
1486 | 1486 | } |
1487 | 1487 | |
1488 | 1488 | // yes this is ugly, feel free to suggest a better way |
1489 | | if (include_once(dirname(__FILE__).'/getid3.php')) { |
| 1489 | if (include_once( __DIR__ . '/getid3.php')) { |
1490 | 1490 | if ($getid3_temp = new getID3()) { |
1491 | 1491 | if ($getid3_temp_tempdir = $getid3_temp->tempdir) { |
1492 | 1492 | $tempdir = $getid3_temp_tempdir; |
-
diff --git a/src/wp-includes/ID3/getid3.php b/src/wp-includes/ID3/getid3.php
index cb25253e22..f2471d20b6 100644
a
|
b
|
|
15 | 15 | } |
16 | 16 | // Get base path of getID3() - ONCE |
17 | 17 | if (!defined('GETID3_INCLUDEPATH')) { |
18 | | define('GETID3_INCLUDEPATH', dirname(__FILE__).DIRECTORY_SEPARATOR); |
| 18 | define('GETID3_INCLUDEPATH', __DIR__ . DIRECTORY_SEPARATOR); |
19 | 19 | } |
20 | 20 | // Workaround Bug #39923 (https://bugs.php.net/bug.php?id=39923) |
21 | 21 | if (!defined('IMG_JPG') && defined('IMAGETYPE_JPEG')) { |
-
diff --git a/src/wp-includes/SimplePie/Misc.php b/src/wp-includes/SimplePie/Misc.php
index 1c1b618414..c918577565 100644
a
|
b
|
function embed_wmedia(width, height, link) { |
2162 | 2162 | */ |
2163 | 2163 | public static function get_build() |
2164 | 2164 | { |
2165 | | $root = dirname(dirname(__FILE__)); |
| 2165 | $root = dirname( __DIR__); |
2166 | 2166 | if (file_exists($root . '/.git/index')) |
2167 | 2167 | { |
2168 | 2168 | return filemtime($root . '/.git/index'); |
… |
… |
public static function get_build() |
2179 | 2179 | } |
2180 | 2180 | return $time; |
2181 | 2181 | } |
2182 | | elseif (file_exists(dirname(__FILE__) . '/Core.php')) |
| 2182 | elseif (file_exists( __DIR__ . '/Core.php')) |
2183 | 2183 | { |
2184 | | return filemtime(dirname(__FILE__) . '/Core.php'); |
| 2184 | return filemtime( __DIR__ . '/Core.php'); |
2185 | 2185 | } |
2186 | 2186 | else |
2187 | 2187 | { |
-
diff --git a/src/wp-includes/Text/Diff.php b/src/wp-includes/Text/Diff.php
index edcdd3ac3a..2d3b0cdd28 100644
a
|
b
|
function __construct( $engine, $params ) |
48 | 48 | } |
49 | 49 | |
50 | 50 | // WP #7391 |
51 | | require_once dirname(__FILE__).'/Diff/Engine/' . $engine . '.php'; |
| 51 | require_once __DIR__ . '/Diff/Engine/' . $engine . '.php'; |
52 | 52 | $class = 'Text_Diff_Engine_' . $engine; |
53 | 53 | $diff_engine = new $class(); |
54 | 54 | |
-
diff --git a/src/wp-includes/Text/Diff/Renderer/inline.php b/src/wp-includes/Text/Diff/Renderer/inline.php
index 392bd57cff..203583f367 100644
a
|
b
|
|
14 | 14 | /** Text_Diff_Renderer */ |
15 | 15 | |
16 | 16 | // WP #7391 |
17 | | require_once dirname(dirname(__FILE__)) . '/Renderer.php'; |
| 17 | require_once dirname( __DIR__) . '/Renderer.php'; |
18 | 18 | |
19 | 19 | /** |
20 | 20 | * "Inline" diff renderer. |
-
diff --git a/src/wp-includes/class-phpmailer.php b/src/wp-includes/class-phpmailer.php
index 8772db2842..b7c1338b75 100644
a
|
b
|
public function setLanguage($langcode = 'en', $lang_path = '') |
1796 | 1796 | ); |
1797 | 1797 | if (empty($lang_path)) { |
1798 | 1798 | // Calculate an absolute path so it can work if CWD is not here |
1799 | | $lang_path = dirname(__FILE__). DIRECTORY_SEPARATOR . 'language'. DIRECTORY_SEPARATOR; |
| 1799 | $lang_path = __DIR__ . DIRECTORY_SEPARATOR . 'language' . DIRECTORY_SEPARATOR; |
1800 | 1800 | } |
1801 | 1801 | //Validate $langcode |
1802 | 1802 | if (!preg_match('/^[a-z]{2}(?:_[a-zA-Z]{2})?$/', $langcode)) { |
-
diff --git a/src/wp-includes/class-requests.php b/src/wp-includes/class-requests.php
index bb266189c1..030d5d1311 100644
a
|
b
|
public static function autoloader($class) { |
142 | 142 | } |
143 | 143 | |
144 | 144 | $file = str_replace('_', '/', $class); |
145 | | if (file_exists(dirname(__FILE__) . '/' . $file . '.php')) { |
146 | | require_once(dirname(__FILE__) . '/' . $file . '.php'); |
| 145 | if (file_exists( __DIR__ . '/' . $file . '.php')) { |
| 146 | require_once( __DIR__ . '/' . $file . '.php'); |
147 | 147 | } |
148 | 148 | } |
149 | 149 | |
… |
… |
public static function get_certificate_path() { |
537 | 537 | return Requests::$certificate_path; |
538 | 538 | } |
539 | 539 | |
540 | | return dirname(__FILE__) . '/Requests/Transport/cacert.pem'; |
| 540 | return __DIR__ . '/Requests/Transport/cacert.pem'; |
541 | 541 | } |
542 | 542 | |
543 | 543 | /** |
-
diff --git a/src/wp-includes/ms-files.php b/src/wp-includes/ms-files.php
index 0f2c0798c8..07f8695a53 100644
a
|
b
|
|
9 | 9 | */ |
10 | 10 | |
11 | 11 | define( 'SHORTINIT', true ); |
12 | | require_once( dirname( dirname( __FILE__ ) ) . '/wp-load.php' ); |
| 12 | require_once(dirname( __DIR__) . '/wp-load.php' ); |
13 | 13 | |
14 | 14 | if ( ! is_multisite() ) { |
15 | 15 | die( 'Multisite support not enabled' ); |
-
diff --git a/src/wp-includes/plugin.php b/src/wp-includes/plugin.php
index 1f6cacd5b4..047f8b8c77 100644
a
|
b
|
|
22 | 22 | */ |
23 | 23 | |
24 | 24 | // Initialize the filter globals. |
25 | | require( dirname( __FILE__ ) . '/class-wp-hook.php' ); |
| 25 | require( __DIR__ . '/class-wp-hook.php' ); |
26 | 26 | |
27 | 27 | /** @var WP_Hook[] $wp_filter */ |
28 | 28 | global $wp_filter, $wp_actions, $wp_current_filter; |
-
diff --git a/src/wp-includes/pomo/mo.php b/src/wp-includes/pomo/mo.php
index 836af801cd..324aa3f4fe 100644
a
|
b
|
|
7 | 7 | * @subpackage mo |
8 | 8 | */ |
9 | 9 | |
10 | | require_once dirname( __FILE__ ) . '/translations.php'; |
11 | | require_once dirname( __FILE__ ) . '/streams.php'; |
| 10 | require_once __DIR__ . '/translations.php'; |
| 11 | require_once __DIR__ . '/streams.php'; |
12 | 12 | |
13 | 13 | if ( ! class_exists( 'MO', false ) ) : |
14 | 14 | class MO extends Gettext_Translations { |
-
diff --git a/src/wp-includes/pomo/po.php b/src/wp-includes/pomo/po.php
index f5ddf5f4eb..88fe3774ad 100644
a
|
b
|
|
7 | 7 | * @subpackage po |
8 | 8 | */ |
9 | 9 | |
10 | | require_once dirname( __FILE__ ) . '/translations.php'; |
| 10 | require_once __DIR__ . '/translations.php'; |
11 | 11 | |
12 | 12 | if ( ! defined( 'PO_MAX_LINE_LEN' ) ) { |
13 | 13 | define( 'PO_MAX_LINE_LEN', 79 ); |
-
diff --git a/src/wp-includes/pomo/translations.php b/src/wp-includes/pomo/translations.php
index be9081a2fc..cb65dcdf62 100644
a
|
b
|
|
7 | 7 | * @subpackage translations |
8 | 8 | */ |
9 | 9 | |
10 | | require_once dirname( __FILE__ ) . '/plural-forms.php'; |
11 | | require_once dirname( __FILE__ ) . '/entry.php'; |
| 10 | require_once __DIR__ . '/plural-forms.php'; |
| 11 | require_once __DIR__ . '/entry.php'; |
12 | 12 | |
13 | 13 | if ( ! class_exists( 'Translations', false ) ) : |
14 | 14 | class Translations { |
-
diff --git a/src/wp-includes/random_compat/random.php b/src/wp-includes/random_compat/random.php
index df74c8a4b6..eda52041ad 100644
a
|
b
|
|
52 | 52 | define('RANDOM_COMPAT_READ_BUFFER', 8); |
53 | 53 | } |
54 | 54 | |
55 | | $RandomCompatDIR = dirname(__FILE__); |
| 55 | $RandomCompatDIR = __DIR__; |
56 | 56 | |
57 | 57 | require_once $RandomCompatDIR . '/byte_safe_strings.php'; |
58 | 58 | require_once $RandomCompatDIR . '/cast_to_int.php'; |
-
diff --git a/src/wp-includes/sodium_compat/autoload.php b/src/wp-includes/sodium_compat/autoload.php
index de2683daee..a3d1824253 100644
a
|
b
|
function sodiumCompatAutoloader($class) |
24 | 24 | // Replace the namespace prefix with the base directory, replace namespace |
25 | 25 | // separators with directory separators in the relative class name, append |
26 | 26 | // with .php |
27 | | $file = dirname(__FILE__) . '/src/' . str_replace('_', '/', $relative_class) . '.php'; |
| 27 | $file = __DIR__ . '/src/' . str_replace('_', '/', $relative_class) . '.php'; |
28 | 28 | // if the file exists, require it |
29 | 29 | if (file_exists($file)) { |
30 | 30 | require_once $file; |
… |
… |
function sodiumCompatAutoloader($class) |
37 | 37 | spl_autoload_register('sodiumCompatAutoloader'); |
38 | 38 | } |
39 | 39 | |
40 | | require_once dirname(__FILE__) . '/src/SodiumException.php'; |
| 40 | require_once __DIR__ . '/src/SodiumException.php'; |
41 | 41 | if (PHP_VERSION_ID >= 50300) { |
42 | 42 | // Namespaces didn't exist before 5.3.0, so don't even try to use this |
43 | 43 | // unless PHP >= 5.3.0 |
44 | | require_once dirname(__FILE__) . '/lib/namespaced.php'; |
45 | | require_once dirname(__FILE__) . '/lib/sodium_compat.php'; |
| 44 | require_once __DIR__ . '/lib/namespaced.php'; |
| 45 | require_once __DIR__ . '/lib/sodium_compat.php'; |
46 | 46 | } |
47 | 47 | if (PHP_VERSION_ID < 70200 || !extension_loaded('sodium')) { |
48 | | require_once dirname(__FILE__) . '/lib/php72compat.php'; |
| 48 | require_once __DIR__ . '/lib/php72compat.php'; |
49 | 49 | } |
-
diff --git a/src/wp-includes/sodium_compat/lib/sodium_compat.php b/src/wp-includes/sodium_compat/lib/sodium_compat.php
index ec5e5b5b51..c72d1de0e4 100644
a
|
b
|
function randombytes_random16() |
820 | 820 | } |
821 | 821 | |
822 | 822 | if (!defined('\\Sodium\\CRYPTO_AUTH_BYTES')) { |
823 | | require_once dirname(__FILE__) . '/constants.php'; |
| 823 | require_once __DIR__ . '/constants.php'; |
824 | 824 | } |
-
diff --git a/src/wp-includes/widgets/class-wp-widget-text.php b/src/wp-includes/widgets/class-wp-widget-text.php
index 642556ce99..fdb83112fb 100644
a
|
b
|
public function update( $new_instance, $old_instance ) { |
417 | 417 | * @since 4.9.3 |
418 | 418 | */ |
419 | 419 | public function enqueue_preview_scripts() { |
420 | | require_once dirname( dirname( __FILE__ ) ) . '/media.php'; |
| 420 | require_once dirname( __DIR__) . '/media.php'; |
421 | 421 | |
422 | 422 | wp_playlist_scripts( 'audio' ); |
423 | 423 | wp_playlist_scripts( 'video' ); |
-
diff --git a/src/wp-links-opml.php b/src/wp-links-opml.php
index 12d35b008a..536cbe8488 100644
a
|
b
|
|
12 | 12 | * @package WordPress |
13 | 13 | */ |
14 | 14 | |
15 | | require_once( dirname( __FILE__ ) . '/wp-load.php' ); |
| 15 | require_once( __DIR__ . '/wp-load.php' ); |
16 | 16 | |
17 | 17 | header( 'Content-Type: text/xml; charset=' . get_option( 'blog_charset' ), true ); |
18 | 18 | $link_cat = ''; |
-
diff --git a/src/wp-load.php b/src/wp-load.php
index 2b8830b580..9a2ad60ec3 100644
a
|
b
|
|
18 | 18 | |
19 | 19 | /** Define ABSPATH as this file's directory */ |
20 | 20 | if ( ! defined( 'ABSPATH' ) ) { |
21 | | define( 'ABSPATH', dirname( __FILE__ ) . '/' ); |
| 21 | define( 'ABSPATH', __DIR__ . '/' ); |
22 | 22 | } |
23 | 23 | |
24 | 24 | error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR ); |
-
diff --git a/src/wp-login.php b/src/wp-login.php
index c57f0a26ce..f90ca5839f 100644
a
|
b
|
|
9 | 9 | */ |
10 | 10 | |
11 | 11 | /** Make sure that the WordPress bootstrap has run before continuing. */ |
12 | | require( dirname( __FILE__ ) . '/wp-load.php' ); |
| 12 | require( __DIR__ . '/wp-load.php' ); |
13 | 13 | |
14 | 14 | // Redirect to HTTPS login if forced to use SSL. |
15 | 15 | if ( force_ssl_admin() && ! is_ssl() ) { |
-
diff --git a/src/wp-mail.php b/src/wp-mail.php
index 00a296bf3a..1588b89f4d 100644
a
|
b
|
|
8 | 8 | */ |
9 | 9 | |
10 | 10 | /** Make sure that the WordPress bootstrap has run before continuing. */ |
11 | | require( dirname( __FILE__ ) . '/wp-load.php' ); |
| 11 | require( __DIR__ . '/wp-load.php' ); |
12 | 12 | |
13 | 13 | /** This filter is documented in wp-admin/options.php */ |
14 | 14 | if ( ! apply_filters( 'enable_post_by_email_configuration', true ) ) { |
-
diff --git a/src/wp-signup.php b/src/wp-signup.php
index 8457c7059e..c73904373e 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | 3 | /** Sets up the WordPress Environment. */ |
4 | | require( dirname( __FILE__ ) . '/wp-load.php' ); |
| 4 | require( __DIR__ . '/wp-load.php' ); |
5 | 5 | |
6 | 6 | add_action( 'wp_head', 'wp_no_robots' ); |
7 | 7 | |
8 | | require( dirname( __FILE__ ) . '/wp-blog-header.php' ); |
| 8 | require( __DIR__ . '/wp-blog-header.php' ); |
9 | 9 | |
10 | 10 | nocache_headers(); |
11 | 11 | |
-
diff --git a/src/wp-trackback.php b/src/wp-trackback.php
index 6bc8495a9f..ae40ded7ec 100644
a
|
b
|
|
9 | 9 | */ |
10 | 10 | |
11 | 11 | if ( empty( $wp ) ) { |
12 | | require_once( dirname( __FILE__ ) . '/wp-load.php' ); |
| 12 | require_once( __DIR__ . '/wp-load.php' ); |
13 | 13 | wp( array( 'tb' => '1' ) ); |
14 | 14 | } |
15 | 15 | |
-
diff --git a/src/xmlrpc.php b/src/xmlrpc.php
index b36b21e951..20bbb8bab5 100644
a
|
b
|
|
27 | 27 | } |
28 | 28 | |
29 | 29 | /** Include the bootstrap for setting up WordPress environment */ |
30 | | include( dirname( __FILE__ ) . '/wp-load.php' ); |
| 30 | include( __DIR__ . '/wp-load.php' ); |
31 | 31 | |
32 | 32 | if ( isset( $_GET['rsd'] ) ) { // http://cyber.law.harvard.edu/blogs/gems/tech/rsd.html |
33 | 33 | header( 'Content-Type: text/xml; charset=' . get_option( 'blog_charset' ), true ); |
-
diff --git a/tests/phpunit/data/themedir1/camelCase/index.php b/tests/phpunit/data/themedir1/camelCase/index.php
index 93de08260b..2f83cff6bd 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
-
diff --git a/tests/phpunit/data/themedir1/sandbox/functions.php b/tests/phpunit/data/themedir1/sandbox/functions.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/data/themedir1/sandbox/index.php b/tests/phpunit/data/themedir1/sandbox/index.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/data/themedir1/theme1-dupe/functions.php b/tests/phpunit/data/themedir1/theme1-dupe/functions.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/data/themedir1/theme1-dupe/index.php b/tests/phpunit/data/themedir1/theme1-dupe/index.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/data/themedir1/theme1/functions.php b/tests/phpunit/data/themedir1/theme1/functions.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/data/themedir1/theme1/index.php b/tests/phpunit/data/themedir1/theme1/index.php
index 1c8413d3a1..d26884a98f 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | // dummy theme |
4 | 4 | |
5 | | echo dirname(__FILE__).'/'.basename(__FILE__); |
| 5 | echo __DIR__ . '/' . basename(__FILE__); |
6 | 6 | |
7 | 7 | ?> |
-
diff --git a/tests/phpunit/includes/abstract-testcase.php b/tests/phpunit/includes/abstract-testcase.php
index f1c08657cb..159afe5eb3 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/factory.php'; |
4 | | require_once dirname( __FILE__ ) . '/trac.php'; |
| 3 | require_once __DIR__ . '/factory.php'; |
| 4 | require_once __DIR__ . '/trac.php'; |
5 | 5 | |
6 | 6 | /** |
7 | 7 | * Defines a basic fixture to run multiple tests. |
-
diff --git a/tests/phpunit/includes/bootstrap.php b/tests/phpunit/includes/bootstrap.php
index 68e8b60792..4bd443be11 100644
a
|
b
|
|
7 | 7 | * Compatibility with PHPUnit 6+ |
8 | 8 | */ |
9 | 9 | if ( class_exists( 'PHPUnit\Runner\Version' ) ) { |
10 | | require_once dirname( __FILE__ ) . '/phpunit6/compat.php'; |
| 10 | require_once __DIR__ . '/phpunit6/compat.php'; |
11 | 11 | } |
12 | 12 | |
13 | 13 | if ( defined( 'WP_TESTS_CONFIG_FILE_PATH' ) ) { |
14 | 14 | $config_file_path = WP_TESTS_CONFIG_FILE_PATH; |
15 | 15 | } else { |
16 | | $config_file_path = dirname( dirname( __FILE__ ) ); |
| 16 | $config_file_path = dirname( __DIR__); |
17 | 17 | if ( ! file_exists( $config_file_path . '/wp-tests-config.php' ) ) { |
18 | 18 | // Support the config file from the root of the develop repository. |
19 | 19 | if ( basename( $config_file_path ) === 'phpunit' && basename( dirname( $config_file_path ) ) === 'tests' ) { |
… |
… |
|
35 | 35 | } |
36 | 36 | |
37 | 37 | require_once $config_file_path; |
38 | | require_once dirname( __FILE__ ) . '/functions.php'; |
| 38 | require_once __DIR__ . '/functions.php'; |
39 | 39 | |
40 | 40 | if ( version_compare( tests_get_phpunit_version(), '8.0', '>=' ) ) { |
41 | 41 | printf( |
… |
… |
|
54 | 54 | tests_reset__SERVER(); |
55 | 55 | |
56 | 56 | define( 'WP_TESTS_TABLE_PREFIX', $table_prefix ); |
57 | | define( 'DIR_TESTDATA', dirname( __FILE__ ) . '/../data' ); |
58 | | define( 'DIR_TESTROOT', realpath( dirname( dirname( __FILE__ ) ) ) ); |
| 57 | define( 'DIR_TESTDATA', __DIR__ . '/../data' ); |
| 58 | define( 'DIR_TESTROOT', realpath( dirname( __DIR__) ) ); |
59 | 59 | |
60 | 60 | define( 'WP_LANG_DIR', DIR_TESTDATA . '/languages' ); |
61 | 61 | |
… |
… |
|
81 | 81 | $multisite = $multisite || ( defined( 'MULTISITE' ) && MULTISITE ); |
82 | 82 | |
83 | 83 | // Override the PHPMailer |
84 | | require_once( dirname( __FILE__ ) . '/mock-mailer.php' ); |
| 84 | require_once( __DIR__ . '/mock-mailer.php' ); |
85 | 85 | $phpmailer = new MockPHPMailer( true ); |
86 | 86 | |
87 | 87 | if ( ! defined( 'WP_DEFAULT_THEME' ) ) { |
… |
… |
|
94 | 94 | } |
95 | 95 | |
96 | 96 | if ( '1' !== getenv( 'WP_TESTS_SKIP_INSTALL' ) ) { |
97 | | system( WP_PHP_BINARY . ' ' . escapeshellarg( dirname( __FILE__ ) . '/install.php' ) . ' ' . escapeshellarg( $config_file_path ) . ' ' . $multisite, $retval ); |
| 97 | system( WP_PHP_BINARY . ' ' . escapeshellarg( __DIR__ . '/install.php' ) . ' ' . escapeshellarg( $config_file_path ) . ' ' . $multisite, $retval ); |
98 | 98 | if ( 0 !== $retval ) { |
99 | 99 | exit( $retval ); |
100 | 100 | } |
… |
… |
function wp_tests_options( $value ) { |
136 | 136 | _delete_all_posts(); |
137 | 137 | |
138 | 138 | if ( version_compare( tests_get_phpunit_version(), '7.0', '>=' ) ) { |
139 | | require dirname( __FILE__ ) . '/phpunit7/testcase.php'; |
| 139 | require __DIR__ . '/phpunit7/testcase.php'; |
140 | 140 | } else { |
141 | | require dirname( __FILE__ ) . '/testcase.php'; |
| 141 | require __DIR__ . '/testcase.php'; |
142 | 142 | } |
143 | 143 | |
144 | | require dirname( __FILE__ ) . '/testcase-rest-api.php'; |
145 | | require dirname( __FILE__ ) . '/testcase-rest-controller.php'; |
146 | | require dirname( __FILE__ ) . '/testcase-rest-post-type-controller.php'; |
147 | | require dirname( __FILE__ ) . '/testcase-xmlrpc.php'; |
148 | | require dirname( __FILE__ ) . '/testcase-ajax.php'; |
149 | | require dirname( __FILE__ ) . '/testcase-canonical.php'; |
150 | | require dirname( __FILE__ ) . '/exceptions.php'; |
151 | | require dirname( __FILE__ ) . '/utils.php'; |
152 | | require dirname( __FILE__ ) . '/spy-rest-server.php'; |
153 | | require dirname( __FILE__ ) . '/class-wp-rest-test-search-handler.php'; |
154 | | require dirname( __FILE__ ) . '/class-wp-fake-block-type.php'; |
| 144 | require __DIR__ . '/testcase-rest-api.php'; |
| 145 | require __DIR__ . '/testcase-rest-controller.php'; |
| 146 | require __DIR__ . '/testcase-rest-post-type-controller.php'; |
| 147 | require __DIR__ . '/testcase-xmlrpc.php'; |
| 148 | require __DIR__ . '/testcase-ajax.php'; |
| 149 | require __DIR__ . '/testcase-canonical.php'; |
| 150 | require __DIR__ . '/exceptions.php'; |
| 151 | require __DIR__ . '/utils.php'; |
| 152 | require __DIR__ . '/spy-rest-server.php'; |
| 153 | require __DIR__ . '/class-wp-rest-test-search-handler.php'; |
| 154 | require __DIR__ . '/class-wp-fake-block-type.php'; |
155 | 155 | |
156 | 156 | /** |
157 | 157 | * A class to handle additional command line arguments passed to the script. |
-
diff --git a/tests/phpunit/includes/factory.php b/tests/phpunit/includes/factory.php
index 91d7da750e..7c98853219 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-thing.php' ); |
4 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-post.php' ); |
5 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-bookmark.php' ); |
6 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-attachment.php' ); |
7 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-user.php' ); |
8 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-comment.php' ); |
9 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-blog.php' ); |
10 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-network.php' ); |
11 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-for-term.php' ); |
12 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-generator-sequence.php' ); |
13 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory-callback-after-create.php' ); |
14 | | require_once( dirname( __FILE__ ) . '/factory/class-wp-unittest-factory.php' ); |
| 3 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-thing.php' ); |
| 4 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-post.php' ); |
| 5 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-bookmark.php' ); |
| 6 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-attachment.php' ); |
| 7 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-user.php' ); |
| 8 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-comment.php' ); |
| 9 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-blog.php' ); |
| 10 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-network.php' ); |
| 11 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-for-term.php' ); |
| 12 | require_once( __DIR__ . '/factory/class-wp-unittest-generator-sequence.php' ); |
| 13 | require_once( __DIR__ . '/factory/class-wp-unittest-factory-callback-after-create.php' ); |
| 14 | require_once( __DIR__ . '/factory/class-wp-unittest-factory.php' ); |
-
diff --git a/tests/phpunit/includes/install.php b/tests/phpunit/includes/install.php
index d07079e501..d493d343ef 100644
a
|
b
|
|
11 | 11 | |
12 | 12 | define( 'WP_INSTALLING', true ); |
13 | 13 | require_once $config_file_path; |
14 | | require_once dirname( __FILE__ ) . '/functions.php'; |
| 14 | require_once __DIR__ . '/functions.php'; |
15 | 15 | |
16 | 16 | // Set the theme to our special empty theme, to avoid interference from the current Twenty* theme. |
17 | 17 | if ( ! defined( 'WP_DEFAULT_THEME' ) ) { |
… |
… |
|
33 | 33 | |
34 | 34 | // Override the PHPMailer |
35 | 35 | global $phpmailer; |
36 | | require_once( dirname( __FILE__ ) . '/mock-mailer.php' ); |
| 36 | require_once( __DIR__ . '/mock-mailer.php' ); |
37 | 37 | $phpmailer = new MockPHPMailer(); |
38 | 38 | |
39 | | register_theme_directory( dirname( __FILE__ ) . '/../data/themedir1' ); |
| 39 | register_theme_directory( __DIR__ . '/../data/themedir1' ); |
40 | 40 | |
41 | 41 | /* |
42 | 42 | * default_storage_engine and storage_engine are the same option, but storage_engine |
-
diff --git a/tests/phpunit/includes/listener-loader.php b/tests/phpunit/includes/listener-loader.php
index 3e3731f98b..1f86fefc06 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | 3 | if ( version_compare( tests_get_phpunit_version(), '7.0', '>=' ) ) { |
4 | | require dirname( __FILE__ ) . '/phpunit7/speed-trap-listener.php'; |
| 4 | require __DIR__ . '/phpunit7/speed-trap-listener.php'; |
5 | 5 | } else { |
6 | | require dirname( __FILE__ ) . '/speed-trap-listener.php'; |
| 6 | require __DIR__ . '/speed-trap-listener.php'; |
7 | 7 | } |
-
diff --git a/tests/phpunit/includes/phpunit7/testcase.php b/tests/phpunit/includes/phpunit7/testcase.php
index 9edc885e6a..071c31491a 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( dirname( __FILE__ ) ) . '/abstract-testcase.php'; |
| 3 | require_once dirname( __DIR__) . '/abstract-testcase.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Defines a basic fixture to run multiple tests. |
-
diff --git a/tests/phpunit/includes/testcase.php b/tests/phpunit/includes/testcase.php
index 964af64ca3..7689d0e48c 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/abstract-testcase.php'; |
| 3 | require_once __DIR__ . '/abstract-testcase.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Defines a basic fixture to run multiple tests. |
-
diff --git a/tests/phpunit/tests/canonical/noRewrite.php b/tests/phpunit/tests/canonical/noRewrite.php
index 0c2a027cfc..0251baa51f 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( dirname( __FILE__ ) ) . '/canonical.php'; |
| 3 | require_once dirname( __DIR__) . '/canonical.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group canonical |
-
diff --git a/tests/phpunit/tests/db/charset.php b/tests/phpunit/tests/db/charset.php
index 3089ec9a74..dd7d518bf6 100644
a
|
b
|
class Tests_DB_Charset extends WP_UnitTestCase { |
25 | 25 | public static function setUpBeforeClass() { |
26 | 26 | parent::setUpBeforeClass(); |
27 | 27 | |
28 | | require_once( dirname( dirname( __FILE__ ) ) . '/db.php' ); |
| 28 | require_once(dirname( __DIR__) . '/db.php' ); |
29 | 29 | |
30 | 30 | self::$_wpdb = new WpdbExposedMethodsForTesting(); |
31 | 31 | |
-
diff --git a/tests/phpunit/tests/filesystem/base.php b/tests/phpunit/tests/filesystem/base.php
index 356be3c9e0..4d63fdd99e 100644
a
|
b
|
function filter_fs_method( $method ) { |
24 | 24 | return 'MockFS'; |
25 | 25 | } |
26 | 26 | function filter_abstraction_file( $file ) { |
27 | | return dirname( dirname( dirname( __FILE__ ) ) ) . '/includes/mock-fs.php'; |
| 27 | return dirname( dirname( __DIR__) ) . '/includes/mock-fs.php'; |
28 | 28 | } |
29 | 29 | |
30 | 30 | function test_is_MockFS_sane() { |
-
diff --git a/tests/phpunit/tests/filesystem/findFolder.php b/tests/phpunit/tests/filesystem/findFolder.php
index 9f754a7c55..903c6af9b7 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group filesystem |
-
diff --git a/tests/phpunit/tests/http/curl.php b/tests/phpunit/tests/http/curl.php
index f64cace2b7..271e6dd698 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group http |
-
diff --git a/tests/phpunit/tests/http/streams.php b/tests/phpunit/tests/http/streams.php
index 2c6922f901..61fcc11925 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group http |
-
diff --git a/tests/phpunit/tests/image/editor.php b/tests/phpunit/tests/image/editor.php
index 35242ad3e0..888d9dc1f4 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * Test the WP_Image_Editor base class |
-
diff --git a/tests/phpunit/tests/image/editorGd.php b/tests/phpunit/tests/image/editorGd.php
index fdd0e9c96a..5bbe4d2478 100644
a
|
b
|
|
7 | 7 | * @group media |
8 | 8 | * @group wp-image-editor-gd |
9 | 9 | */ |
10 | | require_once( dirname( __FILE__ ) . '/base.php' ); |
| 10 | require_once( __DIR__ . '/base.php' ); |
11 | 11 | |
12 | 12 | class Tests_Image_Editor_GD extends WP_Image_UnitTestCase { |
13 | 13 | |
-
diff --git a/tests/phpunit/tests/image/editorImagick.php b/tests/phpunit/tests/image/editorImagick.php
index ac531ff942..e8ff8ecc9a 100644
a
|
b
|
|
7 | 7 | * @group media |
8 | 8 | * @group wp-image-editor-imagick |
9 | 9 | */ |
10 | | require_once( dirname( __FILE__ ) . '/base.php' ); |
| 10 | require_once( __DIR__ . '/base.php' ); |
11 | 11 | |
12 | 12 | class Tests_Image_Editor_Imagick extends WP_Image_UnitTestCase { |
13 | 13 | |
-
diff --git a/tests/phpunit/tests/image/resize.php b/tests/phpunit/tests/image/resize.php
index 2cbd5a2505..2df3b3c25c 100644
a
|
b
|
|
6 | 6 | * @group upload |
7 | 7 | * @group resize |
8 | 8 | */ |
9 | | require_once( dirname( __FILE__ ) . '/base.php' ); |
| 9 | require_once( __DIR__ . '/base.php' ); |
10 | 10 | |
11 | 11 | abstract class WP_Tests_Image_Resize_UnitTestCase extends WP_Image_UnitTestCase { |
12 | 12 | |
-
diff --git a/tests/phpunit/tests/image/resizeGd.php b/tests/phpunit/tests/image/resizeGd.php
index 5d1c614c34..37a2282ca6 100644
a
|
b
|
|
6 | 6 | * @group upload |
7 | 7 | * @group resize |
8 | 8 | */ |
9 | | require_once( dirname( __FILE__ ) . '/resize.php' ); |
| 9 | require_once( __DIR__ . '/resize.php' ); |
10 | 10 | |
11 | 11 | class Test_Image_Resize_GD extends WP_Tests_Image_Resize_UnitTestCase { |
12 | 12 | |
-
diff --git a/tests/phpunit/tests/image/resizeImagick.php b/tests/phpunit/tests/image/resizeImagick.php
index d611e38e14..dd424be2bd 100644
a
|
b
|
|
6 | 6 | * @group upload |
7 | 7 | * @group resize |
8 | 8 | */ |
9 | | require_once( dirname( __FILE__ ) . '/resize.php' ); |
| 9 | require_once( __DIR__ . '/resize.php' ); |
10 | 10 | |
11 | 11 | class Test_Image_Resize_Imagick extends WP_Tests_Image_Resize_UnitTestCase { |
12 | 12 | |
-
diff --git a/tests/phpunit/tests/import/import.php b/tests/phpunit/tests/import/import.php
index e005826a18..88dee19985 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group import |
-
diff --git a/tests/phpunit/tests/import/parser.php b/tests/phpunit/tests/import/parser.php
index 8b198f31e4..be7b141d27 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group import |
-
diff --git a/tests/phpunit/tests/import/postmeta.php b/tests/phpunit/tests/import/postmeta.php
index dcae22d0bd..e712531ea2 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/base.php'; |
| 3 | require_once __DIR__ . '/base.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group import |
-
diff --git a/tests/phpunit/tests/pomo/pluralForms.php b/tests/phpunit/tests/pomo/pluralForms.php
index 2cd283cf95..ce69704d0f 100644
a
|
b
|
public function test_regression( $lang, $nplurals, $expression ) { |
78 | 78 | $this->markTestSkipped( 'Lambda functions are deprecated in PHP 7.2' ); |
79 | 79 | } |
80 | 80 | |
81 | | require_once dirname( dirname( dirname( __FILE__ ) ) ) . '/includes/plural-form-function.php'; |
| 81 | require_once dirname( dirname( __DIR__) ) . '/includes/plural-form-function.php'; |
82 | 82 | |
83 | 83 | $parenthesized = self::parenthesize_plural_expression( $expression ); |
84 | 84 | $old_style = tests_make_plural_form_function( $nplurals, $parenthesized ); |
-
diff --git a/tests/phpunit/tests/query/verboseRewriteRules.php b/tests/phpunit/tests/query/verboseRewriteRules.php
index 5414a51a9a..88f2ef38ac 100644
a
|
b
|
|
1 | 1 | <?php |
2 | 2 | |
3 | | require_once dirname( __FILE__ ) . '/conditionals.php'; |
| 3 | require_once __DIR__ . '/conditionals.php'; |
4 | 4 | |
5 | 5 | /** |
6 | 6 | * @group query |
-
diff --git a/tests/phpunit/wp-mail-real-test.php b/tests/phpunit/wp-mail-real-test.php
index 67da30ef86..6a91067235 100644
a
|
b
|
|
10 | 10 | if ( is_callable( 'getopt' ) ) { |
11 | 11 | $opts = getopt( $options ); |
12 | 12 | } else { |
13 | | include( dirname( __FILE__ ) . '/wp-testlib/getopt.php' ); |
| 13 | include( __DIR__ . '/wp-testlib/getopt.php' ); |
14 | 14 | $opts = getoptParser::getopt( $options ); |
15 | 15 | } |
16 | 16 | |
17 | | define( 'DIR_TESTROOT', realpath( dirname( __FILE__ ) ) ); |
| 17 | define( 'DIR_TESTROOT', realpath( __DIR__) ); |
18 | 18 | |
19 | 19 | define( 'TEST_WP', true ); |
20 | 20 | define( 'WP_DEBUG', array_key_exists( 'd', $opts ) ); |
-
diff --git a/wp-config-sample.php b/wp-config-sample.php
index ed8f9fc0e5..bd4a63cc5c 100644
a
|
b
|
|
83 | 83 | |
84 | 84 | /** Absolute path to the WordPress directory. */ |
85 | 85 | if ( ! defined( 'ABSPATH' ) ) { |
86 | | define( 'ABSPATH', dirname( __FILE__ ) . '/' ); |
| 86 | define( 'ABSPATH', __DIR__ . '/' ); |
87 | 87 | } |
88 | 88 | |
89 | 89 | /** Sets up WordPress vars and included files. */ |
-
diff --git a/wp-tests-config-sample.php b/wp-tests-config-sample.php
index 2f6c515912..7a030d25fb 100644
a
|
b
|
|
2 | 2 | |
3 | 3 | /* Path to the WordPress codebase you'd like to test. Add a forward slash in the end. */ |
4 | 4 | if ( defined( 'WP_RUN_CORE_TESTS' ) && WP_RUN_CORE_TESTS ) { |
5 | | define( 'ABSPATH', dirname( __FILE__ ) . '/build/' ); |
| 5 | define( 'ABSPATH', __DIR__ . '/build/' ); |
6 | 6 | } else { |
7 | | define( 'ABSPATH', dirname( __FILE__ ) . '/src/' ); |
| 7 | define( 'ABSPATH', __DIR__ . '/src/' ); |
8 | 8 | } |
9 | 9 | |
10 | 10 | /* |