Commit Graph

47 Commits

Author SHA1 Message Date
Sergey Biryukov
86491779ec Coding Standards: Adds spacing so define() statements displayed when creating a network.
This ensures that the code intended to be copied to `wp-config.php` conforms to WordPress Coding Standards.

Props paulschreiber, johnjamesjacoby.
Fixes #53182.
Built from https://develop.svn.wordpress.org/trunk@50839


git-svn-id: http://core.svn.wordpress.org/trunk@50448 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-05-11 17:10:02 +00:00
John Blackbourn
b59c0f307b Docs: Corrections and improvements to types used in various docblocks.
See #51800, #52217

Built from https://develop.svn.wordpress.org/trunk@49936


git-svn-id: http://core.svn.wordpress.org/trunk@49635 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-01-05 17:16:11 +00:00
TimothyBlynJacobs
44125fc590 App Passwords: Include authorization rewrite rule in default multisite .htaccess
This rule was previously added to `WP_Rewrite`, but multisite uses a different .htaccess generation mechanism.

Props pbiron.
Fixes #51772.
See [49109].

Built from https://develop.svn.wordpress.org/trunk@49607


git-svn-id: http://core.svn.wordpress.org/trunk@49345 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-15 17:46:06 +00:00
Sergey Biryukov
a2d42351c5 Text Changes: Unify various "Back to..." vs. "Return to..." vs. "Go to..." strings.
Standardize on "Go to..." as a more appropriate option for most cases.

Props garrett-eclipse, kharisblank, audrasjb, ramiy, valentinbora.
Fixes #47235.
Built from https://develop.svn.wordpress.org/trunk@49539


git-svn-id: http://core.svn.wordpress.org/trunk@49277 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-11-09 10:53:10 +00:00
Andrea Fercia
ae447adaf4 I18N: Restore the "Error:" prefix for error messages.
Partially reverts [48059] as there's no full consensus on the removal of the text prefix. Further actions should be taken to improve consistency and accessibility of the admin notices. Keeps some improvements to the translatable strings from [48059].

Fixes #47656.

Built from https://develop.svn.wordpress.org/trunk@48115


git-svn-id: http://core.svn.wordpress.org/trunk@47884 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-21 14:00:09 +00:00
Sergey Biryukov
65724cf380 Docs: Correct DocBlock placement for allow_subdirectory_install filter.
See #49572.
Built from https://develop.svn.wordpress.org/trunk@48108


git-svn-id: http://core.svn.wordpress.org/trunk@47877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-20 12:24:08 +00:00
Andrea Fercia
f83c504b88 I18N: Remove the "Error:" prefix from error messages.
For a number of years, most of the WordPress error messages have been prefixed with "Error:". However, these messages appear in a context where it's already clear an error occurred. Whether it's an error, a warning, or any other classification, that's not so relevant for users. The content of the message is the relevant part. The "Error:" prefix doesn't add great value while it does add unnecessary complexity for the message readability.

Also, revises some of these messages to improve clarity and removes HTML from translatable strings.

Props garrett-eclipse, ramiy, SergeyBiryukov, afercia, sabernhardt, quadthemes, audrasjb. 
See #47003, #43037, #42945, #15887.
Fixes #47656.

Built from https://develop.svn.wordpress.org/trunk@48059


git-svn-id: http://core.svn.wordpress.org/trunk@47826 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-06-16 15:35:13 +00:00
Sergey Biryukov
3dc1e33fb5 Networks and Sites: Link to Nginx documentation on Network Setup screen when Nginx is in use.
Props lipathor, audrasjb, johnbillion, flixos90.
Fixes #41166.
Built from https://develop.svn.wordpress.org/trunk@47632


git-svn-id: http://core.svn.wordpress.org/trunk@47407 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-04-29 14:43:09 +00:00
Sergey Biryukov
38676936ba Coding Standards: Use strict type check for in_array() and array_search() where strings are involved.
This reduces the number of `WordPress.PHP.StrictInArray.MissingTrueStrict` issues from 486 to 50.

Includes minor code layout fixes for better readability.

See #49542.
Built from https://develop.svn.wordpress.org/trunk@47550


