Commit Graph

366 Commits

Author SHA1 Message Date
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
Sergey Biryukov
9967a3e030 Docs: Add missing description for $post global.
Props immeet94.
Fixes #46503. See #47110.
Built from https://develop.svn.wordpress.org/trunk@45742


git-svn-id: http://core.svn.wordpress.org/trunk@45553 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-08-04 12:28:56 +00:00
Gary Pendergast
87675d288b Coding Standards: Fix all WordPress.WhiteSpace.PrecisionAlignment issues.
See #47632.


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


git-svn-id: http://core.svn.wordpress.org/trunk@45413 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-07-05 05:21:56 +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
Gary Pendergast
bbbf0ee62e Admin: Re-add some validation from [44048] that was accidentally removed in [44165].
Props david.binda.
See #45037.


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


git-svn-id: http://core.svn.wordpress.org/trunk@44557 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-02-07 04:12:51 +00:00
Gary Pendergast
6d5cd6842a Coding Standards: Document intentional case block fall-throughs.
Fixes `PSR2.ControlStructures.SwitchDeclaration.TerminatingComment` violations.

See #45934.


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


git-svn-id: http://core.svn.wordpress.org/trunk@44396 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-11 06:26:50 +00:00
desrosj
f082806afa Block Editor: Display notice to the user when JavaScript is disabled.
Currently, when viewing the block editor with JavaScript disabled, the user sees a blank admin page with the admin menu sidebar. This adds an admin notice informing the user that JavaScript is required for the new block editor.

Props mkaz, pento, azaozz, ocean90, desrosj.
Fixes #45453.
Built from https://develop.svn.wordpress.org/trunk@44437


git-svn-id: http://core.svn.wordpress.org/trunk@44268 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2019-01-07 20:40:50 +00:00
desrosj
43bdb0e193 Editor: Remove unwanted fields before saving posts.
The meta_input, file, and guid fields are not intended to be updated through user input.

Merges [44047] to trunk.
Built from https://develop.svn.wordpress.org/trunk@44295


git-svn-id: http://core.svn.wordpress.org/trunk@44125 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-18 21:32:48 +00:00
desrosj
bbe9a37b6c Editor: Add custom fields meta box support in the block editor.
This brings support for the custom fields meta box into the new block editor.

The `webpack` and `copy-webpack-plugin` packages have also been updated.

This does not bump the `@wordpress` packages like in [43861] because of conflicts with package versions already installed in `trunk`. The packages will be brought up to date in a subsequent merge.

Merges [43861] and [43863] into trunk.

See #45145.
Fixes #45257.
Built from https://develop.svn.wordpress.org/trunk@44260


git-svn-id: http://core.svn.wordpress.org/trunk@44090 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-17 03:52:51 +00:00
Gary Pendergast
8464097ea4 Editor: Merge some minor bug fixes.
There were some tweaks made to the post editor in WordPress 5.0 that hadn't been merged to `trunk`, this commit rectifies that.

Merges [43815,43816] from the 5.0 branch to trunk.

