Commit Graph

70 Commits

Author SHA1 Message Date
Sergey Biryukov
79907af59c Add 'dashboard_secondary_items' filter for the number of secondary link items in the 'WordPress News' dashboard widget.
props MikeHansenMe, DrewAPicture.
fixes #31434.

git-svn-id: https://develop.svn.wordpress.org/trunk@33833 602fd350-edb4-49c9-b593-d223f7449a82
2015-08-31 21:56:50 +00:00
Scott Taylor
3b8c5529cb foreach is a statement, not a function.
See #33491.


git-svn-id: https://develop.svn.wordpress.org/trunk@33734 602fd350-edb4-49c9-b593-d223f7449a82
2015-08-25 20:27:56 +00:00
Gary Pendergast
7439dd7354 Capabilities: When creating an auto-draft, ensure that the current user still has permission to do so.
git-svn-id: https://develop.svn.wordpress.org/trunk@33357 602fd350-edb4-49c9-b593-d223f7449a82
2015-07-22 04:01:53 +00:00
John Blackbourn
28ef7b69e5 Place the locale inside the md5 hash in the dashboard RSS feed widget transient key to prevent the transient timeout option name becoming longer than the allowed field size.
Props andg
Fixes #32804


git-svn-id: https://develop.svn.wordpress.org/trunk@33192 602fd350-edb4-49c9-b593-d223f7449a82
2015-07-13 15:31:54 +00:00
John Blackbourn
9889311217 Append the current locale to dashboard RSS widget cache keys so they refresh accordingly when the locale is changed.
Fixes #32804
Props andg


git-svn-id: https://develop.svn.wordpress.org/trunk@33183 602fd350-edb4-49c9-b593-d223f7449a82
2015-07-12 22:06:56 +00:00
Helen Hou-Sandi
8209a24d85 Show row actions on focus for the dashboard comment list.
see #25408.


git-svn-id: https://develop.svn.wordpress.org/trunk@33106 602fd350-edb4-49c9-b593-d223f7449a82
2015-07-07 15:25:03 +00:00
Scott Taylor
986990163f Add doc blocks to functions that are missing them.
If the function has no need for `@param` or `@return`, do an archeaological dig to find `@since`.

See #32444.