git-svn-id: http://core.svn.wordpress.org/trunk@47325 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-04-05 03:02:11 +00:00
Sergey Biryukov
47ed56f38f Code Modernization: Replace dirname( __FILE__ ) calls with __DIR__ magic constant.
This avoids the performance overhead of the function call every time `dirname( __FILE__ )` was used instead of `__DIR__`.

This commit also includes:

* Removing unnecessary parentheses from `include`/`require` statements. These are language constructs, not function calls.
* Replacing `include` statements for several files with `require_once`, for consistency:
 * `wp-admin/admin-header.php`
 * `wp-admin/admin-footer.php`
 * `wp-includes/version.php`

Props ayeshrajans, desrosj, valentinbora, jrf, joostdevalk, netweb.
Fixes #48082.
Built from https://develop.svn.wordpress.org/trunk@47198


git-svn-id: http://core.svn.wordpress.org/trunk@46998 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-06 06:33:11 +00:00
Sergey Biryukov
deb1886078 Accessibility: Text Changes: Use sentence case for the word Error in various error messages, instead of all caps.
Using all caps should be avoided for better readability and because screen readers may pronounce all-caps words as abbreviations.

Props afercia, ryokuhi, sabernhardt, garrett-eclipse.
See #47656, #43037, #42945.
Built from https://develop.svn.wordpress.org/trunk@47156


git-svn-id: http://core.svn.wordpress.org/trunk@46956 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-02-01 21:38:04 +00:00
Sergey Biryukov
037a736757 Docs: Improve comments in some wp-admin files per the documentation standards.
Follow-up to [47084].

Props passoniate, apedog.
Fixes #49223, #49227.
Built from https://develop.svn.wordpress.org/trunk@47119


git-svn-id: http://core.svn.wordpress.org/trunk@46919 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-29 00:35:08 +00:00
Sergey Biryukov
89f5d3dd0c Networks and Sites: Clarify the recommendation to remove the www prefix from the site domain before creating a network.
The `siteurl` option reference was not quite clear, and the string actually refers to the domain name, not the full URL.

Props kharisblank, tobifjellner, ramiy.
Fixes #49214.
Built from https://develop.svn.wordpress.org/trunk@47085


git-svn-id: http://core.svn.wordpress.org/trunk@46885 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-18 01:15:04 +00:00
Sergey Biryukov
f18b173674 Networks and Sites: Use warning styles for 'Caution' and 'Warning' messages during Multisite installation.
Props dlh.
Fixes #49186.
Built from https://develop.svn.wordpress.org/trunk@47067


git-svn-id: http://core.svn.wordpress.org/trunk@46867 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2020-01-13 17:00:06 +00:00
Sergey Biryukov
5b9fd2d7e7 Coding Standards: Use strict comparison in wp-admin/includes/network.php.
Props ataurr.
Fixes #48994.
Built from https://develop.svn.wordpress.org/trunk@46963


git-svn-id: http://core.svn.wordpress.org/trunk@46763 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-12-16 12:37:06 +00:00
Sergey Biryukov
e199663322 I18N: Capitalize translator comments consistently, add trailing punctuation.
Includes minor code layout fixes.

See #44360.
Built from https://develop.svn.wordpress.org/trunk@45932


git-svn-id: http://core.svn.wordpress.org/trunk@45743 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-03 00:41:05 +00:00
Sergey Biryukov
16b8d91baa I18N: Improve translator comments.
* Add missing translator comments.
* Fix placement of some translator comments. Translator comments should be on the line directly above the line containing the translation function call for optimal compatibility with various `.pot` file generation tools. The CS auto-fixing, which changed some inconsistent function calls to multi-line function calls, is part of the reason why this was no longer the case for a select group of translator comments.

Includes minor code layout fixes.

Polyglots, rejoice! All WordPress core files now have translator comments for all strings with placeholders!