Props birgire, jorbin, abdullahramzan, adamsilverstein, mrahmadawais, airathalitov, ajitbohra, schlessera, albertomedina, aldavigdis, alexsanford1, xyfi, nitrajka, afercia, andreiglingeanu, euthelup, aduth, sumobi, anevins, azaozz, androb, andrewserong, kallehauge, nosolosw, apeatling, atimmer, arnaudban, asvinballoo, b-07, benlk, blowery, caxco93, benjamin_zekavica, kau-boy, bernhard-reiter, bcolumbia, bph, boblinthorst, bradyvercher, bpayton, brentswisher, bronsonquick, burhandodhy, icaleb, chouby, ehg, chrisvanpatten, butimnoexpert, christophherr, chriskmnds, claudiosanches, danielbachhuber, mrmadhat, danielhw, danieltj, goldsounds, dfangstrom, daniloercoli, dannycooper, nerrad, dsawardekar, davemoran118, davidherrera, dryanpress, davidsword, davisshaver, dmsnell, dlocc, diegoreymendez, dd32, dency, ocean90, donnapep, chopinbach, electricfeet, eliorivero, sewmyheadon, ericnmurphy, foobar4u, circlecube, fabs_pim, flixos90, floriansimeth, gma992, garrett-eclipse, garyj, pento, doomwaxer, revgeorge, gziolo, bordoni, hardeepasrani, helen, luehrsen, herbmiller, toro_unit, ianbelanger, iandunn, igorsch, ipstenu, ireneyoast, israelshmueli, sisanu, jd55, copons, jnylen0, jamestryon, ephoxjames, jamiehalvorson, jsnajdr, jagnew, dciso, octalmage, vengisss, jhoffm34, shenkj, audrasjb, jblz, jeremyfelt, motleydev, jipmoors, sephsekla, joemaller, joemcgill, joen, johndyer, johnjamesjacoby, joshuawold, johnny5, desrosj, jonsurrell, belcherj, sirjonathan, koke, jorgefilipecosta, shelob9, jvisick77, julienmelissas, kopepasah, kadamwhite, codebykat, ryelle, gwwar, kevinwhoffman, coderkevin, ixkaito, kjellr, obenland, lancewillett, postphotos, loicblascos, lucasstark, luigipulcini, lucaskowalski, lukepettway, mahdiyazdani, mahmoudsaeed, mkaz, tyxla, markjaquith, mapk, vindl, m-e-h, mboynes, mattheu, lonelyvegan, mtias, napy84, maurobringolf, maximebj, mayukojpn, woodent, michaelhull, mmtr86, stubgo, simison, mihai2u, mike-haydon-swo, mnelson4, mpheasant, mikeschroder, idpokute, mikeyarce, dimadin, gonzomir, milesdelliott, warmarks, munirkamal, nfmohit, nateconley, greatislander, njpanderson, notnownikki, nielslange, nikschavan, potbot, nshki, webmandesign, oskosk, pglewis, pareshradadiya-1, swissspidy, pbearne, pauldechov, psealock, paulstonier, paulwilde, pedromendonca, ptasker, peterwilsoncc, tyrannous, strategio, piersb, delawski, prtksxna, presskopp, rachelbaker, rachelmcr, rakshans1, rahmon, lamosty, youknowriad, riddhiehta02, noisysocks, deviodigital, sanchothefat, robertsky, _dorsvenabili, rohittm, magicroundabout, rmccue, welcher, ryo511, sagarprajapati, samikeijonen, scottmweaver, kluny, sharaz, giventofly76, designsimply, sstoqnov, hypest, netweb, stevehenty, stuartfeldt, sergioestevao, soean, tammie_l, karmatosed, thrijith, timgardner, timmydcrawford, tjnowell, mirucon, travislopes, truongwp, tjfunke001, vishalkakadiya, vtrpldn, walterebert, westonruter, skorasaurus, somtijds, earnjam, williampatton, willybahuaud, yoavf, zebulan, ziyaddin, abhijitrakas, andreamiddleton, csabotta, dixitadusara, etoledom, faishal, hideokamoto, imath, iseulde, j-falk, jaswrks, johnwatkins0, jomurgel, notlaura, leahkoerper, mcsf, meetjey, 0mirka00, mitogh, ephoxmogran, tacrapo, mzorz, nagayama, omarreiss, ramonopoly, rileybrook, tinkerbelly, shaileesheth, sikander, ssousa, tfrommen, yahil.

Fixes #45037.


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


git-svn-id: http://core.svn.wordpress.org/trunk@43995 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-14 05:12:52 +00:00
Peter Wilson
a2c890409b Multisite: Validate activation links.
Built from https://develop.svn.wordpress.org/trunk@44048


git-svn-id: http://core.svn.wordpress.org/trunk@43878 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2018-12-13 01:26:24 +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
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
Gary Pendergast
c90cfa3b50 General: Fix some precision alignment formatting warnings.
The WPCS `WordPress.WhiteSpace.PrecisionAlignment` rule throws warnings for a bunch of code that will likely cause issues for `wpcbf`. Fixing these manually beforehand gives us better auto-fixed results later.