git-svn-id: https://develop.svn.wordpress.org/trunk@32672 602fd350-edb4-49c9-b593-d223f7449a82
2015-05-31 03:17:50 +00:00
Scott Taylor
60e5c90e62 Add (more) missing doc blocks to wp-admin/includes/*.
See #32444.


git-svn-id: https://develop.svn.wordpress.org/trunk@32655 602fd350-edb4-49c9-b593-d223f7449a82
2015-05-29 21:16:59 +00:00
Scott Taylor
d55800a4f2 In the style of #30947 and default-filters.php, add 2 new files to wp-admin/includes:
`admin-filters.php`
`ms-admin-filters.php`

There are random actions and filters littered among files like `misc.php`. These files contain functions that won't work outside of admin context and are typically only loaded in files that have already loaded the admin bootstrap.

See #32529.


git-svn-id: https://develop.svn.wordpress.org/trunk@32653 602fd350-edb4-49c9-b593-d223f7449a82
2015-05-29 17:03:13 +00:00
Scott Taylor
23ce2efd12 Add @global annotations for wp-admin/*.
See #32444.


git-svn-id: https://develop.svn.wordpress.org/trunk@32642 602fd350-edb4-49c9-b593-d223f7449a82
2015-05-28 21:40:27 +00:00
Scott Taylor
bd06ad2725 get_comments() can return int, so a few places need to check if the return value is traversable before passing what is assumed to be an array.
See #32444.


git-svn-id: https://develop.svn.wordpress.org/trunk@32600 602fd350-edb4-49c9-b593-d223f7449a82
2015-05-25 17:58:52 +00:00
Gary Pendergast
05710aaa41 Ensure post titles are correctly escaped on the Dashboard.
Props helen, ocean90, dd32, pento.



git-svn-id: https://develop.svn.wordpress.org/trunk@32175 602fd350-edb4-49c9-b593-d223f7449a82
2015-04-20 07:38:29 +00:00
Dominik Schilling (ocean90)
b0d6757918 Use HTTPS URLs for codex.wordpress.org.
see #27115.

git-svn-id: https://develop.svn.wordpress.org/trunk@32116 602fd350-edb4-49c9-b593-d223f7449a82
2015-04-12 21:28:58 +00:00
Jeremy Felt
ff0b2f7a6f Provide proper label associations and descriptions throughout the network admin
* Add labels previously missing for many inputs throughout the network admin screen.
* Add proper `aria-describedby` attributes to provide better descriptions.
* Wrap grouped inputs with `fieldset` elements.
* Remove now unneeded `title` attributes when appropriate.

Props cfoellmann, afercia, rianrietveld.

Fixes #38406.


git-svn-id: https://develop.svn.wordpress.org/trunk@31517 602fd350-edb4-49c9-b593-d223f7449a82
2015-02-23 02:28:41 +00:00
Sergey Biryukov
2dd6c6e696 Dashboard: Add a filter for the query arguments used for the Recent Posts widget.
props danielbachhuber.
fixes #29374.

git-svn-id: https://develop.svn.wordpress.org/trunk@31508 602fd350-edb4-49c9-b593-d223f7449a82
2015-02-22 19:56:09 +00:00
Scott Taylor
83b6fad852 In HTML5, the action attribute is no longer required. Remove this attribute when empty.
The admin HTML is served with the HTML5 doctype.

"The action and formaction content attributes, if specified, must have a value that is a valid non-empty URL potentially surrounded by spaces." 
http://www.w3.org/html/wg/drafts/html/master/forms.html#attr-fs-action

Props voldemortensen.
Fixes #30126.


git-svn-id: https://develop.svn.wordpress.org/trunk@31200 602fd350-edb4-49c9-b593-d223f7449a82
2015-01-16 04:15:52 +00:00
Sergey Biryukov
621292d70f In dashboard activity widget, display a front-end link if the user cannot edit the post.
props UaMV, DrewAPicture.
fixes #29025.

git-svn-id: https://develop.svn.wordpress.org/trunk@31075 602fd350-edb4-49c9-b593-d223f7449a82
2015-01-08 00:25:26 +00:00
Scott Taylor
6c5e90eaa5 Correct some types in wp-admin/*-location files' doc blocks.
See #30224.


git-svn-id: https://develop.svn.wordpress.org/trunk@30203 602fd350-edb4-49c9-b593-d223f7449a82
2014-11-03 07:08:16 +00:00
Mark Jaquith
4c22a5003b Use HTTPS links for planet.wordpress.org
see #27115

git-svn-id: https://develop.svn.wordpress.org/trunk@29787 602fd350-edb4-49c9-b593-d223f7449a82
2014-09-29 13:23:46 +00:00
Mark Jaquith
7402030670 Show the number of approved comments instead of all comments on
the dashboard in the "At a glance" section.

fixes #26738. props benjmay

git-svn-id: https://develop.svn.wordpress.org/trunk@29785 602fd350-edb4-49c9-b593-d223f7449a82
2014-09-29 12:41:49 +00:00
wonderboymusic
fa6508e234 wp_dashboard_cached_rss_widget() contained some func_get_args() code that was indescribably weird.
This keeps it weird, but makes sure that `$check_urls` gets passed to the callback.

Props michalzuber, ocean90.
Fixes #28872.


git-svn-id: https://develop.svn.wordpress.org/trunk@29442 602fd350-edb4-49c9-b593-d223f7449a82
2014-08-07 21:46:02 +00:00
Sergey Biryukov
e4c8f3a843 QuickPress: Disable autocomplete for content, enable "Save Draft" button on load.
props morganestes, michalzuber.
fixes #27760.

git-svn-id: https://develop.svn.wordpress.org/trunk@29323 602fd350-edb4-49c9-b593-d223f7449a82
2014-07-29 15:33:07 +00:00
Drew Jaynes (DrewAPicture)
6ddc1e5f6d Fix syntax for single- and multi-line comments in wp-admin-directory files.
See #28931.


git-svn-id: https://develop.svn.wordpress.org/trunk@29206 602fd350-edb4-49c9-b593-d223f7449a82
2014-07-17 09:13:53 +00:00
Dominik Schilling (ocean90)
60b1befd8e Customizer: Add meta capability customize which is mapped to edit_theme_options.
You can now allow users to access the Customizer, say for any user who can `edit_posts`, via `map_meta_cap` or `user_has_cap` filter. See ticket for examples.

props westonruter, nacin.
fixes #28605.

git-svn-id: https://develop.svn.wordpress.org/trunk@29170 602fd350-edb4-49c9-b593-d223f7449a82
2014-07-14 19:00:24 +00:00
Dominik Schilling (ocean90)
d198c0bdd5 Remove unused variable in wp_dashboard_plugins_output(). Unused since [26144].
props michalzuber.
see #28872.

git-svn-id: https://develop.svn.wordpress.org/trunk@29130 602fd350-edb4-49c9-b593-d223f7449a82
2014-07-13 10:30:53 +00:00
Scott Taylor
4ccb011960 Don't use variable variables in wp_dashboard_plugins_output(). Variable variables aren't the worst thing about this function.
See #27881.


git-svn-id: https://develop.svn.wordpress.org/trunk@28742 602fd350-edb4-49c9-b593-d223f7449a82
2014-06-11 18:55:00 +00:00
Scott Taylor
2cd825a21b Cleanup for switch statements:
* Move `default` to the bottom in `WP_Theme_Install_List_Table`
* `switch/endswitch` syntax is not supported in Hack. Switch to `switch (...) {  .... }` syntax. (A few template-type instances linger).

Fixes #28409.
See #27881.



git-svn-id: https://develop.svn.wordpress.org/trunk@28633 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-30 17:57:51 +00:00
Sergey Biryukov
7b133a336f Remove obsolete code from wp_dashboard_setup().
props kitchin.
fixes #26604.

git-svn-id: https://develop.svn.wordpress.org/trunk@28592 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-27 15:40:19 +00:00
Scott Taylor
e53cdbb8f0 In wp_dashboard_recent_posts(), $i is set and never used.
See #27882.


git-svn-id: https://develop.svn.wordpress.org/trunk@28545 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 18:55:07 +00:00
Scott Taylor
70342f4a75 $theme_name is set but no longer used in wp_dashboard_right_now(). The theme name is displayed with the call to update_right_now_message().
See #27882.


git-svn-id: https://develop.svn.wordpress.org/trunk@28544 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 18:53:43 +00:00
Scott Taylor
312ef7b264 These functions import $wpdb but do not use it.
See #27882.


git-svn-id: https://develop.svn.wordpress.org/trunk@28539 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-22 17:36:42 +00:00
Scott Taylor
eef0d99ed8 hackificator doesn't like mixed quote styles in some generated HTML. The switch from single to double allows these files to be parsed.
See #27881.


git-svn-id: https://develop.svn.wordpress.org/trunk@28497 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-19 01:58:28 +00:00
Scott Taylor
4c6f405ee7 Remove a dead variable, $start, from wp_dashboard_recent_comments().
See #27882.



git-svn-id: https://develop.svn.wordpress.org/trunk@28263 602fd350-edb4-49c9-b593-d223f7449a82
2014-05-06 03:34:22 +00:00
Andrew Nacin
78b05bc236 Avoid JS errors before the commentReply script loads. Let's make this unobtrusive soon.
props aubreypwd.
fixes #24741.


git-svn-id: https://develop.svn.wordpress.org/trunk@27747 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-26 18:52:31 +00:00
Andrew Nacin
0fccb7b64d Restore the update message in the dashboard, removed in 3.8.
props obenland.
fixes #26664.


git-svn-id: https://develop.svn.wordpress.org/trunk@27711 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-25 14:35:23 +00:00
Drew Jaynes (DrewAPicture)
4d7ca61c09 Inline documentation for hooks in wp-admin/includes/dashboard.php.
Props mauryaratan. Props kpdesign for some minor cleanup.
Fixes #25752.


git-svn-id: https://develop.svn.wordpress.org/trunk@27669 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-24 02:20:33 +00:00
Andrew Nacin
b2da716c11 Skipping placeholders in a string will only catch translators off guard.
see #27453, #27132.


git-svn-id: https://develop.svn.wordpress.org/trunk@27613 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-19 05:53:01 +00:00
John Blackbourn
f850186eff Introduce permission checks for post queries and edit links in the At a Glance dashboard widget. Fixes #27132. Props mattheu.
git-svn-id: https://develop.svn.wordpress.org/trunk@27596 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-18 22:43:41 +00:00
John Blackbourn
d91dd88edc Remove the "See more" toggle from the At a Glance dashboard widget. Fixes #26614.
git-svn-id: https://develop.svn.wordpress.org/trunk@27583 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-18 12:55:42 +00:00
Andrew Nacin
a641b9fb55 Cap and theme support checks for the welcome panel.
props MikeHansenMe.
fixes #26276.


git-svn-id: https://develop.svn.wordpress.org/trunk@27563 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-17 19:46:15 +00:00
Sergey Biryukov
1f8285b2e1 Fix .comment-grey-bubble markup and remove a stray </h5> tag.
props avryl.
fixes #27408.

git-svn-id: https://develop.svn.wordpress.org/trunk@27548 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-15 04:31:58 +00:00
Dominik Schilling (ocean90)
ff567294f6 "At a Glance" widget: Move get_avatar() line out of if-block.
This allows you to show avatars for custom comment types via the `get_avatar_comment_types` filter.

props zodiac1978.
fixes #26944.

git-svn-id: https://develop.svn.wordpress.org/trunk@27384 602fd350-edb4-49c9-b593-d223f7449a82
2014-03-03 20:13:29 +00:00
nacin
ce00f36ab7 Dashboard widgets: Don't link to Pages or Posts for Authors or Contributors respectively.
props mattheu.
see #26574 for trunk.


git-svn-id: https://develop.svn.wordpress.org/trunk@26999 602fd350-edb4-49c9-b593-d223f7449a82
2014-01-22 16:51:07 +00:00
Andrew Nacin
6c96d3e787 Introduce dashboard_glance_items filter which replaces 3.7 right_now_* hooks that were tied to table markup.
fixes #26495.


git-svn-id: https://develop.svn.wordpress.org/trunk@26832 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-09 19:11:23 +00:00
Matt Thomas
9439bb7b4f Expand the Quick Draft section by default. Fixes #26463, props bassgang.
git-svn-id: https://develop.svn.wordpress.org/trunk@26813 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-09 00:42:56 +00:00
Andrew Nacin
2c16db49b1 Translator's comment for a date_i18n() string.
props netweb.
fixes #26470.


git-svn-id: https://develop.svn.wordpress.org/trunk@26758 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-07 00:37:13 +00:00
Andrew Nacin
292391081a Dashboard: Restore a line that vanished from my editor to print recently published posts. Also fix an off-by-one error.
see [26704]. see #26066.


git-svn-id: https://develop.svn.wordpress.org/trunk@26741 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-06 20:12:10 +00:00
Drew Jaynes
439c61a1ba Inline documentation fixes for hooks and functions introduced in 3.8.0.
git-svn-id: https://develop.svn.wordpress.org/trunk@26736 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-06 19:17:35 +00:00
Andrew Nacin
a7ee089f6f Fix various i18n issues on the dashboard. Limits it to posts and pages only for 3.8.
props SergeyBiryukov, dimadin.
fixes #26066.


git-svn-id: https://develop.svn.wordpress.org/trunk@26704 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-05 23:33:48 +00:00
Andrew Nacin
b7de614f71 Restore "Search Engines Discouraged" to the dashboard.
props JustinSainton.
fixes #26431.


git-svn-id: https://develop.svn.wordpress.org/trunk@26700 602fd350-edb4-49c9-b593-d223f7449a82
2013-12-05 23:04:46 +00:00