Props jrf, subrataemfluence, GaryJ, webdados, Dency, swissspidy, alvarogois, marcomartins, mihaiiceyro, vladwtz, niq1982, flipkeijzer, michielatyoast, chandrapatel, thrijith, joshuanoyce, FesoVik, tessak22, bhaktirajdev, cleancoded, dhavalkasvala, garrett-eclipse, bibliofille, socalchristina, priyankkpatel, 5hel2l2y, adamsilverstein, JeffPaul, pierlo, SergeyBiryukov.
Fixes #44360.
Built from https://develop.svn.wordpress.org/trunk@45926


git-svn-id: http://core.svn.wordpress.org/trunk@45737 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-09-01 17:13:59 +00:00
Gary Pendergast
cf3fa9f7c8 Coding Standards: Fix the Squiz.PHP.DisallowMultipleAssignments violations in wp-admin.
See #47632.


Built from https://develop.svn.wordpress.org/trunk@45583


git-svn-id: http://core.svn.wordpress.org/trunk@45394 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-01 12:52:01 +00:00
Andrea Fercia
48d9d94881 Accessibility: Improve settings tables and forms after [45403].
- adds `role="presentation"` to the edit comment table 
- removes a few pointless `<fieldset>` elements
- adds a few missing `<label>` elements
- adds the CSS class `class="td-full"` to table rows spanning to multiple cells
- adds explicit `scope="row"` attribute to the table headers in `options-permalink.php`: this table is better communicated as data table 
- uses consistent label association in the "Privacy Settings" page
- in the installation page "Set up your database connection": associates descriptions to their inout fields using `aria-describedby`
- improves the link to gravatar.com in the `user-edit.php` page

See #46899.
Fixes #47390.

Built from https://develop.svn.wordpress.org/trunk@45416


git-svn-id: http://core.svn.wordpress.org/trunk@45227 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-25 15:19:53 +00:00
Sergey Biryukov
b77cf42c0b Accessibility: Make sure layout tables across the admin are correctly linearized.
Adds `role="presentation"` to the `<table>` elements used for layout purposes.

Ideally, HTML tables should be used for tabular data. When tables are used for layout purposes, it's important to remove any native semantics so that assistive technologies can correctly announce the table content in a linearized fashion.

Props greatislander, afercia.
Fixes #46899.
Built from https://develop.svn.wordpress.org/trunk@45403


git-svn-id: http://core.svn.wordpress.org/trunk@45214 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-24 21:56:54 +00:00
Sergey Biryukov
726e77d97e Networks and Sites: Readjust tabs in wp-admin/includes/network.php for (more or less) consistent alignment.
See #47062.
Built from https://develop.svn.wordpress.org/trunk@45391


git-svn-id: http://core.svn.wordpress.org/trunk@45202 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-23 23:35:52 +00:00
Sergey Biryukov
139225ad7a Networks and Sites: Remove extra whitespace in .htaccess rules on Network Setup page.
Props riddhiehta02 for initial patch, sebastienserre, masterforwordpress.
Fixes #47062.
Built from https://develop.svn.wordpress.org/trunk@45390


git-svn-id: http://core.svn.wordpress.org/trunk@45201 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-05-23 23:28:53 +00:00
Gary Pendergast
12b800788e Docs: Improve the @return description of network_domain_check().
Props ishitaka, vaishalipanchal.
Fixes #45403.


Built from https://develop.svn.wordpress.org/trunk@44460


git-svn-id: http://core.svn.wordpress.org/trunk@44291 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-08 05:27:50 +00:00
Gary Pendergast
363cfc4301 General: Replace "Happy blogging" with "Happy publishing".
As of this commit, WordPress is no longer a simple blogging platform. It's now a comprehensive publishing solution.

This also replaces a couple of other "blog" references that were missed previously.

Props igmoweb, Valer1e, audrasjb, pento.
Fixes #41000.


Built from https://develop.svn.wordpress.org/trunk@44455


git-svn-id: http://core.svn.wordpress.org/trunk@44286 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-08 04:30:50 +00:00
Gary Pendergast
56c162fbc9 Coding Standards: Upgrade WPCS to 1.0.0
WPCS 1.0.0 includes a bunch of new auto-fixers, which drops the number of coding standards issues across WordPress significantly. Prior to running the auto-fixers, there were 15,312 issues detected. With this commit, we now drop to 4,769 issues.