See #41057.


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


git-svn-id: http://core.svn.wordpress.org/trunk@42057 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-11-26 23:57:55 +00:00
Gary Pendergast
a72be13ec0 Editor: Add the replace_editor filter.
This filter allows the Core editor to be replaced by an entirely different editor (coughcoughGUTENBERGcough).

Props azaozz, who is supposed to be on sabbatical right now.
Fixes #42119.


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


git-svn-id: http://core.svn.wordpress.org/trunk@41663 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-10-11 12:06:48 +00:00
Sergey Biryukov
9234febe06 Posts, Post Types: Use an existing string for "Invalid post type" error message.
Props ramiy.
Fixes #39171.
Built from https://develop.svn.wordpress.org/trunk@39756


git-svn-id: http://core.svn.wordpress.org/trunk@39694 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2017-01-10 02:40:42 +00:00
Dominik Schilling
25e66e4f1e Text Changes: Unify permission error messages.
The new format looks like "Sorry, you are not allowed to <action>.". This provides a consistent experience for all error messages related to missing permissions. It also reduces the number of similar strings and allows translators to provide a consistent style in their language.

Props ramiy, Presskopp.
Fixes #34521.
Built from https://develop.svn.wordpress.org/trunk@37914


git-svn-id: http://core.svn.wordpress.org/trunk@37855 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-06-29 15:16:29 +00:00
Dominik Schilling
7f1abd441f Posts: Fire a post_action_{$action} action for a custom post action request.
Props jfarthing84, Mte90, brianvan, sudar, DrewAPicture.
Fixes #27056.
Built from https://develop.svn.wordpress.org/trunk@37424


git-svn-id: http://core.svn.wordpress.org/trunk@37390 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2016-05-12 15:44:28 +00:00
Scott Taylor
b0561ed6e4 Dashboard: use the create_posts cap on the post type object when determining if the Quick Press widget can be displayed.
Props jim912, ocean90, chriscct7.
Fixes #25681.

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


git-svn-id: http://core.svn.wordpress.org/trunk@35248 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-20 05:49:24 +00:00
Sergey Biryukov
d6865505d5 Respect the force_delete parameter of get_delete_post_link().
Previously, it only worked if `EMPTY_TRASH_DAYS` was disabled.

Props johnbillion, chriscct7.
Fixes #26832.
Built from https://develop.svn.wordpress.org/trunk@34794


git-svn-id: http://core.svn.wordpress.org/trunk@34759 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-10-03 01:50:25 +00:00
John Blackbourn
541dbb2711 Remove the ability to view the post listing screen and post editing screen for post types with show_ui set to false. It is unexpected and unintended behaviour that this is allowed.
If your plugin or site does rely on this behaviour, the arguments that are passed to `register_post_type()` should be altered so that `show_ui` is `true`, and arguments such as `show_in_menu`, `show_in_nav_menus`, and `show_in_admin_bar` are `false`.

Fixes #33763
Props swissspidy, johnbillion

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


git-svn-id: http://core.svn.wordpress.org/trunk@34145 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-15 10:27:29 +00:00
John Blackbourn
9bf86a74d0 Set the secure flag on the wp-saving-post cookie when using HTTPS.
This cookie doesn't contain any sensitive information, but this change brings its behaviour in line with all other core cookies.

Fixes #31056

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


git-svn-id: http://core.svn.wordpress.org/trunk@33996 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 22:42:23 +00:00
Scott Taylor
503aa8b76d Move redirect_post() from wp-admin/post.php to wp-admin/includes/post.php.
See #33813.

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


git-svn-id: http://core.svn.wordpress.org/trunk@33989 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-09-10 21:31:24 +00:00
Dominik Schilling
a9b3f12826 Heartbeat: Ensure post locks are released.
Built from https://develop.svn.wordpress.org/trunk@33542


git-svn-id: http://core.svn.wordpress.org/trunk@33509 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-08-04 04:54:34 +00:00
Sergey Biryukov
82034319e1 Merge duplicate strings related to Trash.
props pavelevap.
fixes #33133.
Built from https://develop.svn.wordpress.org/trunk@33431


git-svn-id: http://core.svn.wordpress.org/trunk@33398 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-07-26 22:48:26 +00:00
Gary Pendergast
fe5a844be5 Capabilities: When creating an auto-draft, ensure that the current user still has permission to do so.
Built from https://develop.svn.wordpress.org/trunk@33357


git-svn-id: http://core.svn.wordpress.org/trunk@33329 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-07-22 04:02:25 +00:00
Konstantin Obenland
a4e803fbd4 Use get_default_comment_status() globally.
Also makes the filter name static and passes the post type for context.

Props valendesigns.
Fixes #31168.


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


git-svn-id: http://core.svn.wordpress.org/trunk@33025 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-07-02 22:32:25 +00:00
Scott Taylor
c6a4512b1b Add missing doc blocks to wp-admin/includes/*.
Fix some egregious uses of tabbing.
Some functions can simply return `apply_filters(...)` instead of setting a variable that is immediately returned.

See #32444.

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


git-svn-id: http://core.svn.wordpress.org/trunk@32624 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-05-29 20:17:26 +00:00
Scott Taylor
b56b9b3e5c Add @global annotations for wp-admin/*.
See #32444.

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


git-svn-id: http://core.svn.wordpress.org/trunk@32612 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-05-28 21:41:30 +00:00
Scott Taylor
b8341a472d When adding post_type to $sendback in wp-admin/post.php, use add_query_arg() instead of string concatenation.
Props podpirate.
Fixes #31492.

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


git-svn-id: http://core.svn.wordpress.org/trunk@31614 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-03-05 22:31:24 +00:00
Scott Taylor
84867b3e9c Admin globals:
* Declare `$wp_importers` as a global in `admin.php`
* Declare `$post_type`, `$post_type_object`, and  `$post` as globals where applicable

See #30799.

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


git-svn-id: http://core.svn.wordpress.org/trunk@31102 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2015-01-10 05:29:22 +00:00
Andrew Ozz
3d60d9f875 Autosave: prevent setting multiple stale wp-saving-post-* cookies when the browser disregards "session cookies" expiration on quit:
- Add expiration time of 24 hours for these cookies.
- Rename them to `wp-saving-post` (no post_id) so there is never more than one cookie per domain.
Fixes #29294.
Built from https://develop.svn.wordpress.org/trunk@29572


git-svn-id: http://core.svn.wordpress.org/trunk@29346 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-08-22 00:25:16 +00:00
Scott Taylor
517dbfaa21 In wp-admin/post.php, break is unreachabled after exit.
See #27882.

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


git-svn-id: http://core.svn.wordpress.org/trunk@28140 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-05-06 18:15:15 +00:00
Helen Hou-Sandí
593bd2a495 Avoid an undefined function due to /wp-admin/includes/dashboard.php being included too late. props obenland. fixes #27457.
Built from https://develop.svn.wordpress.org/trunk@27630


git-svn-id: http://core.svn.wordpress.org/trunk@27473 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-03-20 01:31:15 +00:00
Andrew Ozz
335add2573 Autosave: refactor autosave.js, use heartbeat for transport and move all "Add/Edit Post" related functionality to post.js. See #25272.
Built from https://develop.svn.wordpress.org/trunk@26995


git-svn-id: http://core.svn.wordpress.org/trunk@26872 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-01-22 04:56:16 +00:00
Andrew Nacin
3189d79f46 Don't let Quick Draft ignore default comment_status and ping_status.
props kovshenin.
fixes #26722.

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


git-svn-id: http://core.svn.wordpress.org/trunk@26838 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2014-01-16 20:24:13 +00:00
Drew Jaynes
89211ee8d6 Inline documentation for hooks in wp-admin/post.php.
Props nukaga, kpdesign.
Fixes #25846.

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


git-svn-id: http://core.svn.wordpress.org/trunk@26299 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-11-26 07:44:10 +00:00
Sergey Biryukov
ecd594b5a6 PHPDoc and i18n fixes for dashboard widgets.
props dimadin for initial patch.
see #25824.
Built from https://develop.svn.wordpress.org/trunk@26241


git-svn-id: http://core.svn.wordpress.org/trunk@26148 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-11-17 03:21:10 +00:00
Andrew Nacin
c03d9d3f01 Revert these action blocks in wp-admin/post.php to their pre-[26144] state.
see #25824.

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


git-svn-id: http://core.svn.wordpress.org/trunk@26138 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-11-15 22:29:09 +00:00
Andrew Nacin
791e807f08 More dash updates.
* Shuffle around some pixels.
 * Rename some things that weren't caught in [26220].
 * Revert default-widgets.php change from [26144].
props lessbloat.
see #25824.

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


git-svn-id: http://core.svn.wordpress.org/trunk@26137 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-11-15 22:23:09 +00:00
Andrew Nacin
809b335f7a Merge the new dashboard design into core.
Merges https://github.com/growthdesigner/wp-dash.

props lessbloat, joen, helen, dbernar1, kraftbj, ryelle, tillkruess, grapplerulrich, markjaquith.
see #25824.

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


git-svn-id: http://core.svn.wordpress.org/trunk@26055 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-11-13 22:09:10 +00:00
Andrew Nacin
fd57b239d2 Don't rely on include_path to include files.
Always use dirname() or, once available, ABSPATH.

props ketwaroo, hakre.
fixes #17092.

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


git-svn-id: http://core.svn.wordpress.org/trunk@25533 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-09-25 00:18:11 +00:00
Andrew Nacin
c2db94d10c Use meta caps edit_post, read_post, and delete_post directly, rather than consulting the post type object. map_meta_cap() handles that for us. props markjaquith, kovshenin. fixes #23226.
git-svn-id: http://core.svn.wordpress.org/trunk@24593 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-07-08 20:05:42 +00:00
Andrew Ozz
a26190eb2e Post locks:
- Change from IDs to classes for the notification-dialog divs so they can be reused.
- Do not check post locks if the dialog's html is not present.
- Do not check post locks if there is only one user on a single site install.
See #23697.

git-svn-id: http://core.svn.wordpress.org/trunk@24304 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-05-20 19:36:29 +00:00
Sergey Biryukov
6898eba2f2 Avoid PHP notices when deleting or restoring an item that no longer exists. props johnbillion, ocean90. fixes #24246.
git-svn-id: http://core.svn.wordpress.org/trunk@24201 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-05-08 18:56:54 +00:00
Sergey Biryukov
bfc9c67861 Remove unused variables. props ocean90. fixes #24247.
git-svn-id: http://core.svn.wordpress.org/trunk@24199 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-05-08 17:52:18 +00:00
Andrew Ozz
9fe85b154e Revisions: move the call to _wp_upgrade_revisions_of_post() to edit-form-advanced.php, in the code block checking whether we should show the revisions postbox. See #16215
git-svn-id: http://core.svn.wordpress.org/trunk@23929 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-04-06 23:43:05 +00:00
Mark Jaquith
cccb2939db Fix a longstanding "off by one" revision authorship bug.
* Fixes old revision data on the fly when you open a post for editing.
* Uses post_name of revisions to store a post version number (-v1), so we know what has been fixed.
* Latest version should also have a revision stored, whereas before it did not.

props adamsilverstein, mdawaffe. fixes #16215.

git-svn-id: http://core.svn.wordpress.org/trunk@23823 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-03-27 20:21:38 +00:00
Andrew Ozz
a224d8aaf7 Local autosave: set a temp cookie on submitting the form and change it on redirecting after the post is saved/updated, then use it to determine if saving worked properly. Removes the chance for false positives after saving/updating a post. See #23220
git-svn-id: http://core.svn.wordpress.org/trunk@23693 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2013-03-14 03:06:07 +00:00