This change includes three notable additions:
- Multiline function calls must now put each parameter on a new line.
- Auto-formatting files is now part of the `grunt precommit` script. 
- Auto-fixable coding standards issues will now cause Travis failures.

Fixes #44600.


Built from https://develop.svn.wordpress.org/trunk@43571


git-svn-id: http://core.svn.wordpress.org/trunk@43400 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-08-17 01:51:36 +00:00
Sergey Biryukov
4848a09b35 I18N: Use the actual placeholder instead of a number in translator comments if the corresponding string does not use numbered placeholders.
Add missing translator comments in `WP_Theme_Install_List_Table` and `wp_notify_postauthor()`.
Add missing commas in some translator comments.

Fixes #43523.
Built from https://develop.svn.wordpress.org/trunk@42827


git-svn-id: http://core.svn.wordpress.org/trunk@42657 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-03-11 16:44:34 +00:00
Gary Pendergast
aaf99e6913 Code is Poetry.
WordPress' code just... wasn't.
This is now dealt with.

Props jrf, pento, netweb, GaryJ, jdgrimes, westonruter, Greg Sherwood from PHPCS, and everyone who's ever contributed to WPCS and PHPCS.
Fixes #41057.


Built from https://develop.svn.wordpress.org/trunk@42343


git-svn-id: http://core.svn.wordpress.org/trunk@42172 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-30 23:11:00 +00:00
Sergey Biryukov
d2499c4212 Network Admin: After [41923], move the second <p> tag to a new line for better readability.
See #41652.
Built from https://develop.svn.wordpress.org/trunk@41924


git-svn-id: http://core.svn.wordpress.org/trunk@41758 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 20:51:48 +00:00
Sergey Biryukov
a749494900 I18N: Remove hardcoded constant from a translatable string in network_step1().
Props ramiy.
Fixes #41652.
Built from https://develop.svn.wordpress.org/trunk@41923


git-svn-id: http://core.svn.wordpress.org/trunk@41757 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 20:02:50 +00:00
Sergey Biryukov
106beec6a7 I18N: Combine two "Warning" strings in network_step1() and network_step2().
Props ramiy.
Fixes #38570.
Built from https://develop.svn.wordpress.org/trunk@41921


git-svn-id: http://core.svn.wordpress.org/trunk@41755 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-18 19:50:47 +00:00
John Blackbourn
28eda6f4bc General: Improve terminology used when referring to installations of WordPress and its extensions.
"Install" is not a noun, and while it might be acceptable to use the verb as a noun, it is not correct. Using the correct
noun, "installation", increases clarity, especially for non-native English speakers.

This change fixes the usage in user-facing text and in developer documentation.

Fixes #41620

Built from https://develop.svn.wordpress.org/trunk@41289


git-svn-id: http://core.svn.wordpress.org/trunk@41129 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-08-22 11:52:48 +00:00
Sergey Biryukov
fee26cf741 I18N: Replace unnecessary context with a translator comment for %s Sites string in network_step1().
Props ramiy.
Fixes #37777.
Built from https://develop.svn.wordpress.org/trunk@38323


git-svn-id: http://core.svn.wordpress.org/trunk@38264 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-08-23 00:17:27 +00:00
Dominik Schilling
a288544c41 I18N: Make "That's all, stop editing! Happy blogging." translatable.
The string is used during the network installation process to inform the user about where to store additional configuration data. Since the wp-config.php file can be translated the string should be too.

Props julesaus.
Fixes #36945.
Built from https://develop.svn.wordpress.org/trunk@37902


git-svn-id: http://core.svn.wordpress.org/trunk@37843 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-28 23:24:27 +00:00
Peter Wilson
47d26cd9fb DOCS: Replace HTTP links with HTTPS.
Replaces unsecure links in documentation and translator comments with their secure versions.

Props johnpgreen, netweb

Fixes #36993

Built from https://develop.svn.wordpress.org/trunk@37674


git-svn-id: http://core.svn.wordpress.org/trunk@37640 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-10 04:50:33 +00:00
Drew Jaynes
c3055cc190 Docs: Standardize hook docs in wp-admin/* to use third-person singular verbs per the inline documentation standards for PHP.
See #36913.

Built from https://develop.svn.wordpress.org/trunk@37488


git-svn-id: http://core.svn.wordpress.org/trunk@37456 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-22 18:01:30 +00:00
Sergey Biryukov
6f2fbfb28b I18N: Move the "Caution:" prefix to a separate string in wp-admin/includes/network.php.
Props ramiy.
Fixes #35674.
Built from https://develop.svn.wordpress.org/trunk@36690


git-svn-id: http://core.svn.wordpress.org/trunk@36657 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-02-24 18:40:26 +00:00
Pascal Birchler
4a6d77c8e5 Docs: Correct a parameter name for the allow_subdirectory_install filter.
See #32246.
Built from https://develop.svn.wordpress.org/trunk@35971


git-svn-id: http://core.svn.wordpress.org/trunk@35936 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-12-16 19:32:26 +00:00
Sergey Biryukov
cbe0cad509 Remove <code> tags from translatable strings in wp-admin/includes/network.php.
Add translator comments.

Props ramiy.
Fixes #34598.
Built from https://develop.svn.wordpress.org/trunk@35552


git-svn-id: http://core.svn.wordpress.org/trunk@35516 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-11-06 00:59:25 +00:00
Drew Jaynes
217b661703 Docs: Add missing descriptions for the $wpdb global in DocBlocks all the places.
See #32246.

Built from https://develop.svn.wordpress.org/trunk@35170


git-svn-id: http://core.svn.wordpress.org/trunk@35136 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-14 23:44:25 +00:00
Jeremy Felt
9926983b66 Revert [34778], continue using _site_option() for the current network.
The `_network_option()` parameter order will be changing to accept `$network_id` first. The `_site_option()` functions will remain in use throughout core as our way of retrieving a network option for the current network.

See #28290.

Built from https://develop.svn.wordpress.org/trunk@34912


git-svn-id: http://core.svn.wordpress.org/trunk@34877 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-07 17:11:25 +00:00
Jeremy Felt
54512d64cb MS: Use *_network_option() functions throughout core.
Replaces all uses of `*_site_option()` with the corresponding "network" function.

This excludes one usage in `wp-admin/admin-footer.php` that needs more investigation.

Props spacedmonkey.
See #28290.

Built from https://develop.svn.wordpress.org/trunk@34778


git-svn-id: http://core.svn.wordpress.org/trunk@34743 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-02 19:08:26 +00:00
Sergey Biryukov
8f0e1e3c72 Add missing translator comment after [34292].
See #31840.
Built from https://develop.svn.wordpress.org/trunk@34299


git-svn-id: http://core.svn.wordpress.org/trunk@34263 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 18:40:24 +00:00
Scott Taylor
dd6fe1ba32 Network Setup: don't use <code> in translation strings in wp-admin/network files.
Props ramiy.
Fixes #31840.

Built from https://develop.svn.wordpress.org/trunk@34292


git-svn-id: http://core.svn.wordpress.org/trunk@34256 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-18 18:18:27 +00:00
John Blackbourn
a9e5cfddc7 Implement wp_login_url() and wp_registration_url() in places where wp-login.php is currently hard-coded.
See #31495
Props GregLone

Built from https://develop.svn.wordpress.org/trunk@34213


git-svn-id: http://core.svn.wordpress.org/trunk@34177 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 17:11:35 +00:00
Scott Taylor
bd0a6bbf8c Create wp-admin/includes/network.php via svn cp and only load it in wp-admin/network.php. Move the functions there.
See #33813.

Built from https://develop.svn.wordpress.org/trunk@34023


git-svn-id: http://core.svn.wordpress.org/trunk@33992 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 22:01:24 +00:00
nacin
55e6976d96 Remove unused MU function and unnecessary separate includes file. see #11816
git-svn-id: http://svn.automattic.com/wordpress/trunk@13644 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-03-10 08:46:05 +00:00
nacin
4c1b910030 First pass on network.php improvements. see #12094
git-svn-id: http://svn.automattic.com/wordpress/trunk@13571 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2010-03-03 07:43:32 +00:00