__group__ ticket summary owner component _version priority severity votes milestone type _status workflow _created modified _description _reporter
Popular 32101 Ability to mark plugin as unmanaged DrewAPicture Plugins 4.1.2 normal normal 48 WordPress.org task (blessed) assigned has-patch 2015-04-24T07:48:54Z 2016-09-19T20:20:59Z "We've had a rather unpleasent incident where we used a certain plugin name for a private plugin, but then another plugin appeared under the same name in the theme directory, marking our plugin for an update. Rest assured ''someone'' clicked on the update button, replacing our plugin with some other.
Such conflicts may seem rare, but they do happen. Adding an optional, defaults to false, `private` field to the theme header (like npm/Bower) to disable update checking for such a plugin would be an easy fix. " damonganto
Popular 14179 Theme asking to update (theme with same name on WordPress.org) Themes normal normal 14 WordPress.org defect (bug) new 2010-07-03T08:34:02Z 2016-09-19T20:20:58Z "I have a theme with a certain name, but there is a theme with the same name in the WordPress themes directory. So now my theme keeps showing an update message.
Proposed solutions:
1. Add unique hash to each uploaded theme in the themes directory. This way even if someone has a home-grown theme which happens to have the same name, but are not going to upload it to the themes directory, there won't be a conflict. (You could change the name of the theme, but who is to say someone won't upload a theme that also has that name.)
2. Add more fields to the updater check such as author, and date/ time created. This could mean though that theme authors would always have to add this during theme creation, and know why they are doing this. Possibly adding a extra complicating step in WordPress theme design. Otherwise at some point they or their client could start getting a update message for their theme.
" design_dolphin
Popular 23318 Plugins Admin Showing Details for Wrong Plugin Plugins normal normal 11 WordPress.org enhancement new 2013-01-29T22:41:54Z 2016-09-19T20:20:59Z "I just set up a new site with some plugins, none of them activated yet. The plugins screen says:
""There is a new version of Google XML Sitemaps available. View version 4.1 details or update now.""
I know for a fact there is no such version of this plugin. When I click details link, it tells me to install some other plugin called page-list?!" miqrogroove
Noteworthy 34694 Facilitate automated testing in context of pull requests and diffs westonruter* Build/Test Tools normal normal 8 WordPress.org enhancement accepted 2015-11-16T00:45:59Z 2016-11-29T21:51:53Z "Using GitHub for core development has been a wishlist item for awhile now. Individual feature plugins have been increasingly developed on GitHub (e.g. Widget Customizer, WP-API). Going an extra step, the Twenty Sixteen theme only exists on GitHub and isn't even committed to `trunk`. So while feature plugins and themes are often being developed primarily on GitHub, other work on Core is generally not (although [https://make.wordpress.org/core/2015/09/21/wp-rest-api-merge-proposal/ this may change]).
While there is no official wordpress-develop Git repo on GitHub (yet), anyone can clone the [https://make.wordpress.org/core/2014/01/15/git-mirrors-for-wordpress/ wordpress-develop Git repo] and push it to GitHub. Teams working on various components can then work in the context of those GitHub clones, and then when work is complete a committer can apply the patch to SVN. Travis CI is already configured in the wordpress-develop repo, and so anyone who clones the repo to GitHub can automatically turn on Travis CI to start getting automated build checks for each commit.
Work on GitHub is usually done in the context of pull requests, and Travis CI can be especially useful when running in response to a pull request being opened or a commit pushed to a feature branch with an existing pull request. As reported in #30017, many automated tests are unnecessarily slow. This is in large part because with each commit, _all_ checks are being made across all files in the project, irrespective of whether they were recently modified or not.
When Travis CI does a build in the context of a pull request, it makes available the branch checked out and the branch being merged into, and with these two refs in hand, we can gather a list of the files (and patches) that were specifically changed. When we have these, we can optimize Travis CI to only run the checks that are relevant to the changes in the feature branch. For instance, if no PHP files were changed, then all of the jobs that run PHPUnit tests can be cancelled. If no JS files were modified, then the JSHint checks can be skipped.
It can be [https://make.wordpress.org/core/2013/11/13/finding-fixing-javascript-errors-with-jshint/ painful] to introduce new automated checks to WordPress because they can add a lot of noise for automated tests and fixing requires a touching a lot of files, possibly invalidating many pending patches. When Travis runs in the context of a pull request (or when automated tests are run when `trunk`/`master` is not checked out), then again, there is a diff available for the specific changes. We can introduce PHP_CodeSniffer for core (#30153) when Travis runs in in the context of a pull request, and it can skip reporting errors on any lines that aren't modified in the commit. This is likewise how JSCS linting can be added (#31823).
For existing code which causes Travis CI to only report coding standard violations to lines changed, see https://github.com/xwp/wp-dev-lib/blob/master/travis.script.sh when `$LIMIT_TRAVIS_PR_CHECK_SCOPE` is `patches`.
For commits pushed to `master` on Travis CI (outside the context of a pull request), it may make sense to configure Travis to check for changes made since the last major release." westonruter
Noteworthy 34679 Replace use of wp_get_http() in the WordPress Importer Import 4.4 lowest minor 8 WordPress.org defect (bug) reopened 2015-11-13T22:39:41Z 2016-09-26T14:49:44Z "It's been deprecated since r33969
Previously discussed in https://core.trac.wordpress.org/ticket/33709#comment:10
Reported in https://github.com/wp-cli/wp-cli/issues/2205" danielbachhuber
Noteworthy 36281 Importer Fails to import menu items in PHP7 boonebgorges Import 4.0 normal normal 3 WordPress.org defect (bug) assigned 2016-03-21T03:09:04Z 2016-09-30T04:10:40Z "The WordPress Importer plugin fails to import menu items at all with PHP 7 (any WP version). It's a pretty quick fix, though.
I noticed this as part of writing a fix for the importer on wp-cli:
https://github.com/wp-cli/wp-cli/pull/2545#issuecomment-199026539
But it was noticed by others, a couple months ago, and a fix provided:
https://wordpress.org/support/topic/importer-fails-to-import-menu-items-in-php7?replies=6
Since PHP7 has now been officially released for a few months, we're going to see more and more PHP7 installs pop up.
To sum it up:
wordpress-importer.php on line 798
Change:
{{{
$$meta['key'] = $meta['value'];
}}}
To:
{{{
${$meta['key']} = $meta['value'];
}}}" mightyturtle
Noteworthy 17191 Importing the same content duplicates your custom menus rmccue Import 3.1 normal minor 3 WordPress.org defect (bug) reviewing 2011-04-20T15:03:40Z 2015-10-27T06:45:41Z "When I import from one site to another, the importer will notify you if you have duplicate posts but will not import them, as expected, but it does duplicate your custom menu's.
I'm not sure if this is the desired result." zanematthew
Noteworthy 22041 Importer dies silently when multisite upload limit is reached Import normal normal 3 WordPress.org enhancement reopened 2012-09-28T17:58:57Z 2015-10-08T00:23:51Z "The scenario: You're importing a WXR file into a site on a multisite network and the WXR includes a number of large attachments. For whatever reason, the upload capacity for each site is set at 100MB.
If the upload capacity is reached during the import process, the import will look like it's hanging forever. Instead, it would be nice to show an alert that the upload capacity was reached or similar." danielbachhuber
Noteworthy 37052 Plugin search result count API showing wrong WordPress.org site normal trivial 3 WordPress.org defect (bug) new 2016-06-08T08:04:04Z 2016-06-08T17:20:55Z "When we search the plugin then the plugin search count is showing wrong `count`.
E.g.
- Search found 1 plugin then it showing 2 items.
- Search found 18 plugins then it showing 19 items.
---
I was be search plugin `MG Post Contributor` then it showing 2 `items`. Refer screenshot:
[[Image(https://c1.staticflickr.com/8/7661/27438240832_d614bd5b54_z.jpg)]]
After debugging, I found it comes from API.
`\wp-admin\includes\class-wp-plugin-install-list-table.php` **LINE - 208**
Snippet:
{{{
$api = plugins_api( 'query_plugins', $args );
}}}
On line `226` we set `total_items` using `$api->info['results']`
{{{
$this->set_pagination_args( array(
'total_items' => $api->info['results'],
'per_page' => $args['per_page'],
) );
}}}
Screenshot:
[[Image(https://c7.staticflickr.com/8/7443/27502714646_bdc94f6562_z.jpg)]]" Mahesh901122
Noteworthy 16147 MT Importer truncates double vertical spaces, munging paragraphs together Import 3.2.1 normal normal 2 WordPress.org defect (bug) reopened 2011-01-07T22:25:47Z 2015-10-01T17:33:38Z "Movable Type 3.x-era exports don't use '''

''' tags. Like TinyMCE (and WordPress), a '''

''' in final rendered code is represented by two '''\n'''s in a row.
The importer strips out double '''\n'''s and replaces with a single '''\n'''. This causes paragraphs to lose their distinction upon import.
It does this because the '''$line''' variable was created by '''$line = $this->fgets($handle)''' (line 339). Then '''$line = trim($line)''' (line 340) strips out several characters, including '''\n'''.
Lines 455 and 456 add back the '''\n''' ''except'' on blank lines:
{{{
if( !empty($line) )
$line .= ""\n"";
}}}
So if a '''$line''' was nothing but a '''\n''', it's stripped by the '''trim''' function and becomes a 0 character line. Then the '''if( !empty($line) )''' declines to add back a '''\n'''.
Somehow this needs to be altered so that successive '''\n'''s aren't stripped. Otherwise paragraphs get vertically munged together." novasource
Noteworthy 18602 Media Library imported, but all items Unattached Import 3.2 normal normal 2 WordPress.org defect (bug) new reporter-feedback 2011-09-06T10:10:18Z 2015-09-02T04:02:25Z "Export XML file from one site, import into another site. By checking ""Download and import file attachments"", files from wp-content/uploads are downloaded correctly to the new site, and added to Media Library. However all items in the Media Library are now ""Unattached"", and for example posts using [gallery] are broken on the new site. " awallin
Noteworthy 16404 WordPress Importer fails to import images Import 3.0.4 normal normal 2 WordPress.org defect (bug) new reporter-feedback 2011-01-29T00:42:28Z 2015-07-10T14:57:55Z "WordPress Importer fails to import images and update image src urls when download and import file attachments is checked.
WordPress MS with images in a post via Media using WP image mapping, e.g. image url: http://site.domainname.com/files/2011/01/myimage.jpg
Fails to download, import and update image src url. All image src urls remain intact from the old domain name.
If you change the image source to specific directory rather than the WP uploads directory: e.g. image url:
http://site.domainname.com/images/myimage.jpg
Images are downloaded and imported to media but it fails to update image src url in posts. All image src urls in posts remain intact from the old domain name.
I tested this on clean install of WP 3.0.4 MultiSite with TwentyTen theme and no other plugins activated." wlpdrpat
Noteworthy 23275 WordPress Importer: line-ending mismatch corrupts serialized meta Import normal normal 2 WordPress.org defect (bug) new has-patch 2013-01-23T16:56:04Z 2015-06-23T23:24:45Z "A possible solution:
{{{
if ( $key ) {
// export gets meta straight from the DB so could have a serialized string
if ( ! $value )
$value = maybe_unserialize( $meta['value'] );
// Occationally, line-endings break unserialize()
if ( empty( $value ) ) // Try normalizing...
$value = maybe_unserialize( str_replace( array(""\r\n"", ""\r"", ""\n""), ""\r\n"", $meta['value'] ) );
if ( empty( $value ) ) // Adjust string length if needed
$value = maybe_unserialize(
preg_replace( // e flag deprecated in PHP 5.5.0 I think
'!s:(\d+):""(.*?)"";!se',
""'s:'.strlen('$2').':\""$2\"";'"",
$meta['value']
)
);
add_post_meta( $post_id, $key, $value );
do_action( 'import_post_meta', $post_id, $key, $value );
// if the post has a featured image, take note of this in case of remap
if ( '_thumbnail_id' == $key )
$this->featured_images[$post_id] = (int) $value;
}
}}}" WraithKenny
Noteworthy 16460 Category/tag converter should support all public taxonomies Import 3.0 normal normal 2 WordPress.org feature request new has-patch 2011-02-05T04:56:39Z 2016-03-29T11:09:53Z The category to tag converter should let you convert terms to custom taxonomies, if any are defined. I'm attaching a rewrite of the plugin based on 1.5.2, which included support for post formats. sillybean
Noteworthy 18097 Themes update-check should check parent/child WordPress.org site normal normal 2 WordPress.org defect (bug) reopened 2011-07-13T10:19:33Z 2015-09-02T03:45:22Z "A child theme by the name of Commune gets served the updates of a parent theme.
We should only serve an update to a theme if it's a child or parent, appropriately. For child themes, we should also confirm the parent." nacin
Noteworthy 35974 `@param` tags with `&` in variable names are not parsed as parameters in the developer docs General normal normal 1 WordPress.org defect (bug) new has-patch 2016-02-27T06:16:25Z 2016-04-05T06:26:49Z "While documenting hooks, if `&` is added in the `@param` tag, then they are not regonized as parameters in the developer docs.
Eg: Look under parameter sub-heading in the following pages
https://developer.wordpress.org/reference/hooks/http_api_curl/
https://developer.wordpress.org/reference/hooks/posts_where/
and about a dozen pages where the parameters are not documented properly.
I did a full search in the code base for the regex 'param .* \&\$' and fixed those instances.
The patch I am attaching doesn't have any code changes. It only fixes phpdocs for the hooks who's parameters are not documented properly." sudar
Noteworthy 20881 Show code references in inherited localization files I18N normal normal 1 WordPress.org defect (bug) new 2012-06-07T20:01:31Z 2016-02-28T12:02:24Z "For example string ""Invalid post type"" is used several times - on frontend and also in admin. But this string is only in frontend localization file, because this file is also loaded on admin side. That is correct, no need to duplicate strings in different files. But translators do not see code references related to admin file and it can leads to context problems during translation.
It could be very helpfull to modify makepot.php to add related code references to generated .pot files.
Related example: #20809" pavelevap
Noteworthy 23482 Fix improper use of comment_exists() in some importers maxpagels Import normal normal 1 WordPress.org defect (bug) assigned has-patch 2013-02-15T18:49:18Z 2015-06-23T18:40:26Z "Background: #20494
DotClear Importer and TextPattern Importer treat the returned comment post ID as a comment ID: [[BR]]
http://plugins.trac.wordpress.org/browser/dotclear-importer/trunk/dotclear-importer.php#L416 [[BR]]
http://plugins.trac.wordpress.org/browser/textpattern-importer/trunk/textpattern-importer.php#L429" SergeyBiryukov
Noteworthy 24995 Importer does not check to see if DOM is available Import 3.6 normal normal 1 WordPress.org defect (bug) new 2013-08-08T20:55:34Z 2015-10-13T03:53:51Z "I have a WordPress network with many blogs. I exported a few posts from one blog (export file attached with some details sanitized). I then imported the posts into another blog.
Not only does the import probably do nothing, the '''/''blogname''/wp-admin/import.php''' page stops rendering after:
{{{

Import WordPress

}}}
That is, if you do a view source on the page, the above '''h2''' element is the last thing you see.
Expected behavior: execution does not stop mid-page, and if there is an error, it is displayed for logged-in administrative users.
I am logged in as a network administrator." novasource
Noteworthy 24729 "Legacy mention of ""admin"" account via import.php" rmccue Import normal normal 1 WordPress.org defect (bug) assigned has-patch 2013-07-11T20:44:52Z 2015-10-01T03:28:20Z "'First off, hello and apologies if I've submitted my first bug incorrectly - I did the recommended reading and searching but couldn't find this reported yet. Do let me know how I can improve for the next time!'
On /wp-admin/admin.php?import=wordpress - When importing a WXR file, once the file is submitted, the information prompt suggest assigning all posts to ""admin"". Since we no longer create this named account, perhaps this wording should be changed to eliminate any confusion?
Picture: http://instagram.com/p/bo5yrbCHZ_/" meaganhanes
Noteworthy 15760 "LiveJournal Importer mishandles some and expressions" westi Import normal normal 1 WordPress.org defect (bug) assigned dev-feedback 2010-12-10T04:45:17Z 2015-12-03T20:20:07Z "There is a note on plugins.trac ticket 1231 that says this should be handled in core.trac instead, so I'm cross-posting it here. The patch and ticket were originally added by a-bishop:
http://plugins.trac.wordpress.org/ticket/1231
Reproduction steps: 1. Create a LiveJournal? entry that has in it. Note that this is XML-ish 2. Try to use the livejournal-importer on this post.
Bug The gets ignored because the regular expression is too strict.
I've attached a patch that makes LiveJournal? Importer recognize the XML-ish version.
Patch:[[BR]]
http://plugins.trac.wordpress.org/attachment/ticket/1231/livejournal-importer.patch" designsimply
Noteworthy 34845 Serialized custom fields are ignored on import Import normal normal 1 WordPress.org defect (bug) new 2015-12-04T13:56:30Z 2016-01-15T15:15:42Z "Hi guys,
we would like to report a bug related with .xml file import. Data from our builder are stored in $items table. Post meta values entry are made with below code:
{{{
$new = wp_slash( $items );
update_post_meta( $post_id, 'mfn-page-items', $new );
}}}
And in accordance to your documentation https://codex.wordpress.org/Function_Reference/update_post_meta#Character_Escaping, we use ""wp_slash"" function. Table with data is saving and reading properly. The problem is when we export .xml file with Tools > Export and when we try to import data with built-in Tools > Import > WordPress option, serialised table is ignored and we get empty field.
We attach test, exported .xml file so you can check it yourself.
We would be grateful if you can have a look on it.
Thanks!" muffingroup
Noteworthy 22082 WordPress Import Tool loses the complete category hierarchical structure Import 3.4.2 normal normal 1 WordPress.org defect (bug) new 2012-10-03T01:53:05Z 2015-01-31T23:48:46Z "I have exported from my local laptop wordpress installation the posts I had. They have the following structure with categories:
{{{
language --> main category, parent
- source language --> for example AF
-- target language --> for example AFAR for Africans to Arabics
--- lessons
----- lesson 1 --> up to 100 lessons entries
-- next target language
}}}
and so on
this complete structure is lost after import - they are all changed to parent categories no single child category.
I will attach the export file." christian_gnoth
Noteworthy 21597 WordPress Importer $base_url index failed Import 3.4 normal normal 1 WordPress.org defect (bug) new has-patch 2012-08-15T18:30:11Z 2016-06-15T22:26:38Z "When XRS file without the site url tag is imported, it throws a notice. This patch allow people to upload hand-made and not-attached-to-any-site XRS file.
I came across creating a XRS file to import names of cities from Portugal to a specific custom taxonomy to some sites. This can reflect the necessity of this patch." lightningspirit
Noteworthy 31976 WordPress Importer ignores WP_TEMP_DIR in wp-config Import normal normal 1 WordPress.org defect (bug) new 2015-04-15T06:14:33Z 2015-04-18T03:25:24Z "I wanted to change the place of `/tmp` directory and defined WP_TEMP_DIR in wp-config.php,
`define ('WP_TEMP_DIR', 'DIRECTORY PLACE FROM ROOT');`
It's working for auto update, plugin update etc. But not for WordPress Importer plugin." mayukojpn
Noteworthy 23276 WordPress Importer: Update existing navs instead of new Import normal normal 1 WordPress.org defect (bug) new has-patch 2013-01-23T17:00:06Z 2015-09-02T01:10:55Z "A possible solution (reuses logic present in the code):
{{{
$menu_item_db_id = (int) $item['post_id'];
$original_object = get_post( $menu_item_db_id );
if ( is_null( $original_object ) ) {
$post_parent = (int) $item['post_parent'];
if ( $post_parent ) {
// if we already know the parent, map it to the new local ID
if ( isset( $this->processed_posts[$post_parent] ) ) {
$post_parent = $this->processed_posts[$post_parent];
// otherwise record the parent for later
} else {
$this->post_orphans[intval($post['post_id'])] = $post_parent;
$post_parent = 0;
}
}
// map the post author
$author = sanitize_user( $item['post_author'], true );
if ( isset( $this->author_mapping[$author] ) )
$author = $this->author_mapping[$author];
else
$author = (int) get_current_user_id();
$postdata = array(
'import_id' => $item['post_id'],
'post_author' => $author,
'post_date' => $item['post_date'],
'post_date_gmt' => $item['post_date_gmt'],
'post_content' => $item['post_content'],
'post_excerpt' => $item['post_excerpt'],
'post_title' => $item['post_title'],
'post_status' => $item['status'],
'post_name' => $item['post_name'],
'comment_status' => $item['comment_status'],
'ping_status' => $item['ping_status'],
'guid' => $item['guid'],
'post_parent' => $post_parent,
'menu_order' => $item['menu_order'],
'post_type' => $item['post_type'],
'post_password' => $item['post_password']
);
$menu_item_db_id = wp_insert_post( $postdata, true );
if ( is_wp_error( $menu_item_db_id ) ) {
$post_type_object = get_post_type_object( $item['post_type'] );
printf( __( 'Failed to import %s “%s”', 'wordpress-importer' ),
$post_type_object->labels->singular_name, esc_html($item['post_title']) );
if ( defined('IMPORT_DEBUG') && IMPORT_DEBUG )
echo ': ' . $post_id->get_error_message();
echo '';
}
}
$id = wp_update_nav_menu_item( $menu_id, $menu_item_db_id, $args );
}}}" WraithKenny
Noteworthy 21913 Detecting MIME Types in WXR Files Import 3.4.2 normal normal 1 WordPress.org enhancement new dev-feedback 2012-09-17T21:09:07Z 2015-05-12T08:23:00Z "In the process of creating a service to convert TypePad data to WXR formatted files, we've encountered some unique problems with TypePad data. Namely, many TypePad files are saved without file extensions, which prevents the existing importer from importing those files into the wp-content/uploads folder.
In order to import and rename these otherwise ignored files, we've created a patch for the WordPress importer that does the following:
1. If there is an attachment in the WXR and the importer is not able to determine the file type from the file name (ie missing extension), the patched version will make a light (body-less) request to the web server where the file is hosted for information we can use about the file. The things we're interested in are file type, size, and filename.
2. If the importer is processing an attachment under the above situation, and it is able to determine the file type, then it will rewrite the local version of the file to have the appropriate file extension.
This is a simple bit of code, but it makes a huge difference as TypePad saves without file extensions quite regularly.
We've attached our patch and a sample WXR file from ragsgupta.com, the Brightcove co-founder's blog." ReadyMadeWeb
Noteworthy 7543 Import TypePad data using AtomPub. westi* Import normal normal 1 WordPress.org enhancement accepted needs-review 2008-08-19T02:44:26Z 2015-12-03T15:36:00Z "First off, I want to mention that TypePad updated their AtomPub server a few days ago, and their server does not seem to be sending comments. With a little luck, my current code should work fine once that server starts functioning again, but for the time being I would highly recommend not committing this into core.
Instead, I'm hoping people can look over the code and offer suggestions for improvement, test results, etc. While the Summer of Code is officially over today, I will be working on this until the job is done.
Alright, now to what this is. As some of you may know, I've been working on an Atom Publishing Protocol ([http://www.rfc-editor.org/rfc/rfc5023.txt RFC 5023]) based importer this summer for the Google Summer of Code. The diff attached is the latest version of my work.
The advantages of using the Atom Publishing Protocol are as follows:
* Nothing has to be done in the old blogging software to prepare for import (no export files, etc). Users just enter their blog URL, username, and password and the importer grabs all of the data using AtomPub.
* More data is imported compared to the old importers, especially with TypePad. Post slugs, comments, trackbacks, tags, categories, excerpts, etc are all imported. Everything used for posts in MT/TypePad is imported using AtomPub.
* The Atom Publishing Protocol is an established standard. With the exceptions of tag additions (which don't necessarily need updates), the importer should not have to be changed and should continue working well into the future.
I should mention there is one drawback to using the Atom Publishing Protocol. For the time being, it appears pages can not be retrieved using AtomPub. They were retrievable a few weeks ago, and I'm currently talking with Six Apart to see what happened.
I would greatly appreciate any and all feedback. Let me know your suggestions, and I'll be happy to incorporate them." cavemonkey50
Noteworthy 16294 Remote WXR Import duck_ Import normal normal 1 WordPress.org enhancement reviewing has-patch 2011-01-19T01:02:00Z 2015-09-02T03:25:15Z The attached patch allows a user to submit a URL pointing to a WXR import file, rather then uploading it. The purpose of this is to allow people to import a WXR file that is larger then their server's max_upload_size/max_post_size php.ini settings. belaraka
Noteworthy 22994 Remove 'blogroll' from the import options nacin* Import 3.5 normal normal 1 WordPress.org enhancement accepted has-patch 2012-12-18T17:53:16Z 2015-10-03T19:55:26Z "Now that we've dropped links (#21307), we shouldn't encourage importing them. It'll just confuse the newbies.
This will require a change to http://api.wordpress.org/core/importers/1.0/, so while we can clean up /wp-admin/includes/import.php (attached) it won't matter till that's scrubbed. Maybe upgrade that to 1.1 so people who are on older WP are left alone?" Ipstenu
Noteworthy 23464 WXR importer: Poor UX when creating new user to import to Import normal normal 1 WordPress.org enhancement new 2013-02-13T07:05:33Z 2015-10-03T23:42:32Z "When importing WXR you are prompted to assign a user to which of the existing users the imported content will be assigned, but it is also possible to provide a name of a new user which will be created and the content then will be associated with it.
The new user functionality sucks
1. No email or password is required therefor the user for a while is missing data which is assumed to always exist for a user. In the end of the import there is a small notice about updating the user data, but it gets lost in all the output being generated during import
2. Processing does not stop if user creation had failed (I used hebrew characters for user name) and the imported content is assigned to the current user. WTF?
" mark-k
Noteworthy 24791 Map audio/video shortcode IDs on import Import normal normal 1 WordPress.org task (blessed) new 2013-07-17T21:39:47Z 2015-10-03T23:04:57Z See #24458. nacin
Noteworthy 28187 EOL of wp-config-sample is now somehow set to LF nacin WordPress.org site 3.9 normal normal 1 WordPress.org defect (bug) reviewing 2014-05-09T03:52:18Z 2015-12-16T10:09:12Z "EOL of wp-config-sample.php in the latest, 3.9.1 is now somehow set to LF.
Suppose to be CRLF. Please see #12775.
" tai
Noteworthy 23950 Company recognition WordPress.org site normal normal 1 WordPress.org feature request new dev-feedback 2013-04-05T15:13:24Z 2015-09-02T00:32:42Z "My company, and many others, have a policy of sponsoring WordPress community contribution, core and otherwise, by strongly encouraging employees to participate during paid company hours. I want to open a discussion on how this company contribution could be recognised, while not allowing ""corporates"" to take over the credits page on each release.
* Would greater recognition encourage your company to foster contribution?
* Should companies contributing employee time to WordPress, particularly core contributions, be recognised?
* How should companies be recognised?
* What are the pros and cons for the WordPress project in allowing this kind of recognition?
This follows a [https://twitter.com/jenmylo/status/320144575266160640 Twitter conversation] re showing company names in the WordPress credits page, and Nacin's suggestion to open this discussion." simonwheatley
Very Popular 12706 Custom post status bugs Posts, Post Types 3.0 normal normal 163 Future Release task (blessed) reopened needs-unit-tests 2010-03-25T14:41:39Z 2016-11-15T11:57:45Z "A developer should be able to register a custom post status using `register_post_status()`. The admin UI (including post submit box and quick edit) should reflect this new custom post status. Furthermore, there are many hard-coded references to 'draft' and 'pending' statuses in core that should properly use the post status API.
All existing arguments to `register_post_status()` should be fully implemented, should also support per-post-type arguments. As things get implemented across core, there will likely be a need for supporting capabilities and bits of API.
Related: #23169 (register_post_status_for_object_type), #23168 (unregister_post_status)." ptahdunbar
Very Popular 36335 Next generation: core autoloader proposal General normal normal 94 Future Release feature request new has-patch 2016-03-25T19:21:43Z 2016-12-03T03:50:02Z "Hello WordPress community. With this ticket I would like to get the debate of the last days about how to attract WordPress to developers (or the other way around?) to a concrete discussion on how a class autoloader could look like in WordPress core.
So when we start to think about some major improvements like in #36292, we should also take some time and talking about autoloading.
== Abstract ==
A class autoloader is a basic tool to separate code writing form code organization. It takes care about providing class declaration at the point they are needed. The fact that WordPress lacks of a core autoloader was one point mentioned in the debate on what developers [https://www.alainschlesser.com/attracting-developers-wordpress/ missing most with WordPress].
== Why we need an autoloader ==
Plugin authors using autoloaders these days. They even use composer for dependency management and ship their plugins with this dependencies. This practice [https://github.com/composer/composer/issues/3852 leads to trouble right now]. I'm convinced that in a long-range plan we even have to talk about how to deal with proper dependency management to overcome collisions. Having an autoloader in core is a precondition for this.
== How an implementation could look like ==
The following proposal follows a concept of separating the file locating and file loading process to avoid a violation of the single responsibility principle and to gain flexibility. All classes and interfaces are prefixed with `WP_Autoload_` to apply a pseudo namespace.
The main instance of this concept is the interface `WP_Autoload_Rule`. An autoload rule is against the client responsible for locating and loading a given class. The class is provided by its full qualified name. This leads to this interface signature:
{{{#!php
base_directory = (string) $base_directory;
$this->base_namespace = (string) $base_namespace;
$this->file_loader = $file_loader && is_a( $file_loader, 'WP_Autoload_Fileloader' )
? $file_loader
: new WP_Autoload_IsReadableFileLoader;
}
/**
* @param string $class (A full qualified class name)
*
* @return bool
*/
public function load_class( $class ) {
// performing the psr4 mapping here to get a $file
$file = '/whatever';
return $this->file_loader->load_file( $file );
}
}
}}}
Autoloading rules should depend on a file loader. The file loader receives a file name and loads it, if it is present.
{{{#!php
rules, TRUE ) )
$this->rules[] = $autoload_rule;
}
/**
* @param string $fqcn (full qualified class name)
*/
public function load_class( $fqcn ) {
foreach ( $this->rules as $rule ) {
if ( $rule->load_class( $fqcn ) )
break;
}
}
}
}}}
== Instantiate and propagate the autoloader ==
{{{#!php
addRule(
new WP_Autoload_Psr4Rule(
'MyPlugin\\'
__DIR__ . '/src'
)
);
} );
}}}
== Things to discuss ==
* The proposal uses [http://verraes.net/2013/09/sensible-interfaces/ sensible interface names] which I prefer over naming interfaces like `WhateverInterfaces`. As WordPress does not provide interfaces right now, this is just a suggestion.
* PHP class identifiers are case insensitive. That means `new MySql` and `new MySQL` will both work, if a class `mysql` is declared. The autoloader should respect this. Now, Psr4 is very wide-spread and encourage developers to use case sensitive autoloaders and [https://r.je/php-autoloaders-should-not-be-case-sensitive.html this is a problem]. How can we deal with this in a performant way?
* How should the WordPress core files be organized to work with the autoloader? Is it realistic to rearrange them, if not how could a corresponding `WP_Autoload_Rule` look like?
* What about compatibility with PHP 5.2.? The proposal uses `spl_autoload_register`. But before PHP 5.3.0 it is theoretically possible to deactivate the spl extension. In this case another implementation of `WP_Autolad_Autoload` would be necessary and maybe some adaptions to the other interfaces. But is this really the intention?
== Finally ==
Thanks for reading. Feel free to add your concerns, your opinions or even if I'm on a completely wrong train. In fact
I'm really interested in critic. To be clear, I don't want to push this proposal but I would like to see a proper
autoloader in core some day :)" dnaber-de
Very Popular 15311 dynamic image resize (on the fly) using already available functions Media 3.1 normal normal 78 Future Release enhancement new dev-feedback 2010-11-03T20:18:44Z 2016-09-09T19:15:27Z "The lack of a dynamic resize function in WordPress forces theme developers to register lots of image sizes for their themes to use.
One of the problems with this approach is that the server becomes full of image files that will be never used.
Another problem is that when someone changes their theme the image sizes simply doesn't match, forcing people to use a plugin to regenerate all image files, and once again lots of those files will never be used.
So theme developers right now are using some sort of image resizing script like timthumb that works outside of wp. I think it has many drawbacks comparing to a native implementation.
So I made a function that uses WordPress native image handling capabilities to resize and save those resized images for future use.
I use this for attached images as well as standalone files such as custom fields and other images.
What I want here is just to share my solution, and maybe we can someday put something like this into core (actually something better then this):
{{{
/*
* Resize images dynamically using wp built in functions
* Victor Teixeira
*
* php 5.2+
*
* Exemple use:
*
*
* "" width="""" height="""" />
*
* @param int $attach_id
* @param string $img_url
* @param int $width
* @param int $height
* @param bool $crop
* @return array
*/
function vt_resize( $attach_id = null, $img_url = null, $width, $height, $crop = false ) {
// this is an attachment, so we have the ID
if ( $attach_id ) {
$image_src = wp_get_attachment_image_src( $attach_id, 'full' );
$file_path = get_attached_file( $attach_id );
// this is not an attachment, let's use the image url
} else if ( $img_url ) {
$file_path = parse_url( $img_url );
$file_path = ltrim( $file_path['path'], '/' );
//$file_path = rtrim( ABSPATH, '/' ).$file_path['path'];
$orig_size = getimagesize( $file_path );
$image_src[0] = $img_url;
$image_src[1] = $orig_size[0];
$image_src[2] = $orig_size[1];
}
$file_info = pathinfo( $file_path );
$extension = '.'. $file_info['extension'];
// the image path without the extension
$no_ext_path = $file_info['dirname'].'/'.$file_info['filename'];
$cropped_img_path = $no_ext_path.'-'.$width.'x'.$height.$extension;
// checking if the file size is larger than the target size
// if it is smaller or the same size, stop right here and return
if ( $image_src[1] > $width || $image_src[2] > $height ) {
// the file is larger, check if the resized version already exists (for crop = true but will also work for crop = false if the sizes match)
if ( file_exists( $cropped_img_path ) ) {
$cropped_img_url = str_replace( basename( $image_src[0] ), basename( $cropped_img_path ), $image_src[0] );
$vt_image = array (
'url' => $cropped_img_url,
'width' => $width,
'height' => $height
);
return $vt_image;
}
// crop = false
if ( $crop == false ) {
// calculate the size proportionaly
$proportional_size = wp_constrain_dimensions( $image_src[1], $image_src[2], $width, $height );
$resized_img_path = $no_ext_path.'-'.$proportional_size[0].'x'.$proportional_size[1].$extension;
// checking if the file already exists
if ( file_exists( $resized_img_path ) ) {
$resized_img_url = str_replace( basename( $image_src[0] ), basename( $resized_img_path ), $image_src[0] );
$vt_image = array (
'url' => $resized_img_url,
'width' => $new_img_size[0],
'height' => $new_img_size[1]
);
return $vt_image;
}
}
// no cached files - let's finally resize it
$new_img_path = image_resize( $file_path, $width, $height, $crop );
$new_img_size = getimagesize( $new_img_path );
$new_img = str_replace( basename( $image_src[0] ), basename( $new_img_path ), $image_src[0] );
// resized output
$vt_image = array (
'url' => $new_img,
'width' => $new_img_size[0],
'height' => $new_img_size[1]
);
return $vt_image;
}
// default output - without resizing
$vt_image = array (
'url' => $image_src[0],
'width' => $image_src[1],
'height' => $image_src[2]
);
return $vt_image;
}
}}}
" vteixeira
Very Popular 21170 JavaScript actions and filters adamsilverstein General 3.4 normal normal 74 Future Release feature request assigned dev-feedback 2012-07-05T21:34:03Z 2016-12-09T20:24:48Z "The concept of adding JavaScript actions and filters has been tossed around for some time. We've experimented with various configurations of actions in both the fullscreen and customizer APIs, and they've proven their utility enough to graduate them to a core feature in their own right.
----
I think that a good events API should satisfy these parameters:
1. '''Support jQuery-style dot namespacing''' to allow functions to be easily removed.
2. '''Should (likely) support priorities.''' While seemingly random numbers aren't fun to use, it allows plugins to cooperate without having to know of each other's existence. We can't expect plugin authors to rearrange the array of callbacks.
3. '''Should ''not'' force functions to have unique IDs.''' Anonymous functions are extremely common in JavaScript — forcing them to be named is contrary to the nature of the language.
4. '''Should be structured as a mixin.''' The global event loop should be an instance of the core Events object. Using a mixin will allow developers to easily create event loops for their own plugins (to prevent polluting the global namespace — think about large plugins, like bbPress). An events mixin will also enable developers to create more powerful abstractions, such as observable values, collections, and pretty much any structural JS object you can dream up.
5. '''Should allow the looping process to be overwritten.''' This will result in less code and added flexibility. The only difference between actions and filters is how they handle the callbacks object. There are other types of looping processes that could be beneficial in JS. One example would be returning false if any callback returns false, which could be used to stop a process, much like the native event.stopPropagation method.
----
'''Why not use custom jQuery events?'''
Custom jQuery events are great when we need to trigger actions on a DOM element. Triggering plain events on the body element (or any other hidden element) is not performant — every jQuery event normalizes an DOM Event object, which we then completely ignore.
'''Should we require jQuery to use the API?'''
I'm not sure. jQuery.Callbacks may be a helpful solution here, provided we can properly integrate priorities and namespacing. jQuery.Callbacks also only requires jQuery.each and jQuery.extend, so writing a shim that doesn't use the rest of jQuery would not be exceptionally difficult. Either way, switching between one and the other as we develop should not be exceptionally difficult." koopersmith
Very Popular 20564 Framework for storing revisions of Post Meta adamsilverstein Revisions 3.4 normal normal 69 Future Release enhancement assigned dev-feedback 2012-04-28T08:51:36Z 2016-04-27T21:09:42Z "There are a couple of tickets that would seem to benefit from storing revisions of post meta (#11049, #20299). We had a need for this feature in our Carrington Build and RAMP products and built it a few years back.
It handles the storing of post meta along with revisions, as well as restoring those revisions when someone restores an older version of a post(/page/etc.). There is an API for registering the post meta keys you want to track revisions of, it does not track all post meta keys by default.
There are two versions of the code. The bare-bones revisions framework code is here:
https://github.com/crowdfavorite/wp-revision-manager [[BR]]
https://github.com/crowdfavorite/wp-revision-manager/blob/master/cf-revision-manager.php
while I started adding features to a version that would be more user-friendly plugin, allowing the users to select which post meta keys they want to track revisions for:
http://plugins.svn.wordpress.org/revision-manager/ [[BR]]
http://plugins.svn.wordpress.org/revision-manager/trunk/cf-revision-manager.php
If this would be a valuable addition to core, I'd be happy to help polish this up in whatever manner is most helpful. I'd recommend breaking out the code I started on for the admin form and having that be the extent of the ""revision manager"" plugin - basically it becomes a nicer UI for selecting additional post meta keys to track revisions for." alexkingorg
Very Popular 19627 Themes should be able to opt-in to a static front page Themes normal normal 68 Future Release feature request assigned 2011-12-21T01:42:05Z 2016-10-04T17:57:10Z "A theme should be able to register that they are designed to have a static front page by default. Core should then pick up on this as part of the activation process and allow them to pick or create a page, or ignore it and show posts on the front.
Twenty Twelve will most likely need this (http://wpdevel.wordpress.com/2011/12/20/default-theme-twenty-twelve/)." nacin
Very Popular 32417 Add new core media widget wonderboymusic Widgets 4.3 normal normal 54 Future Release feature request assigned needs-unit-tests 2015-05-16T03:14:25Z 2016-10-14T17:14:08Z Adding images to your widget areas is a common, yet currently incredibly tedious task -- you need to upload it in your media library, find the url, copy the url, and then manually add an image tag inside of a text widget. That's a lot to ask for a beginner user to do. We should include a default image widget in core to make this task easier. melchoyce
Very Popular 36292 Rewrites: Next Generation rmccue Rewrite Rules normal normal 53 Future Release feature request assigned 2016-03-22T06:38:33Z 2016-06-06T05:34:43Z "Let's start improving rewrites. The current rewrite system is outdated and clunky for modern development, and was one of the most complained about pieces of WordPress when I [https://twitter.com/rmccue/status/710460165879898114 enquired on Twitter]. Here's what I'd like to change.
== Part 1: Separate rules from WP Query ==
This has two parts. Firstly, we need to ensure any rule can be mapped to any set of arbitrary query parameters. Right now, this is quite hard to do for the more complex query parameters, such as [https://roots.io/routing-wp-requests/ date query]. Doing this will eliminate the need for temporary/intermediate query vars; these are typically used temporarily during the rewrite process, then changed into actual query vars in `pre_get_posts`.
The second part of this is breaking the interdependency between rewrites and the main query. Currently, it's not possible to have a page that doesn't generate a main query. #10886 has attempted to tackle this in the past, however has run up against problems. This is important for things like user profile pages, and can immediately be used in core for the REST API. The current solution for these is to hook in at `parse_request`, but this causes some hooks not to be run, and changes the overall flow of a WordPress request.
Part 1 will introduce a Rewrite Rule Interface that will allow better customisability of rules as well.
== Part 2: Ensure the rewrite process is DRY and testable ==
This part will decouple the rewrite process from the global state to ensure testability. @ericlewis has made a fantastic start on this in #18877, which works well with some of the refactoring from part 1.
In separating from the global state, we may be able to reuse `WP_REST_Request` as a more generic `WP_HTTP_Request` (it was designed for this from the start).
This should also start cleaning up the `WP` and `WP_Rewrite` classes as concerns get a cleaner separation. Currently the boundary between the two is pretty unclear.
== Part 3: Rework flushing ==
The `rewrite_rules` option and the flushing process are one of the toughest bits of the rewrite process. The fact with these is that they're a caching process that significantly predates transients and object caching. The reason flushing exists is to avoid regenerating expensive rules (like one-rule-per-tag) on every request, but we can create a better system using the newer tools available in core. An opt-in system for rewrite caching could potentially work well once we have a solid Rewrite Rule Interface that allows us to identify and group rules. (For example, a `WP_Rewrite_CachedRuleInterface`.)
#29118 digs into some past work on this front; automatically flushing rewrites is already possible.
== Other Changes ==
Note that these parts are in a rough order, and get more vague as they go on. We need to incorporate feedback after changes are made, and these changes might need to be reworked or rethought with previous feedback in mind. There are also other changes we may want to make based on feedback from the community.
" rmccue
Very Popular 8592 Private Pages not listed in the Parent dropdown SergeyBiryukov Posts, Post Types normal critical 51 Future Release defect (bug) assigned has-patch 2008-12-12T16:22:24Z 2016-12-07T21:28:45Z "Private pages are not available as a choice in the Parent dropdown of the Attributes module.
You should be able to create a hierarchy of private pages if you want to.
Tested with r10194." mtdewvirus
Popular 18909 Bundled jQuery UI should have CSS External Libraries 3.3 normal normal 46 Future Release enhancement assigned 2011-10-11T18:53:57Z 2016-02-22T21:29:23Z "Now that all of jQuery UI is in core, matching CSS should also be included for use in the admin in both color schemes.
Related: #17952" helen
Popular 18584 Nav menus need more hooks for extensibility (on admin page & in customizer) Customize 3.3 normal normal 44 Future Release enhancement new has-patch 2011-09-04T02:38:16Z 2016-09-16T05:56:38Z "I'm trying to add some additional fields to the nav menu blocks but sadly there are no hooks for doing so. Zero.
We should add some and get in a better habit of just doing so when the code is written.
My specific suggestions are before the Remove/Cancel links (i.e. for adding standard stuff), one above the ""original"" field, and one after those action links (to add more actions).
We need to account for both extending the menus admin page and menus in the customizer." Viper007Bond
Popular 23912 Add Composer package description Build/Test Tools 3.5 normal trivial 42 Future Release enhancement new 2013-03-30T20:44:16Z 2016-08-28T14:52:16Z "WordPress, as software download, lacks machine-readable source of meta information about it. For PHP projects de-facto standard for such is Composer via `composer.json` file in project root.
While WP currently doesn't use or need Composer dependency functionality, it will help provide information to developers and improve WP usage ''as'' dependency in projects that make use of Composer.
Suggested `composer.json` draft:
{{{
{
""name"" : ""wordpress/wordpress"",
""description"" : ""WordPress is web software you can use to create a beautiful website or blog."",
""keywords"" : [""blog"", ""cms""],
""homepage"" : ""http://wordpress.org/"",
""license"" : ""GPL-2.0+"",
""authors"" : [
{
""name"" : ""WordPress Community"",
""homepage"": ""http://wordpress.org/about/""
}
],
""support"" : {
""issues"": ""http://core.trac.wordpress.org/"",
""forum"" : ""http://wordpress.org/support/"",
""wiki"" : ""http://codex.wordpress.org/"",
""irc"" : ""irc://irc.freenode.net/wordpress"",
""source"": ""http://core.trac.wordpress.org/browser""
},
""require"" : {
""php"": "">=5.2.4""
}
}
}}}
" Rarst
Popular 14877 Ability to create exclusive custom taxonomies helen* Taxonomy normal minor 39 Future Release feature request accepted 2010-09-15T14:08:25Z 2016-08-31T22:00:22Z "Custom taxonomies should have the option of toggling exclusivity, meaning the user should only be able to select one term at a time.
Currently, developers wishing to implement an exclusive custom taxonomy (and thus would prefer radio buttons rather than check boxes on the add/edit post pages) must remove the existing taxonomy meta box completely and build their own, simply to change the input type. This not only duplicates code and development effort, but has the potential to create security vulnerabilities when plugin developers stray from best practices, for example, when recreating the AJAX add term functionality.
Exclusive taxonomies are not uncommon in every day life and are even more common when one thinks about typical custom post type implementations (e.g., students->school year, employee->department, car->color, ice cream->flavor).
While the best implementation is uncertain, I propose the function register_taxonomy accept an optional 'exclusive' argument (similar to 'hierarchical') that would change the check boxes within the taxonomy meta box to radio buttons and would handle the POST accordingly." benbalter
Popular 13239 Filter locate_template template_names variable Themes 3.0 normal normal 38 Future Release enhancement reopened has-patch 2010-05-03T21:43:05Z 2016-10-11T08:25:26Z "I recently encountered a situation where it would be very helpful to supply alternate template file locations; however, this cannot be accomplished as the locate_template function is being used and that function's arguments are not filterable. So, I created a patch that adds the filter.
This patch adds two filters: locate_template and locate_template-TEMPLATENAME. This allows for both general and specific filtering.
The following example shows how this could be used to modify the location of a BuddyPress template file.
{{{
function filter_member_header_template( $template ) {
return dirname( __FILE__ ) . '/buddypress/members/single/member-header.php';
}
add_filter( 'locate_template-members/single/member-header.php', 'filter_member_header_template' );
}}}
While the value of this example is debatable as BuddyPress could be updated to support alternate template locations, the value of the patch itself is high. This opens up a new ability for plugins to modify template file locations, giving plugins a hook into the content rendering process without requiring themes to be modified." chrisjean
Popular 19867 wp_dropdown_users() still not scalable Users 3.3.1 normal normal 38 Future Release enhancement new has-patch 2012-01-20T22:04:27Z 2016-12-07T04:47:28Z #14572 made huge improvements to the performance of wp_dropdown_users(), however, on certain sites that have an unusually large set of authors, wp_dropdown_users() still isn't usable. It either causes a memory error on the server, or potentially crashes the client browser due to content size. prettyboymp
Popular 16413 Settings page needs HTML refactoring and UI improvements helen Administration 3.1 normal normal 37 Future Release enhancement assigned 2011-01-30T20:22:09Z 2016-09-12T17:32:55Z "The settings pages haven't had much attention or improvement in a while.
We need to refactor the HTML on the settings pages, as they are still using tables instead of divs.
We also want to make some minor UI improvements including:
- clearer differentiation between option groupings
- using consistent text styles for descriptions and links (including the time zone/date format comment)
- restructure for better readability
Comment if you have any other" chexee
Popular 17268 Use native gettext library when available I18N normal normal 37 Future Release enhancement new has-patch 2011-04-28T11:32:30Z 2016-08-17T14:57:59Z "[http://codex.wordpress.org/Translating_WordPress Here] you say that the GNU gettext-Framework is used. Exactly, ""pomo"" (file: wp-includes/l10n.php) is a complete own php-implementation of the gettext-program.
I've added a patch to solve this problem. Maybe it is not very good, but it works. On my wordpress-sites, the used php-memory returns from about 65% to about 12% and the site is running much faster when patching wp-includes/l10n.php.
I know that gettext is not available on every wordpress-installation, but when it's available, it should be used.
Sorry for my bad english, I'm german." linushoppe
Popular 31245 Replace alloptions with a key cache rmccue Options, Meta APIs normal normal 34 Future Release enhancement assigned has-patch 2015-02-06T05:39:47Z 2016-10-27T15:57:03Z "Let's talk about `alloptions`. `alloptions` is a particularly fragile piece of WordPress, since it's exceptionally vulnerable to accidental concurrency issues due to its design.
A primer on `alloptions`, for those who haven't dug into it: `alloptions` is a cache key that stores all the options marked with autoload, thereby reducing the number of external calls out to an object cache from hundreds down to 1. It does this by running `SELECT * FROM wp_options WHERE autoload = 'yes'`, then storing that array (map of `option_name => option_value`) under the `alloptions` cache key. (Non-autoloaded options are stored as individual cache items instead, with a key of `option_name` in the `options` group.)
When you add an option, you can pick the `autoload` flag. This flag is `'yes'` (`true`) '''by default''', meaning most calls to `add_option` will set options to autoload. Additionally, if you add an option via `update_option`, there's no way to set this flag. These combined mean that the vast majority of options are stored in the `alloptions` cache.
== Why is this an issue? ==
The `alloptions` cache is loaded very early in the WordPress request lifetime. From this moment until the end of a request, option reads are taken from this cache rather than the database.
In addition, every time an autoloaded option is updated or deleted, `alloptions` is similarly updated. However, this means that on '''any''' autoloaded option being updated, '''every''' autoloaded option has its value set to the value at load time.
This is a huge concurrency bug, as it's very easy to run into accidentally. As a proof of concept, try updating two different options in two different requests at the same time, and you'll see that whichever ran first will lose the changes. (See #25623)
(We're running into this issue a few times a week, due to certain plugins running an `update_option` on a high percentage of requests. These plugins are obviously being dumb in doing so, but they're revealing the core bug quite nicely.)
== How do we fix this? ==
The biggest issue is that `alloptions` is a single cache item containing every option. If we reduce this to one cache item per option, the concurrency problem is then reduced to individual options (and can be mitigated in the places it actually matters, typically in plugins). Rather than storing all the options, we can instead cache the keys that matter, then grab the values for all of those at once.
This means that we may still have minor concurrency issues when adding and removing options, however these happen much less often than updating existing ones. In addition, the cache would now only be used to decide which options to load at the start of the request, so worst case scenario, you end up with extra object cache `get` calls. This is much better than the current case, where a concurrency problem can return incorrect data.
This change would require adding a `wp_cache_get_multi` to take full advantage of the cache, however compatibility could be shimmed here with a loop and individual calls to `wp_cache_get`. This '''would''' cause worse performance for object caches that don't support multi-get (or haven't been updated), but at the benefit of no longer returning potentially bad data.
There's a few things that need to be done for this:
* Add `wp_cache_multi_get`, and talk to object cache maintainers to update the popular ones to support it (Memcache, APC)
* Change `wp_load_alloptions` to pull from `alloptionskeys`, then run a multi-get on those
* Ensure `alloptionskeys` is a protected option name
* Store value caches per-key" rmccue
Popular 22249 Add ability to set or remove attributes on enqueued scripts and styles. Script Loader normal normal 34 Future Release enhancement assigned early 2012-10-21T23:29:13Z 2016-10-12T22:46:45Z "I think it should be easier to customize the loading of scripts and styles (easier to customize the markup generated by the script/style system). Proposed solutions:
'''Solution 1:''' Allow `wp_enqueue_script`, `wp_enqueue_style`, `wp_register_script`, `wp_register_style` to accept an array of attributes as the `$src` parameter. For example:
{{{
wp_enqueue_script( 'my-plugin', array(
'src' => 'http://example.com/js/app.js'
'defer' => ''
'data-my-plugin' => 'custom data attr value'
), array('jquery'), null, true );
}}}
'''Solution 2:''' Add a filter before the markup is generated that allows devs to filter the attributes while they are in array format. For example:
{{{
add_filter('script_loader_attrs', function ($attrs, $handle) {
unset ( $attrs['type'] );
'my-plugin' === $handle and $attrs['data-my-plugin'] = 'plugin data';
$attrs['src'] = remove_query_arg( $attrs['src'] );
return $attrs;
}, 12, 2);
}}}
In class.wp-scripts.php it might look something like:
{{{
$attrs = (array) apply_filters('script_loader_attrs', $attrs, $handle);
}}}
and/or:
{{{
$attrs = (array) apply_filters(""{$handle}_script_loader_attrs"", $attrs );
}}}
----
I imagine that solution '''2''' would be easier to implement than '''1''', and '''2''' allows for themes/plugins to modify scripts/styles w/o re-registering resources.
The key feature of both solutions is the ability to modify the attrs while in array format. There are other ways that one could achieve the same results, but the array is '''by far the cleanest'''. Dirty alternatives include:
* Use `preg_replace()` on the markup after it is generated (see #22245)
* Use output buffers and PHP's DOMElement interface
* Filter away the ""print_scripts_array"" and regenerate the markupmanually.)" ryanve
Popular 15691 Network admin should have its own settings API Plugins normal normal 33 Future Release feature request new dev-feedback 2010-12-05T19:31:17Z 2016-11-13T16:59:57Z preferably using options.php and the same API as normal admin, this way making a plugin multisite compatible (ie. adding a Network admin screen to it) would be much easier. joostdevalk
Popular 16841 Manually created user roles not showing in author dropdown regardless of assigned capabilities Role/Capability 3.1 normal normal 32 Future Release defect (bug) new needs-unit-tests 2011-03-12T23:39:39Z 2016-06-16T15:37:04Z "I posted the below on wp-testers hoping to verify or gain experiences from others in order to confirm this prior to reporting it as a bug, but, haven't received any further input, and it's just becoming more evident to me that perhaps it should be posted here, so, I hope I'm not creating a false report here. Please excuse me if I am.
I'm posting this as a link so that it will translate more clearly rather than just cluttering up this message with more text than necessary.
http://lists.automattic.com/pipermail/wp-testers/2011-March/014130.html
Upon further investigation I have also come across the following: #16451
I'm not an expert at debugging this sort of thing, but, I have attempted all within my knowledge thus far, and in looking at all of the returned objects and entries, the only difference I can spot between how the default user roles ( which show up properly in the dropdown ) and the custom created roles ( which do not ) are being returned is that the default user roles, editor for instance, correctly show the deprecated level_7 entry, and the custom user role ( with more assigned privileges than the editor ) does not show user levels in the capabilities array at all, and shows level_0 in the object.
This is leading me to think that perhaps there is something happening with those user levels in creating the author dropdown on the post editor that is blocking the custom user roles from showing up as expected.
When running the following code:
{{{
echo '

Capabilities assigned to the role of ' . $name. '

';
endforeach;
}}}
the default wp roles return the following capability value pairings
{{{
delete_published_posts 1
}}}
roles created with Justin Tadlock's members plugin return the following
{{{
delete_published_posts delete_published_posts
}}}
roles created manually in functions.php utilizing
{{{
add_role( 'test_role', 'Test Role' );
//saved and then removed before running the code below ...
$role = get_role('test_role');
$role->add_cap('read');
$role->add_cap('edit_posts);
$role->add_cap('edit_others_posts');
$role->add_cap('publish_posts');
$role->add_cap('read_private_posts');
$role->add_cap('delete_posts');
$role->add_cap('delete_private_posts');
$role->add_cap('delete_published_posts');
$role->add_cap('delete_others_posts');
$role->add_cap('edit_private_posts');
$role->add_cap('edit_published_posts');
}}}
return the following ...
{{{
delete_published_posts 1
}}}
but lack the user levels as mentioned above.
Let me know if there is any further info I can provide to help sort this out~
" 10sexyapples
Popular 20299 "Preview changes on a published post makes all post meta ""live""" adamsilverstein Revisions 3.3.1 normal major 30 Future Release defect (bug) assigned dev-feedback 2012-03-25T02:02:16Z 2016-07-04T21:05:42Z "Here's the use case. Client wants to preview an update to a published post (as the Preview Changes button correctly implies they can). This post has some important post meta that impacts that preview.
Here's the problem - because post meta is not saved to a revision (it looks for the ""real"" post), when the preview button is pressed, save_post runs, and saves the meta data to the real, published post, even though the user only intends to preview the change.
Without realizing it, the user has updated the published version. That can be prevented by not saving post meta to revisions (when using custom save_post hooks), but then there's no non-hacky way to actually preview the full changes.
I believe this bug has been present for a while, we just rarely use the Preview function on published posts, and when we do, probably never tested it with critical post meta." jakemgold
Popular 32678 Audit toolbar links and content helen Toolbar normal normal 30 Future Release enhancement assigned has-patch 2015-06-17T19:56:43Z 2016-11-26T02:17:32Z "We've done some tweaks here and there in the toolbar, such as changing where links go or adding/removing some, but I don't think we've really taken a wider view of its general contents since 3.2 in #17705. Right now, some links take you into the customizer context without warning (as do a couple in the admin menu), which is quite jarring. We need context for each link to be clearer, and a good hard look at how the toolbar actually gets used and if it's really working to help get users to where they need to go more quickly.
At the very least, for 4.3, we need to resolve the issue of mixing customizer links in with dashboard links." helen
Popular 20491 Introduce some JavaScript i18n functions swissspidy I18N normal normal 29 Future Release enhancement assigned has-patch 2012-04-19T18:50:24Z 2016-11-20T18:52:15Z "There's JavaScript code dotted around core that handles i18n in JavaScript (for example, localised thousands separators in the pending comment count). We should bring this together into a wpL10n JavaScript library that can be reused by plugins.
I've done some work on this and I'll get a patch up in the next day or so." johnbillion
Popular 12718 Better structure for admin menu Plugins normal normal 29 Future Release enhancement reopened dev-feedback 2010-03-26T01:05:37Z 2016-09-13T16:54:31Z "Currently, the global $menu variable is one big linear array:
{{{
$menu = array(
[2] => array('Dashboard', ...
[4] => array('', 'read', 'separator1', ...),
[5] => array('Posts', ...)
...
)
}}}
To allow plugins to add a menu item at the end of a group, we use a bunch of additional global variables that remember the last element in each group.
Also, we use arbitrary numeric indexes to specify the order of the items, instead of being able to position items relative to one another.
It's all very low level. Things would be a lot easier if we had an actual API for manipulating the menu items." scribu
Popular 21022 Allow bcrypt to be enabled via filter for pass hashing Security 3.4 normal normal 29 Future Release enhancement new dev-feedback 2012-06-20T01:34:26Z 2016-10-31T01:56:20Z "Hi,
following recent discussions on password security and how to best prevent any hackers can leverage password table they might have got I looked into the phpass used for WordPress.
While I in principle understand why WordPress uses the compatibility mode of it, I would like to see some flexibility for those who don't need the compatibility.
Thus I would propose to change in wp-includes/pluggable.php all occurances of
$wp_hasher = new PasswordHash(8, true);
to
$wp_hasher = new PasswordHash(8, apply_filters('phpass_compatibility_mode', true));
This would allow users to easily change via plugin from the ""not so secure"" compatibility mode (only salted MD5) of phpass to a more secure setting (bcrypt) in case no compatibility with other applications is required.
The plugin changing the encryption methog could then as easy as
function phpass_bcrypt() {
return false;
}
add_filter('phpass_compatibility_mode', 'phpass_bcrypt');" th23
Popular 7756 AJAX saving method instead of reloading the page Editor normal normal 28 Future Release enhancement new 2008-09-16T17:36:44Z 2016-02-08T11:14:52Z "Instead of using a traditional page refresh after saving a post, utilize AJAX, similar to how auto-saving already functions, to save the post.
this would help decrease the load on the server and enhance the user experience." jdingman
Popular 23314 Allow published posts to be revised without being updated immediately Revisions normal normal 28 Future Release enhancement new has-patch 2013-01-29T19:39:01Z 2016-01-29T18:48:20Z Two things. Let's allow contributors to submit changes for review to their published posts. Let's also allow users to make changes to their posts and pages and save those changes, without updating the published post or page. kovshenin
Popular 31696 Better select, multi-select, and autocomplete/suggestion inputs in the admin Administration normal normal 27 Future Release enhancement new dev-feedback 2015-03-19T16:47:15Z 2016-07-17T17:59:45Z "I know this has been brought up before, but can't find the original ticket. That said, a few months ago Helen brought up a potential integration of the Select2 library but, due to licensing issues, we were unable to proceed with it at the time ([https://github.com/select2/select2/issues/2468 GH issue]). The licensing issue has now been resolved and, since I've been unable to find the original ticket, I'm opening a new one along with a preliminary patch to add Select2 to core.
At the moment, this patch is based on a new CSS class (select2) being added to any select field that should implement the Select2 library. I've added it to the select fields on the Settings->General page as an example, but didn't want to implement it system-wide until the community had a chance to speak up RE: where does/doesn't Select2 belong, or should it actually be implemented everywhere. The language and timezone fields seemed an obvious choice given their inherent size, but things like the emoji field under Settings->Reading that have a finite number of options seem less obvious.
Discuss!" section214
Popular 22435 Export API Export normal normal 27 Future Release enhancement new dev-feedback 2012-11-13T16:41:55Z 2016-08-19T03:40:55Z "From experience and from tickets (#19864, #19307, #17379) it's evident that we need to update the export API.
High level goals:
* To be usable from different parts of the code. From the web backend, from a CLI script, from an async job.
* To allow more control of the output format – serve over HTTP, write a single XML file to disk, split it and write many smaller XML files, write a big zip with many XML files, etc.
* To allow exporting the data without querying all the posts at once, so that we can fit the exports to memory.
* Keep {{{export_wp()}}} for backwards compatibility without the need to keep all (even any) of its code.
Here's my idea for the part of the API 99% of the developers touching export would use and be happy:
{{{
#!php
'2011-10-10', 'post_type' => 'event', … ) );
backup( $export->get_xml() ); // string
$export->export_to_xml_file( 'mom.xml' );
send_to_mom_to_import( 'mom.xml');
$export->serve_xml(); // with all the headers and stuff
$export->export_to_xml_files( '/files/exports-for-my-awesome-website/', 'export-%02d.wxr.xml', 5 * MB_IN_BYTES );
}}}
Before I dive into implementation details (in the comments, not to pollute the ticket), I'd like to hear what use cases for extending this code you have in mind and where should we draw the line. Adding more output writers? Adding custom export data? Adding formats different from WXR?
" nbachiyski
Popular 22363 Accents in attachment filenames should be sanitized mikeschroder Media 3.4 normal critical 27 Future Release defect (bug) assigned has-patch 2012-11-05T15:51:12Z 2016-11-02T21:47:25Z "There is an inconsistency in the way WP is sanitizing post slugs and attachment filenames.
Sanitizing the post slugs is a Good Thing(tm) for non-english users who use diacritics in their post titles.
Example: If I write a post with the title ""Moiré patterns"", the actual page slug will be: ""moire-patterns"". The space is replaced with a hyphen, the ""é"" becomes ""e"". Even if I try to change the slug manually into ""moiré"", WP won't let me (for my own good, since that URL would break in lesser capable browsers).
For some reason, WP doesn't apply that error-correction to attachment filenames.
Example: If I attach a file named ""moiré pattern.png"", it gets renamed into ""moiré-pattern.png"".
We can see that the space (and some other forbidden characters) are corrected by `sanitize_file_name()`, but diacritics such as ""é"" or ""ä"" are left as they are.
Currently, most modern browsers are capable of displaying files with diacritics, but some of them still fail (most prominently, Safari).
For the sake of cross-browser compatibility, attachment filenames should benefit from the same safety measures that we apply for the post slugs (I guess that's the `remove_accents()` function)." tar.gz
Popular 20578 Allow users to delete a plugin without uninstalling swissspidy Plugins normal normal 26 Future Release enhancement reviewing 2012-05-01T01:18:35Z 2016-09-14T06:17:03Z Sometimes, a user may need to delete plugin files without deleting all the plugin data. scribu
Popular 12877 Modular themes: Apply template hierarchy to folders within a theme Themes normal normal 26 Future Release feature request new dev-feedback 2010-04-06T16:26:15Z 2015-10-04T03:50:37Z "Applying template heirarchy to folders within a theme will allow themes to be broken into modules, allowing theme developers to substantially reduce repeated code. This is an automated, complete version of the use of get_template_part() in Twenty Ten.
I've written posts on the [http://wp.me/pS0xt-1f justification for modular themes] and [http://wp.me/pS0xt-30 their potential to transform theme organization].
Based on [http://wp.me/pS0xt-3O my tests], these functions should cause no noticeable difference in performance.
The patch has the added benefit of creating an accurate global $wp_template_hierarchy object (and a getter method), so any plugin/theme can access the template hierarchy for $wp_query.
The patch introduces several new functions: get_template_module($folder), get_template_hierarchy(), update_template_hierarchy(), and 2 private functions.
Finally, the patch also add a 'locate_template' filter on $template_names at the beginning of locate_template(), and turns the large conditional in template-loader.php into a function: template_loader()." koopersmith
Popular 36534 Media Upload Issue Since 4.5 Upgrade joemcgill Media 4.5 normal major 25 Future Release defect (bug) reopened 2016-04-15T06:11:32Z 2016-12-01T09:17:42Z "Here is my problem: Since I updated to 4.5 yesterday, I can't upload certain image files. Every time I try, I get an error stating:
Fatal error: Maximum execution time of 30 seconds exceeded in /home2/scarlett/public_html/germany/wp-includes/class-wp-image-editor-imagick.php on line 358
I finally figured out that the problem is with the photograph's dimensions. All of the photos that won't upload were rotated from landscape to portrait on import. Their dimensions are 3000x4000 rather than 4000x3000 like the photos that I can still upload. After trying to save the photos without their metadata, turning off all plugins, and various other edits and experiments, it turns out that for some reason I only get the ""imagick"""" error on the photos that have a dimension of 3000x4000. Changing it to 2250x3000 (or anything less than 4000 for the height) allows me to upload them. I had no problem uploading files with this designation before I updated to 4.5. Everything else about the files is identical, and the file sizes do not conform to any kind of pattern and are not particularly large or small. As test, I tried to re-upload a photo that had this exact same ratio that I had uploaded successfully yesterday, and it would not upload today. This leads me to believe that there is something going on WP's end, since nothing has changed on the server side in the last 24 hours (and sadly my auto-backup was turned off somehow so now I am stuck with this)." unicornbacon
Popular 14459 Rotate Full Size Images on Upload mikeschroder Media 3.0 normal normal 25 Future Release enhancement reviewing has-patch 2010-07-29T23:16:17Z 2016-10-19T20:54:38Z "It may be worth a revisit to #7042. Some mobile devices that use WordPress for Android are not capturing images in the correct orientation, instead they are writing the EXIF orientation to the image instead (which is a standard method these days). In wp-android and other external clients that offer full size image upload, these images will not be rotated correctly upon upload.
Since most mobile users are on the go with no access to the wp-admin area to rotate the images themselves, it would work best if the image was rotated for them automatically.
Hopefully there's a solution that wouldn't strip the EXIF data, some way to copy the EXIF data before rotating, then save it back again?" mrroundhill
Popular 18322 The Road to Magic Quotes Sanity Bootstrap/Load 3.2.1 normal normal 24 Future Release defect (bug) new dev-feedback 2011-08-03T20:26:25Z 2016-04-07T07:51:14Z For back compat reasons, wp_magic_quotes() performs addslashes() on GPCS data. This is a pain, especially given that some core API expects slashes and some doesn't. In hopes of someday losing the automatic GPCS slashing, let's introduce a flag to turn off the slashing as well as slash and unslash functions that consult the flag. If slashing is on, these functions add and strip slashes. If slashing is off, they return data unchanged. Plugin authors can start using these functions and testing their code with GPCS slashing turned off and on. Eventually, GPCS slashing would default to off and all calls to the slash and unslash functions could be removed from core. ryan
Popular 33717 Send Notification Email When a Comment is Approved From Moderation swissspidy Comments normal normal 24 Future Release feature request assigned has-patch 2015-09-04T00:43:09Z 2016-08-21T19:45:22Z Currently in WordPress, commenters have no idea their comment is approved unless they visit the page often. When a comment is held for moderation, WordPress should send the commenter an email notification when their comment is approved. I'm using the [http://wptavern.com/an-easy-way-to-notify-users-when-their-comment-is-approved Comment Approved] plugin to add this functionality to WordPress but I really think it should be a core feature. jeffr0
Popular 35214 Custom Comment Types aaroncampbell* Comments normal normal 24 Future Release task (blessed) accepted 2015-12-24T00:28:11Z 2016-09-30T20:25:40Z "It's time to take another look at Custom Comment Types. We have a nice stable example in post types, but there's a '''lot''' to do here, so we'll use this as a centralized tracking ticket for everything. As such, I'm sure the description here will be fluid for a while as we figure out how much there is to do.
Here's a rough list of things that need to be looked at and addressed:
* UI/UX - In order for custom comment types to be really useful, we need to put some serious thought into the UI/UX surrounding comments in the admin.
* The `comment_type` field needs to start using `'comment'` instead of `''` for comments. This will mean an upgrade routine as well as some back-compat work.
* We need to decide what to do about non-default comment types in various admin areas (comments table, recent comments, etc). The thing that makes most sense is for `WP_Comment_Query` to be adjusted to only show default comment types (comments, pingbacks, and trackbacks) by default. Additional comment types would then be handled by whatever plugin or theme adds them. Unfortunately, this is a breaking change (comment:58:ticket:12668) because right now those areas show all comment types. Maybe we can create new management areas to be able to pull these out of the default one? Lets put our heads together.
* A lot of existing functions, like `comment_type()`, will need to be fixed to make room for newly registered comment types and their registered strings.
Previous tickets for history:
#25674
#12668
" aaroncampbell
Popular 15086 get_template_part() should let you specify a directory westi* Themes 3.0 normal normal 24 Future Release enhancement accepted needs-unit-tests 2010-10-10T21:36:45Z 2015-09-23T23:41:49Z "IT would be nice for `get_template_part()` to allow you to specify a directory to look for a file in. Right now you actually *can* do this, but it requires passing a 'slug' to the function like `directory/slug`. Since everywhere else in the code slugs are sanitized, this seems like an unexpected way to allow this functionality (I didn't realize this worked until @nacin pointed it out). Since this slug isn't actually sanitized at all, you can currently do `get_template_part( '../../../test' );` which seems rather unsafe (`get_template_part` should be able to include from outside the themes directory).
I suggest sanitizing $slug and adding a third [optional] parameter that allows you to specify the directory to look in. The directory parameter should be sanitized enough to not allow it to start with a . or a / (although this more likely belongs in `locate_template()` as something done to $template_name inside the foreach).
What does everyone think about this approach?
How many themes do we think are currently using the $slug parameter to specify a directory?
Right now the optional $name parameter is set up as a fall through, so if $slug-$name.php doesn't exist $slug.php is used. Should $directory be set up similarly ($directory/$slug-$name.php -> $directory/$slug.php -> $slug-$name.php -> $slug.php)?" aaroncampbell
Popular 33885 meta_form performs a potentially expensive query Administration 4.3.1 normal critical 23 Future Release defect (bug) new has-patch 2015-09-15T18:23:11Z 2016-08-18T00:50:20Z "This is a follow-up to #24498 and the research that @tollmanz did on the query used in meta_form. To summarize:
The query in meta_form can be incredibly slow on sites with a lot of post meta.
The solution to me seems to be to cache the query and update the cache of meta to use every time a new piece of post_meta is saved. This will prevent the query from needing to be run on sites with a persistent cache. " jorbin
Popular 34848 Add support for updating post meta in bulk chriscct7 Options, Meta APIs normal normal 23 Future Release enhancement assigned needs-unit-tests 2015-12-04T19:43:48Z 2016-10-10T13:46:03Z "A limiting factor in performance of inserting posts into the database is postmeta. I've been running a patch locally which adds functions for adding postmeta in one function call instead of calling add_post_meta multiple times over and over.
add_post_meta creates a single SQL insert query, when adding 20 post metas that is 20 SQL inserts all run separately. This can be greatly improved by combining these into a single SQL insert.
There is a problem where updating meta in bulk would likely be impossible or very painful. At the very least I have not been able to find a way to do this. Deleting I haven't developed a function but I imagine it would be fairly easy.
{{{#!php
/**
* Add metadatas to a post.
*
* @since x.x.x
*
* @param int $post_id Post ID.
* @param string $meta_data Metadata as an key/value pair array
*
* @return bool Was the data inserted
*/
function add_post_metas( $post_id, $meta_data ) {
// Make sure meta is added to the post, not a revision.
if ( $the_post = wp_is_post_revision($post_id) )
$post_id = $the_post;
return add_metadatas('post', $post_id, $meta_data);
}
/**
* Add multiple metadatas for the specified object. Similar to calling add_metadata for each metadata individually,
* and is only applicable for unique meta data. If a meta key already exists for an object it will not be stored.
*
* @since x.x.x
*
* @global wpdb $wpdb WordPress database abstraction object.
*
* @param string $meta_type Type of object metadata is for (e.g., comment, post, or user)
* @param int $object_id ID of the object metadata is for
* @param array $meta_data Metadata as an key/value pair array
*
* @return bool If the metadata was stored successfully.
*/
function add_metadatas($meta_type, $object_id, $meta_data) {
global $wpdb;
if ( ! $meta_type || ! is_array( $meta_data ) || ! is_numeric( $object_id ) ) {
return false;
}
$object_id = absint( $object_id );
if ( ! $object_id ) {
return false;
}
$table = _get_meta_table( $meta_type );
if ( ! $table ) {
return false;
}
$column = sanitize_key($meta_type . '_id');
/**
* Filter whether to add metadatas of a specific type.
*
* The dynamic portion of the hook, `$meta_type`, refers to the meta
* object type (comment, post, or user). Returning a non-null value
* will effectively short-circuit the function.
*
* @since x.x.x
*
* @param null|bool $check Whether to allow adding metadata for the given type.
* @param int $object_id Object ID.
* @param string $meta_key Meta key.
* @param mixed $meta_value Meta value. Must be serializable if non-scalar.
* @param bool $unique Whether the specified meta key should be unique
* for the object. Optional. Default false.
*/
$check = apply_filters( ""add_{$meta_type}_metadatas"", null, $object_id, $meta_data );
if ( null !== $check )
return $check;
$_meta_data = array();
foreach( $meta_data as $key => $value ) {
if ( 0 == absint( $wpdb->get_var(
$wpdb->prepare( ""SELECT COUNT(*) FROM $table WHERE meta_key = %s AND $column = %d"", $key, $object_id )
) ) ) {
$key = wp_unslash( $key );
$value = wp_unslash( sanitize_meta( $key, $value, $meta_type ) );
$_meta_data[ $key ] = maybe_serialize( $value );
/**
* Fires immediately before meta of a specific type is added.
*
* The dynamic portion of the hook, `$meta_type`, refers to the meta
* object type (comment, post, or user).
*
* @since 3.1.0
*
* @param int $object_id Object ID.
* @param string $meta_key Meta key.
* @param mixed $meta_value Meta value.
*/
do_action( ""add_{$meta_type}_meta"", $object_id, $key, $value );
}
}
$rows = array();
if( ! empty( $_meta_data ) ) {
$sql = ""INSERT INTO {$table} ({$column}, meta_key, meta_value) VALUES "";
$comma = false;
foreach( $_meta_data as $key => $value ) {
if( true == $comma ) {
$sql .= ',';
}
$sql .= ""({$object_id}, '{$key}', '{$value}')"";
$comma = true;
}
}
$result = $wpdb->query( $sql );
if ( ! $result )
return false;
wp_cache_delete($object_id, $meta_type . '_meta');
return true;
}
}}}
" patrickgarman
Popular 21488 Add Default Callback Functions for add_settings_field() Plugins normal normal 23 Future Release enhancement reopened dev-feedback 2012-08-05T23:22:00Z 2015-10-01T03:37:00Z "By default, when creating options in plugins and themes, every developer is required to create custom callback functions for rendering their option's HTML. The HTML for most options is nothing more than a standard INPUT field, a SELECT field, TEXTAREA field, etc, so there's really no reason there shouldn't be default callback options in place.
For example, if I have a plugin that registers one text field option in the General settings page, it really doesn't make sense that I should be forced to create a callback function, especially not when probably 99% of all text fields are outputted in exactly the same way:
{{{

The description of the field (if present)

}}}
With default field callbacks available, developers can do this:
{{{
function pw_register_settings() {
register_setting( 'general', 'pw_sample_option', 'esc_attr' );
add_settings_section( 'pw_sample_section', 'This is a Sample Section', 'pw_sample_section_cb', 'general');
add_settings_field( 'pw_sample_option', 'A Sample Setting', 'text', 'general', 'pw_sample_section', array( 'description' => 'The field description' ) );
}
add_action('admin_init', 'pw_test_settings');
function pw_sample_section_cb() {
// this is the section HTML (if you want it)
}
}}}
This is much simpler than also having to write the callback function to render the HTML for the option.
The patch attached adds the following default callbacks:
* text
* textarea
* select
* radio
* checkbox
* checkbox_group
For select, radio, and checkbox groups, the options are passed as an array of ""choices"" in the last, optional $args parameter for add_settings_field():
{{{
$options = array(
'one' => 'The Choice Name',
'two' => 'The Second name',
'three' => 'The Third option'
);
add_settings_field( 'pw_sample_option', 'A Sample Setting', 'select', 'general', 'pw_sample_section', array( 'choices' => $options, 'description' => 'This is a select' ) );
}}}
When a user wants to create a custom callback function, this is still allowed as call_user_func() is the default in the `$field['callback']` switch statement for the do_settings_fields() function." mordauk
Popular 26879 Friendlier welcome when installing WordPress Upgrade/Install 3.0 normal normal 23 Future Release enhancement reopened has-patch 2014-01-20T07:58:23Z 2016-08-08T05:04:00Z "When you first install WordPress, the very first interaction you have with WordPress is an error - by design.
The message is, ""There doesn't seem to be a wp-config.php file...."". The page title is ""WordPress > Error"". For new users to WordPress, this is an intimidating message suggesting that they have done something wrong.
This page hasn't been updated for a while. This ticket provides a more welcoming first page for new users.
Summary of Changes:
* Replaced error message with a more friendly message.
* Changes page title from ""WordPress > Error"" to ""Welcome to WordPress [version number]""
* Changed HTML div name from #error-page to #wp-welcome-page. Updated associated CSS.
* Added WordPress png and svg logo to top of page.
Please see attached screenshot of before and after.
" mrtortai
Popular 9757 Allow Plugin/Theme updates from a uploaded .zip file. Upgrade/Install 2.8 low normal 23 Future Release feature request new dev-feedback 2009-05-08T00:17:07Z 2016-09-23T10:26:04Z "Plugin administration lacks of an update possibility by uploading zip files. This feature is only half-done in 2.7, you can only upload plugins as zip to install them, not to update them.
Zip file uploads should be treated the same as the other install/update possibilities like remote.
#9708 provides a testcase that can be used to test such am update by zip.
currently a over-upload in the install page does throw an error that the directory already exists:
{{{
Installing Plugin from uploaded file: 9708-plugin-testcase-9708-plugin-a-v-0.2.zip
Unpacking the package.
Installing the plugin.
Destination folder already exists. [...]worpress-trunk/wp-content/plugins/9708-plugin-testcase/
Plugin Install Failed.
}}}
" hakre
Popular 20943 Paragraphs get removed in table cells when Visual editor is refreshed azaozz Formatting 3.2 normal major 22 Future Release defect (bug) reviewing 2012-06-13T19:06:04Z 2016-04-28T20:51:49Z "As far as I know, this issue has been around since 3.1. It's not a bug in 3.0.4. I even stopped upgrading at 3.0.4 for any sites where I knew the client would need to edit tabular data. For security reasons, it's time to upgrade these and I'd REALLY like this issue to be fixed.
The problem happens when using paragraphs in a table cell. When I hit enter to create a new paragraph within a table cell, it looks fine. If I then hit Update/Publish, when the page refreshes, WordPress converts that paragraph break into a single line break. If I then click Update again, WordPress removes that linebreak entirely and the paragraphs are essentially merged.
I can also reproduce this behaviour without even clicking Update. If you just switch to HTML mode and then back to Visual mode, the same issue occurs." JboyJW
Popular 28197 Fallback Languages I18N 4.0 normal normal 22 Future Release enhancement reopened 2014-05-09T20:53:44Z 2016-06-07T18:43:44Z "We should do a better job of loading translation files in the user's language if they are available.
For instance, if a Spanish speaker has their locale set as es_MX (Spanish Mexico) it would be preferable to load any available Spanish translations files (es_ES, es_CO, etc) before returning the default (generally English).
I wrote up a quick patch, tester plugin, and plugin that demonstrate this idea. If a $mofile is not available in the user's current locale, it will search for and return the first available translation that is also in the same language.
A better option might be to create a filterable stack rank of locales for WordPress to search for within the language before returning the default. Other suggestions are also welcome.
This idea was also discussed in an ""ideas"" thread:
http://wordpress.org/ideas/topic/fallback-to-generic-language-file-when-specific-locale-file-absent" downstairsdev
Popular 21810 Improve intermediate image size handling Media 3.5 normal normal 22 Future Release enhancement new 2012-09-05T20:28:14Z 2015-12-03T16:48:48Z "When discussing the new media workflows on #21390, the need to improve our image size API became apparent.
A quick overview of the improvements that should be made:
* All image attachments have an original, or ""golden master"", which is never altered.
* An image size creates a new image and stores all transformations applied to the image as metadata. Transformations are described relative to the golden master. An image size has a unique slug (which means a set of dimensions does *not* have to be unique).
* Image attachments have a ""master"" image size, which is used to create any automatically generated image sizes.
* Automatically generated image sizes can be overridden with manual transformations.
Would love for someone to step up on this ticket, as the media modal editing UI will benefit greatly from these improvements." koopersmith
Popular 32396 Settings Reduction chriscct7 Administration normal normal 21 Future Release enhancement assigned dev-feedback 2015-05-14T15:20:29Z 2016-11-09T17:56:04Z "One of WordPress's many core philosphies is decisions instead of options based on the majority. In recent years, WordPress has worked on simplifying the administration and new-to-WordPress experience. As a result of these talks, and my ongoing work on the ancient ticket report, we're proposing the removal of some of the lesser used options in WordPress core.
This ticket is strongly related to (#22942), where we're removing email to post for all installs from WordPress core, as it is inherently broken.
As part of the work into this ticket, several hosting providers have provided usage data for core options, specifically the % of installs where the value of the core setting is not on the default.
Here is an overview of the proposed movement of options:
Settings Removed:
- mailserver_url (post to email leaving core)
- mailserver_login (post to email leaving core)
- mailserver_pass (post to email leaving core)
- mailserver_port (post to email leaving core)
- default_email_category (post to email leaving core)
- default_category (moving to the post category page in #31483)
Possibly removed based on usage under 1% (from WordPress.com data, normalized) :
- avatar_default
- show_avatars
- avatar_rating
- default_post_format
- ping_sites
- posts_per_rss
Settings Under Consideration for Removal pending media numbers from GoDaddy + Page.ly:
- thumbnail_size_w
- thumbnail_size_h
- thumbnail_crop
- medium_size_w
- medium_size_h
- large_size_w
- large_size_h
- uploads_use_yearmonth_folders
- rss_use_excerpt
Settings Moved to General:
- posts_per_page
- page_on_front
- page_for_posts
- blog_public
The two options we have for each setting is to:
- Remove the setting (hide it) just for new installs (continue showing for existing installs)
- Remove the setting for all installs
For each setting, existing hooks can be utilized (as well as just a simple update_option call) to continue using the setting after it's been removed or hidden.
As it stands right now, the following option pages would not show for new installs (or if we decide to remove the settings existing ones as well):
- Writing
- Reading
- Media (pending data)
All settings pages would be mapped as was done previously for the privacy page in 3.5.
Thus any plugin currently hooking into any of the removed tabs would not be affected.
From a UX standpoint, the second most commonly used WordPress setting (behind site URL) is the posts_on_front/page_for_posts selector, currently on the reading page. Under this proposal, the option would be relocated to new installs (or existing if removal of tab for existing installs) to right underneath the site url field on the general tab which makes sense as one of the more used WordPress settings should be on the default settings page.
The goal is to finish getting usage data for the remaining settings this week, and to have a patch ready within the next 2 weeks. Decisions on whether to remove settings on existing installs will need to be made on an option by option basis and should be done as soon as possible to expedite the patch process. " chriscct7
Popular 21583 Improve discoverability and visual design of Screen Options and Help Panels Help/About normal normal 21 Future Release enhancement new 2012-08-14T22:34:05Z 2016-09-19T17:16:19Z "The Screen Options and Help panels are not very discoverable and, in part because of this, aren't very helpful to our users.
Here are the problems with them right now:
* Most users are blind to these tabs.
* The labels and positioning give little indication as to what these tabs actually do.
* For a lot of users, Help is not that helpful.
*They’re position in the admin creates yet another point of navigation for users to be aware of (and per #1, most of them aren’t).
* The very wide container for text makes a lot of the help text difficult to read.
Here are some proposals to improve the design and discoverability of these tabs (related images and mockups are here: http://make.wordpress.org/ui/2012/08/06/we-did-some-brainstorming-at-dev-day-today/) :
* Adding icons to these tabs would (hopefully) both make these tabs more visible and give a better indication as to what these tabs too.
* Moving these to the right side of the toolbar would give even more context to what these do, as they would be grouped with other user-specific settings.
* (6) The toolbar dropdown would allow for a slimmer content area for better readability.
* (7) The slimmer content area would let us make screen options read like a list for better scannability.
* (4/5) Putting the gear on the upper right would standardise with several other web apps (Twitter, etc).
Related: #21326" chexee
Popular 25239 $_SERVER['SERVER_NAME'] not a reliable when generating email host names SergeyBiryukov Mail 3.8 normal normal 21 Future Release defect (bug) reviewing dev-feedback 2013-09-06T14:05:28Z 2016-12-02T15:07:09Z "For quite some time I have been having an issue with my comment notifications. The From address has been wordpress@_. I haven't paid much attention to this, but I had some spare time and decided to pursue the issue. Here it is...
I am running WPMS w/ domains (latest stable) with Nginx and PHP5-FPM. In WordPress the comment notifications from email addresses are being generated using `$_SERVER['SERVER_NAME']` to get the current site's domain name.
e.g.
{{{
$wp_email = 'wordpress@' . preg_replace('#^www\.#', '', strtolower($_SERVER['SERVER_NAME']));
}}}
However, because of my environment my Nginx config for my site has the server_name set to ""_"" (underscore). Which is a catchall -- http://nginx.org/en/docs/http/server_names.html.
Site config in Nginx:
{{{
# Redirect everything to the main site.
server {
listen [::]:80 default_server;
listen [::]:443 ssl;
ssl_certificate /etc/nginx/ssl.crt/xxx.com.2012.crt;
ssl_certificate_key /etc/nginx/ssl.key/xxx.com.2012.key;
server_name _;
root /var/www/xxx.com;
access_log /var/log/nginx/xxx.com.access.log;
error_log /var/log/nginx/xxx.com.error.log;
client_max_body_size 100m;
if ($http_host = ""www.xxx.com"") {
rewrite ^ http://xxx.com$request_uri permanent;
}
include global/restrictions.conf;
# Additional rules go here.
include global/wordpress-ms.conf;
}
}}}
The default fastcgi_params has this set:
{{{
fastcgi_param SERVER_NAME $server_name;
}}}
Thus, `$_SERVER['SERVER_NAME']` is outputting ""_"" (underscore).
I propose we move away from `$_SERVER['SERVER_NAME']` when generating the from email addresses and use the available $current_site global object which stores the domain variable ($current_site->domain). I have implemented this change on my own site and have included the patch here.
In the meantime, anyone else facing this problem can change their fastcgi_param to $host instead of $server_name. In my opinion, not the best solution, but it works for now." layotte
Popular 28521 FORCE_SSL constant for really forcing SSL Security normal normal 21 Future Release task (blessed) new 2014-06-12T22:50:16Z 2016-04-10T01:22:57Z "Previously: #27954.
As per [https://make.wordpress.org/core/2014/06/11/ssl-taskforce/ this post on make/core and its comments], we should introduce a new constant which becomes the iron-fisted ruler of HTTPS, imposing its might everywhere it can.
If this constant is set, we will:
* Force `https` connections (pretty much covered by #27954)
* Force local URLs within content to `https`
* Force local enqueued scripts and styles to `https`
* Force non-local enqueued scripts and styles to `https`
* Set the `secure` flag on all cookies
What we won't do:
* Force non-local URLs within content to `https`
* Force the `https` version of oEmbeds just yet - see #28507
* Send an HSTS header - see #28520
What I'm not sure on:
* Should we force `https` connections for XML-RPC? See #28424." johnbillion
Popular 17379 Filtered exports drop attachments and featured images chriscct7 Export 3.0 normal normal 20 Future Release defect (bug) reviewing has-patch 2011-05-11T18:37:31Z 2015-11-01T16:23:23Z "When using Tools>Export, targeting a specific author, the resulting XML file does not contain a reference/link to any Featured Image (thumbnail) associated with these posts.
On the other hand, Tools>Export ""all content"" (including all authors) produces an XML file that does contain reference/link to Featured Image.
Request: Have Tools>Export ""specific author"" generate the same metadata as the ""all content"" export, so that Export ""specific author"" will also include metadata reference to the Featured Image.
Many people (including myself) use ""specific author"" as a way to export some, but not all, posts. Full metadata would really help. Thanks." billseymour
Popular 31071 media / post_mime_type related queries are very slow on larger sites pento Media 4.1 normal normal 20 Future Release defect (bug) assigned dev-feedback 2015-01-20T11:34:23Z 2016-09-22T22:09:33Z "Hey guys,
Remember #27985? It was about a slow query that did probably a full table scan, which was then replaced with two queries:
{{{
SELECT ID
FROM wp_posts
WHERE post_type = 'attachment'
AND post_mime_type LIKE 'video%'
LIMIT 1
}}}
{{{
SELECT ID
FROM wp_posts
WHERE post_type = 'attachment'
AND post_mime_type LIKE 'audio%'
LIMIT 1
}}}
On a busy server with 285k entries in wp_posts, this query is taking 5-7s each. And it takes forever to save/open an edit post screen.
The main problem is that there's not a proper index for it to use.
Running EXPLAIN shows this:
{{{
+----+-------------+----------+------+------------------+------------------+---------+-------+--------+-------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+-------------+----------+------+------------------+------------------+---------+-------+--------+-------------+
| 1 | SIMPLE | wp_posts | ref | type_status_date | type_status_date | 62 | const | 161195 | Using where |
+----+-------------+----------+------+------------------+------------------+---------+-------+--------+-------------+
1 row in set
}}}
I'm not really sure why such an unoptimized query would be put in place, but the index on (`post_type`, `post_mime_type`) fixes it:
{{{
+----+-------------+----------+-------+--------------------------------------+---------------------+---------+------+------+-------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+-------------+----------+-------+--------------------------------------+---------------------+---------+------+------+-------------+
| 1 | SIMPLE | wp_posts | range | type_status_date,post_type_mime_type | post_type_mime_type | 364 | NULL | 1 | Using where |
+----+-------------+----------+-------+--------------------------------------+---------------------+---------+------+------+-------------+
1 row in set
}}}
The query now runs in 0.2s." archon810
Popular 30262 Combine wp_terms and wp_term_taxonomy tables Taxonomy low normal 20 Future Release enhancement new 2014-11-05T19:01:10Z 2016-09-28T20:54:35Z "The two database tables `wp_terms` and `wp_term_taxonomy` are designed to facilitate ""shared terms"": single ""terms"" that are shared by multiple ""term-taxonomy"" pairs. In 4.1 we've begun the process of phasing out shared terms (#5809, #21950), and at some point we'll be able to guarantee that items in `wp_terms` are in one-to-one correspondence with those in `wp_term_taxonomy` (#30261). Once this has happened, we have no more need for two tables. So let's get rid of one of them.
The primary benefit of merging the two tables is that, over time, we can simplify the internals of much of our taxonomy API. No more JOINS will be necessary in `get_terms()`. There will be no need for `WP_Tax_Query::transform_query()`. And so forth. This will make the component easier to maintain, and will improve cachability and overall performance. A subsidiary benefit is that it makes the system a bit more sane for developers who are learning it for the first time.
The main concern in the process of merging the two tables is backward compatibility. As [https://make.wordpress.org/core/2013/07/28/potential-roadmap-for-taxonomy-meta-and-post-relationships/ outlined by nacin in 2013], we have a pretty good plan for how we can maintain close to 100% backward compat. Two parts:
1. The table aliases `$wpdb->terms` and `$wpdb->term_taxonomy` should point to the same merged table, which will include all columns from both existng tables. This will provide support for anyone using these aliases to perform taxonomy queries.
2. Create a [https://dev.mysql.com/doc/refman/5.0/en/views.html MySQL view] that replicates the deprecated table. This will provide support for anyone querying the table with syntax like `$wpdb->get_blog_prefix( $blog_id ) . 'terms'`.
We can't do the migration for at least a version or two after #30261 is complete - we have to give time to all installations to get their shared terms cleared out before we can think about putting the tables together.
A viable patch for this ticket will include: a schema change to introduce the view, the migration logic to move the old columns into the new combined table, and the necessary changes to `$wpdb`." boonebgorges
Popular 15317 My Sites limited to 23 sites on Admin Bar morganestes Toolbar 3.1 normal normal 20 Future Release defect (bug) assigned 2010-11-04T13:35:21Z 2016-05-20T16:17:18Z "I have a test site with 25 sites. I can only access 23 from the My Sites tab on the admin bar.
(This is a minor bug, but I hadn't seen it mentioned.)
Ron
I'm using latest trunk." ronbme
Popular 15058 Validate option and transient name lengths Options, Meta APIs 3.1 normal normal 19 Future Release enhancement new needs-unit-tests 2010-10-07T15:37:46Z 2016-01-08T21:41:48Z "The option_name column in the options table holds up to 64 characters yet there aren't any length checks to ensure that the length isn't exceeded. This leads to all sorts of odd behavior as the name will be truncated to fit, saving the option but not allowing it to be retrieved with the same name.
This issue affects all uses of the options system. A particular annoyance is transients. A transient that doesn't expire has a max name length of 53 characters yet a transient that does expire has a max name length of 45 characters. When attempting to save an expiring transient of name length between 46 and 53 characters, the transient will store but will be deleted before being used when get_transient is called due to the missing _transient_timeout_ option (since it was too long).
The core issues are that the functions don't return any type of failure condition on names that are too long and no warning is created. So, I've created a patch that addresses both of these issues.
The patch shows an example of how option and transient name length validation can be added. In order to allow users to modify the option_name column length, a new constant, WP_OPTION_LENGTH, is created with a default value of 64. This constant is checked for all length validation.
This is simply an example of how I'd like the validation to function. I'm not attached to the wording of the warnings or the name of the constant." chrisjean
Popular 9296 Settings API & Permalink Settings Page Bug jfarthing84 Permalinks 2.7.1 normal major 19 Future Release defect (bug) reopened 2009-03-07T05:33:55Z 2016-11-09T17:53:29Z Although there is a hook in the options-permalink.php to insert custom settings, it does not actually save any custom setting which is added to that page. Instead of posting to options.php like all the other options pages, it posts to itself and only handles the form data which is built into the wordpress core. It should be implemented on that page to also store custom settings that may be hooked onto that page. jfarthing84
Popular 12955 Add get_post filter Posts, Post Types normal normal 19 Future Release feature request new dev-feedback 2010-04-10T13:50:07Z 2016-11-19T01:25:24Z This patch filters the return value of the get_post() function. I would find this very helpful for a plugin I'm developing. JohnLamansky
Popular 31383 Add WP_Tax_Query support to WP_User_Query Query 4.2 normal normal 19 Future Release feature request new 2015-02-19T16:31:15Z 2016-10-20T19:26:39Z "Users like any other object type in WordPress can have taxonomy terms assigned to them. However, there is currently no way to query by taxonomies in WP_User_Query.
As far as I could find, the only way to really accomplish this right now is to use get_objects_in_term(), filter out the non user objects, and then use the include parameter.
Ideally, I think you should be able to accomplish this by the following:
{{{
$user_query = new WP_User_Query( array(
'tax_query' => array(
array(
'taxonomy' => 'tax_name',
'field' => 'slug',
'terms' => array( 'term-1', 'term-2' ),
)
)
) );
}}}" desrosj
Popular 27954 Add FORCE_SSL option to enable HTTPS everywhere on the site johnbillion Security 4.0 normal normal 19 Future Release task (blessed) reopened has-patch 2014-04-21T16:59:04Z 2016-10-07T16:46:38Z "We have the option to FORCE_SSL_ADMIN and FORCE_SSL_LOGINs, but not to FORCE_SSL for everyone everywhere.
Aside: It appears wordpress.com force's SSL everywhere" bryanquigley
Popular 18146 Add user-level timezone setting Users normal normal 19 Future Release feature request reopened 2011-07-17T06:25:21Z 2016-09-03T13:48:47Z "Timezone can currently only be set on the blog level. This makes sure that the blog displays times in the timezone chosen by the blog's owner.
It would also make sense to add a timezone setting for registered users, so we can show times in their own timezone, or use that setting as a default for new blogs or other features in a multi-site setting." RanYanivHartstein
Popular 38342 Quick Draft: Leverage REST API endpoints joehoyle Administration normal normal 18 Future Release enhancement assigned has-patch 2016-10-18T13:54:21Z 2016-12-09T19:05:19Z "If the REST API content endpoints were in core, how would we rebuild core features (like Quick Draft) to use it? I am opening this ticket to track work on converting the Quick Draft feature to using the REST API.
The quick draft feature is a meta box on the Dashboard for creating draft posts:
[[Image(https://cl.ly/0l1n311M3T1e/Dashboard__WordPress_Dev__WordPress_2016-10-18_09-37-07.jpg)]]
Quick Draft currently uses a simple form to post to `post.php` and create a the draft. The goal of this ticket would be to switch this action to JavaScript and the REST API. In addition, we would switch the list of recent drafts below the form to load via the API and render dynamically as well as adding a progress indicator and confirmation/error message. Note that the form is already hidden if JavaScript isn't available.
Aaron Rutley has already coded a POC version here: https://github.com/AaronRutley/quick-rest-draft
" adamsilverstein
Popular 27111 Turning off global comments should include existing content Comments 3.9 normal normal 18 Future Release enhancement new has-patch 2014-02-12T18:57:00Z 2015-06-17T10:02:46Z "People get confused when they turn off comments on a site, but continue receiving comment notifications. When a user sets the discussion setting to no longer allow comments to be posted to articles, it should turn off new comments on existing posts as well, not just new ones.
http://irclogs.wordpress.org/chanlog.php?channel=wordpress-dev&day=2014-02-12&sort=asc#m790178" jenmylo
Popular 13816 There should be built-in index pages for taxonomies Taxonomy normal normal 18 Future Release feature request new 2010-06-10T12:20:29Z 2015-01-20T06:52:13Z "By default, if you enable 'pretty' permalinks, you get URLs like this for categories and tags: /category/slug, /tag/slug. The same pattern is used when adding custom taxonomy types.
These URLs often suggest to people that it should be possible to go 'up' one level, and access index pages at /category and /tag which list all of the available categories or tags (or maybe just the top x most popular ones for tags).
I'd suggest that we add a new template type of is_archive_index() which uses, in order of preference, taxononmyname-index.php (eg category-index.php), archive-index.php.
Within these templates, the 'loop' should return taxonomy items rather than posts.
This is all possible already using custom templates and get_terms(), but it'd be handy if it was built-in.
" frankieroberto
Popular 34693 Add browser-based testing and automated acceptance tests (BrowserStack) jonathanbardo Build/Test Tools normal normal 17 Future Release enhancement assigned 2015-11-15T23:43:07Z 2016-02-25T14:24:14Z "Automated testing in WordPress is primarily focused on PHPUnit testing, with some JavaScript QUnit tests. While the PHP tests are run against every version of PHP since 5.2, the JavaScript tests are limited to one single browser environment (PhantomJS). This has meant that browser-specific bugs have been introduced (e.g. #30781) because manual testing isn't always performed in all the browsers that WordPress supports. We should connect WordPress unit tests with something like BrowserStack to run the QUnit tests in the various browsers.
While we're at it, the unit/integration testing in PHPUnit and QUnit only take us so far in WordPress as it is. What WordPress is missing are acceptance tests that fire up an actual browser to do actual tasks that users would perform when using WordPress. Such acceptance tests would make WordPress much more resilient against regressions, and it would open up a lot of new areas for automated testing that are currently very difficult to test using unit/integration tests. For instance, the Customizer heavily uses data from both PHP and JavaScript along with Ajax requests between the two. To create unit/integration testing mocks for PHP, JS, and Ajax requests adds a lot of testing overhead and is also difficult to maintain.
I believe acceptance testing would allow much more of WordPress to be tested automatically, and it would allow tests to be written by more people.
See also https://wordpress.slack.com/archives/core/p1419407324003594" westonruter
Popular 7665 Add jQuery UI's datepicker() where applicable chsxf Editor 2.7 lowest normal 17 Future Release enhancement assigned has-patch 2008-09-01T09:32:03Z 2016-04-13T18:23:49Z "Obviously it'll need some skinning, but it's handy dandy:
http://jqueryui.com/demos/datepicker/
It'd be slick to have that for choosing dates (for example publish dates). We should still allow manual entry though." Viper007Bond
Popular 27048 Export: Allow multiple post types to be selected Export 3.8 normal normal 17 Future Release enhancement new needs-unit-tests 2014-02-07T09:39:39Z 2016-01-29T17:09:01Z The export tool currently only allows for all post types to be exported, or for only one to be exported. I propose fixing this so that the selection is made via checkboxes and any number of post types can be exported. This will be beneficial in many use cases. hlashbrooke
Popular 17904 Multisite has more restrictions on user login character set jeremyfelt Login and Registration 3.0 normal normal 17 Future Release defect (bug) assigned has-patch 2011-06-27T11:09:12Z 2016-10-20T13:04:33Z "Multisite has more restrictions on the characters allowed in a user's login name compared to single site. This seems unnecessary and confusing. It was also the root of a recent bug in the importer, see [http://wordpress.org/support/topic/invalid-author-importing-single-wordpress-to-mulitsite-wordpress?replies=21#post-2186667 this forum thread] and the [http://plugins.trac.wordpress.org/changeset/401649 workaround].
I haven't worked up a patch yet since there seem to be a few locations where these restrictions are enforced and I don't know if I have found them all yet:
- wpmu_validate_user_signup() uses the regex `/[a-z0-9]+/`
- ms-default-filters.php adds `strtolower` to `sanitize_user`
Relevant: http://mu.trac.wordpress.org/changeset/1689 [12948]" duck_
Popular 22942 Remove Post by Email chriscct7 Mail 3.5 normal normal 17 Future Release enhancement assigned has-patch 2012-12-14T16:48:46Z 2015-10-20T04:38:43Z "We said last year that we'd remove the post by email functionality from core as it was better suited for plugins. The Jetpack plugin has already added this functionality and, honestly, includes better functionality than the core version.
We should move forward with our plans to remove this feature.
I recommend ''deprecating'' it similar to the way the link manager was removed in 3.5. Essentially:
* New WordPress installations will never see the core feature
* Existing installations that aren't using it won't see it any more
* Existing installations that ''are'' using it will see a notice explaining they should switch to a plugin instead as the feature will be completely removed in the future
Basically, I want the option to go away, but I don't want anyone to start a riot if we remove a tool they're actively using." ericmann
Popular 19629 return option for media_sideload_image Media 3.3 normal minor 17 Future Release enhancement new has-patch 2011-12-21T09:14:50Z 2016-11-27T08:27:50Z "An optional parameter to return the attachment id opposed to the html would be beneficial to those attempting to make use of this functionality outside of press this.
Ticket: #11993 has an enhancement suggestion to allow adding thumbnails from URL. I have written a solution for this enhancement, and the result duplicates the functionality of media_sideload_image() setting the post thumbnail opposed to returning the image html markup." slbmeh
Popular 12821 Merge get_posts() and get_pages() garyc40 Posts, Post Types 3.0 normal normal 17 Future Release enhancement assigned needs-unit-tests 2010-04-02T21:10:54Z 2015-12-22T21:08:45Z "get_pages() should wrap get_posts() the same way get_page() wraps get_post(). Arguments of different names need to be retained for back compat.
Reasoning for this includes #14823. Querying a nonhierarchical post type should still be allowed with child_of for example, to allow for cross-type relationships." mikeschinkel
Popular 18298 deprecate TEMPLATEPATH and STYLESHEETPATH wonderboymusic Themes 3.0 normal normal 17 Future Release enhancement reopened 2011-07-29T18:43:02Z 2016-08-05T03:20:40Z As part of #15086 we wanted to add unit tests, but we came across a problem in #UT22. Basically `locate_template()` uses these constants instead of `get_template_directory()` and `get_stylesheet_directory()` which makes it impossible to use `switch_theme()`. It looks like the constants are only used in about 20 places through core, so I recommend we fix those places and deprecate the constants. aaroncampbell
Popular 22277 Admin (not just superadmin) should be able to add user without confirmation email in multisite morganestes Users 3.4.2 normal normal 17 Future Release enhancement assigned dev-feedback 2012-10-25T18:04:19Z 2016-04-06T21:04:51Z I don't know why admins would be restricted from adding existing users without sending them a confirmation, but they are in multisite. You have to be a superadmin to get that option. I think that is lame, and would like to see admins have that admin option. Is there is a reason why it is that way (security etc)? Since neither @markjaquith nor I could remember a reason, making this ticket and hoping we fix it. jane
Popular 16020 Upload custom avatar for user in Dashboard nacin Users normal minor 17 Future Release feature request reviewing dev-feedback 2010-12-29T08:07:53Z 2016-12-01T22:52:15Z It would be nice to be able to upload a custom avatar for a user in the WordPress Dashboard rather than making each user sign up for a Gravatar account and upload the image to that account. computerwiz908
Popular 21666 Customizer reset/undo/revert Customize 3.4.2 normal normal 16 Future Release feature request new 2012-08-23T10:09:49Z 2016-04-18T22:25:58Z "It would be useful to be able to reset the settings to the defaults as specified in the add_setting() class method when setting up each setting.
These could be reset on a section by section basis and/or for ALL settings." dgwyer
Popular 17948 Enhancements to the login and registration forms wpdavis Login and Registration 3.2 normal normal 16 Future Release enhancement new 2011-06-30T16:25:01Z 2015-12-03T17:10:34Z "I would like to propose a significant overhaul of the registration and login forms for 3.2, which I'd be happy to take on. A few things that I think would be helpful:
Combine registration processes for multisite and single-user into one form on one page.
Allow the registration and login to be templatized — no reason this should be for MS only.
Standardize filters, actions and variables between MS and single-user when at all possible.
A few related tickets:
#17904
#17306
#17085
#16866
#16411
#17630" wpdavis
Popular 18493 HTML emails westi Mail 3.2 normal normal 16 Future Release enhancement reviewing 2011-08-22T00:29:44Z 2016-09-23T22:37:01Z "Wojtek worked on the Enhanced E-Mails project for GSoC this summer. It's definitely something that would be nice to have in core. The plugin already exists in the repository - [http://wordpress.org/extend/plugins/enhanced-emails/ Enhanced Emails]. There are still some things that need to be cleaned up in the code, but it works pretty well.
I'm hoping we can clean it up, test it, and get it in core. " aaroncampbell
Popular 28474 WordPress destroys animation in animated GIF when it resizes markoheijnen Media 3.9.1 normal normal 16 Future Release defect (bug) assigned has-patch 2014-06-06T20:12:39Z 2016-02-26T20:48:44Z When uploading animated GIFs to WordPress and then resizing them, the end result is the resized versions lose all frames and become static. This is a bug and should be fixed to allow animated GIFs to be resized properly. archon810
Popular 18408 Can't wp_reset_postdata after custom WP_Query in an admin edit page ericlewis Query normal normal 16 Future Release defect (bug) reopened 2011-08-15T02:38:07Z 2016-05-11T11:46:09Z "While on an edit post page (or any post type), if you create a custom WP_Query object before the editor has been output, the post data from the custom WP_Query will fill out the edit post form, not the original content of the post that is actually trying to be edited.
I found this out when trying to create a custom metabox in the 'side' context. You can reproduce this by inserting this code into a plugin:
{{{
add_action( 'add_meta_boxes', 'myplugin_add_custom_box' );
function myplugin_add_custom_box() {
add_meta_box(
'myplugin_sectionid',
__( 'My Post Section Title', 'myplugin_textdomain' ),
'myplugin_inner_custom_box',
'post',
'side'
);
}
function myplugin_inner_custom_box() {
global $post;
$a = new WP_Query('post_type=page');
while($a->have_posts() ) : $a->the_post();
endwhile;
wp_reset_postdata();
}
}}}
This happens because $wp_query->post is never defined in the admin load, which wp_reset_postdata relies on to reset the original post data.
I am attaching a patch that defines $wp_query->post after the $post global has been defined. " ericlewis
Popular 10726 Admin notifications for more than 1 email Administration 2.8.4 normal normal 15 Future Release enhancement reopened 2009-09-05T02:18:51Z 2016-03-17T00:45:27Z "Please allow admin notifications to go to more than 1 email address. It could be as simple as allowing a comma-separated list.
Better yet, allow sending '''admin''' notifications to all people in the '''administrators''' role." novasource
Popular 28050 Consider using Backbone Views for List Table updates Administration normal normal 15 Future Release enhancement new 2014-04-28T04:02:40Z 2016-06-29T17:11:20Z "List Tables are kinda clunky. (Duh!)
I just Quick Edit'd the first post in the list to have a date that is 1 month ago. Did the list table re-render? Not Really! Did the post move down the list? No!
If the list table class could return state via a `toJSON()`method, all that is left is rendering a master view template that contains subviews for each row.
Real time updates would be killer. Imagine real time searches...
I have been thinking about this a lot lately. If something sane emerges, it could be cool." wonderboymusic
Popular 22325 Abstract GPCS away from the superglobals Bootstrap/Load normal normal 15 Future Release enhancement new dev-feedback 2012-10-30T21:15:41Z 2016-04-07T07:50:13Z "As discussed at #wpcs, it looks like we want to move away from directly using the GPCS superglobals. This gives us a way to handle slashing backwards compatibility moving forward.
This is still a heap of versions away, but this is a way to keep any notes central." rmccue
Popular 33704 Reduce reliance on wp_is_mobile() adamsilverstein General 3.4 normal normal 15 Future Release enhancement assigned has-patch 2015-09-03T09:29:47Z 2016-10-17T16:59:21Z "User agent sniffing is bad. `wp_is_mobile()` isn't very reliable. In core it's actually used to detect if the device is a touch device (so that, among other things, elements that normally appear on hover are shown persistently and JavaScript for touch functionality is loaded).
We should audit the use of `wp_is_mobile()` in core to see if replacing it in favour of client-side feature detection is possible. If so, `wp_is_mobile()` should be deprecated.
Reported bugs with `wp_is_mobile()`: #24541, #21667, #24252.
History: #20014" johnbillion
Popular 23348 "Add a ""Contribute"" tab to the about page" Help/About 3.5 normal normal 15 Future Release enhancement reopened has-patch 2013-01-31T22:22:19Z 2016-10-26T17:43:54Z "The path to find out how to contribute is several levels deep in WordPress itself. Right now, you have to click on the W icon, then About WordPress, then the Credits tab, and then scroll down to the bottom of that page to see a micro link in the footer: Want to see your name in lights on this page? Get involved in WordPress.
Also, only Core Contributors are on this list so it gives a false promise of being listed on this page if you contribute which is not the case.
We discussed adding a link in #wordpress-sfd and everyone thought this would be a good idea so that more people could find out how to get started in contribution.
I am new to creating tickets so please let me know if there is any other information you need!" mt_suzette
Popular 17255 More statuses (like draft and/or private) for media files Media 3.1 normal normal 15 Future Release defect (bug) new 2011-04-27T11:48:11Z 2016-09-29T02:17:53Z "It's weird that media files don't carry any concept of pub status. If someone wants to upload files (either attached to a post or directly into the library), they should be able to keep them hidden via 'draft' status just like any other content. The fact that people can link to things that haven't been explicitly published is bizarre.
Media files should have a pub status. If uploaded as post attachment, should inherit publish on post publish. Would then need a workflow for if a post becomes unpublished containing media, as it then lives in library for use by other content, so would need to ask if user wants to unpub media files as well. This would be a big shift, so would make most sense as part of a media redux with a long notice period for plugin and theme authors. " jane
Popular 21668 WordPress does not save jpeg as progressive jpeg Media 3.4.1 normal normal 15 Future Release enhancement assigned 2012-08-23T16:44:06Z 2016-11-24T19:24:50Z "Every time WordPress does `imagejpeg` it should be doing `imageinterlace` beforehand to set progressive mode, but it's not.
http://php.net/manual/en/function.imageinterlace.php
Progressive jpeg has been supported by ALL browsers since 2001 or so.
progressive demo: http://bbshowcase.org/progressive/
Note that even if an ancient browser is listed somewhere as not rendering progressive, progressive jpeg still will be displayed, simply showing it all at once rather than gradual.
IE6 for example WILL load progressive jpeg, it will just not render it progressively, instead it will load the entire image and then render all at once at the end.
Progressive algorithm will also make slightly smaller jpeg as a side effect in most cases.
ie. in `media.php`
`
imageinterlace($newimage,1);
imagejpeg( $newimage, ...
`
This update is years overdue.
It might be possible to futureproof this by adding a filter to `$newimage` before the final `imagejpeg`. I am uncertain if that would work since filters would not pass `$newimage` by reference and instead make a copy - while newimage is only a pointer to php/gd memory. Can apply_filters be forced to work somehow by reference instead of a copy? Maybe that should be another feature idea.
" _ck_
Popular 13459 Conflict between post and page slugs/permalinks when permalink setting is set to /%postname%/ ericlewis* Permalinks 2.9.2 normal normal 15 Future Release defect (bug) accepted has-patch 2010-05-20T04:56:27Z 2016-09-12T03:49:26Z "If Dashboard -> Settings -> Permalinks is set to /%postname%/, it is possible to create both a page and a post with the same slug. When viewing via the frontend, the page is always displayed.
I would have thought that WordPress should prevent a post and a page from having the same permalink.
Steps to reproduce:
1. Create and publish a page with any slug. eg. http://domain.com/test/.
2. Create and publish a blog post with the same slug. Wordpress says the permalink for the blog post is http://domain.com/test/, but when you visit that URL it displays the page instead.
I can reproduce this on my 2.9.2 install, as well as 3.0 trunk. I'm guessing the bug is present in earlier versions of WordPress as well.
Possibly related: #11863" jamescollins
Popular 26937 get_adjacent_post() should use WP_Query rather than build its own SQL query nacin Query 3.7 normal normal 15 Future Release enhancement reopened 2014-01-25T18:51:47Z 2016-12-06T16:45:40Z "With the introduction of the `WP_Date_Query` through r25139, `get_adjacent_post()` no longer needs to build its own SQL to retrieve adjacent posts. By switching to `WP_Query`, we gain the benefit of its performance improvements, including native caching.
The trickiest part of this change is maintaining support for the `get_{$adjacent}_post_join` and `get_{$adjacent}_post_where` filters currently applied to the SQL built in `get_adjacent_post()`." ethitter
Popular 10201 Remove user-specific caps Role/Capability 2.8 normal normal 15 Future Release enhancement assigned close 2009-06-17T23:02:36Z 2015-12-03T20:04:43Z "See IRC discussions from June 18th 2009
* The current role system is rather complicated, But has a lot of flexibility
* A lot of the flexibility isn't even used by most (ie. the ability to have a user with a Roll + a single capability)
* The role system starts having trouble with a high number of users
* To look up every user with a certain cap. it requires loading all the users, and then checking individually.
The proposed changes are:
* That we reduce the complex system to something much more simple:
* Roles are retained: 1 role per meta entry, and since the meta API allows for multiple values for the same key, this would have the benefit of multiple roles, and direct lookups.
* However:
* Remove the ability for a user to be part of a Role, and have an extra capability added on top of that.
* This has the ability to significantly increase performance, As now:
* Looking up users with a specific cap is easy:
* Filter the role list for roles with that cap
* SQL the usermeta table for users in those roles
* Select those users (if needed, else return the ID's)
* An upgrade path is available which doesnt require extra tables, and reduces the ammount of serialization
* The other option is a whole new set of tables.. which.. those who are sane (And there are some insane people in WP Dev..) realise that its not really needed.
* Fine grain control has never been possible from WP without a plugin, Nothing would change here, If a user wants fine grained control over permissions, They'd still have to run a plugin, Its just that that plugin may have to do more heavy lifting now -- since wordpress's API/role system would be simpler and not support the extra fangledangles." Denis-de-Bernardy
Popular 24579 Add Drag'n'Drop UI to plugin and theme manual uploaders Upgrade/Install normal normal 15 Future Release enhancement new 2013-06-14T17:03:38Z 2016-11-29T10:09:32Z "We have this nice looking easy to use drag-n-drop UI for our media, is there anything stopping us from having it for our plugin and theme uploaders? I know most people use the search that goes through the .org repo, but it's foolish to think that's the only place people ever get their products. This would help facilitate a consistent user experience throughout the entire WP Admin.
Edit:
If possible, support multiple uploads too." tw2113
Popular 25052 Updates and downloads should be signed Upgrade/Install normal normal 15 Future Release enhancement new 2013-08-15T17:03:37Z 2016-11-21T22:30:07Z "Spin off from #18577.
We should sign updates and downloads (including themes and plugins)." samuelsidler
Popular 25449 wp_upload_dir() doesn't support https Upload 3.8 normal major 15 Future Release defect (bug) new has-patch 2013-09-30T13:11:15Z 2016-10-07T16:41:29Z "The wp_upload_dir() function does not support https. I have added a simple is_ssl() check and a string replacement to serve the correct URL type.
'''Background behind what prompted me to write the patch:'''
I read a blog post by Kaspars Dambis in which he discussed fixing this problem via his own plugin, but it seems to me that since WordPress outputting an incorrect URL, that it would make most sense to fix it there.
http://kaspars.net/blog/wordpress/minit-plugin-ssl-https
" ryanhellyer
Popular 12295 More support to customize user profile edit page nacin* Users 3.0 normal normal 15 Future Release enhancement accepted dev-feedback 2010-02-19T21:14:01Z 2015-02-02T10:34:43Z "Right now I can edit the contact methods via the user_contactmethods filter, but I can not modify or remove the Personal Options or the Name Options.
I want to keep the interface as simple as possible for my users, and I don't think that they need to edit this settings at all.
If wp wants to be a cms, it should give me control over this aspect as well.
At least, give me custom css-ids, so I can remove it via css!" pampfelimetten
Popular 33507 Allow widget controls to be JS-driven westonruter* Widgets 3.9 normal normal 15 Future Release enhancement accepted 2015-08-22T05:30:02Z 2016-10-07T03:57:24Z "Widgets currently have an almost complete reliance on PHP for all aspects of their behavior:
* Generating the control form via `WP_Widget::form()`
* Validating the instance data via `WP_Widget::update()`
* Rendering the widget into the template via `WP_Widget::widget()`
The dependence on PHP can make managing widgets in WordPress relatively slow. In the Customizer, it can be excruciatingly slow since the widget form control is presented alongside the widget in the preview, and so the slow roundtrip time for sanitization and rendering is clear (especially with full-page refreshes of the Customizer, which is to be mitigated in #27355 via partial refreshes).
In the Customizer, making a change to a widget form field results in an `update-widget` Ajax call to pass the full form data to WordPress to pass it through the widget’s `update` callback for sanitization. The Ajax handler then passes this updated instance through the `form` callback, and the HTML output of the `form` callback then gets sent back in the Ajax response. (Look at the number of Ajax requests triggered when typing into a widget field.) The Customizer widget logic then tries to apply the sanitized instance data by aligning the input fields in the widget form shown in the Customizer with the input fields sent in the Ajax response. When the input fields are aligned (when the same inputs are present), then the inputs’ values will be updated to their sanitized values and a `widget-synced` jQuery event is triggered. But if the inputs cannot be aligned (which can happen easily if any of the fields are created dynamically), then it falls back to showing an Update button which will do a full replacement of the widget form, just as is done on the widgets admin page (and a `widget-updated` jQuery event is triggered). Then finally, once the widget instance is updated, then the Customizer preview can do its full page refresh with the widget instance previewed in the template.
Most of the above logic can be eliminated entirely if widget controls handled rendering of the controls and sanitization of the instance data purely with JavaScript, just like every other Customizer control normally behaves.
Widgets would hugely benefit from a revamp following patterns laid down in Customizer controls. Customizer controls were designed to be JS-driven from the start. A Customizer control gets associated with a Customizer setting, the control then applies the setting data onto the control’s template and the inputs are automatically synced back to the setting—this is accomplished via two-way data bindings provided by `wp.customize.Element`. So controls in the Customizer handle UI validation purely with JavaScript. There is no need for an Ajax request because the logic is in the client. (True this means that the sanitization logic has to be duplicated in PHP and JS, but this can be minimized by adopting a common schema for the input types.)
Naturally these new JS-driven widgets would need to be backwards compatible with existing widgets. We can allow a widget to opt-in to indicate it is JS-driven by supplying a new flag to the seldom-used `$control_options` param to `WP_Widget::__construct()` (which is used to pass the infamous width/height for wide widget form controls), for example:
When this is present, the Customizer would disable the existing update mechanism and defer to the control’s own logic.
Note that these new JS-driven widget controls in the Customizer would be implemented in a very similar way to how nav menu item controls have been implemented in the Customizer in 4.3. The overall widget control would be associated with a single widget instance setting. The widget’s setting would be just the JSON-serializable instance array (object) as opposed to a scalar value, and each property in the setting value would then get mapped to a different `wp.customize.Element` in the widget control: the inputs’ values would then get synced back into property of the setting object value by means of `wp.customize.Element` instances.
Some widget controls would still depend on the server for UI validation, for instance the RSS widget. However, only specific fields would need to be validated as opposed to the entire form. Note again that full server-side validation of the widget instance data would still be required. Ideally the duplication of logic here could be reduced by having a schema that both the JS and PHP validation logic could read from.
While the above focuses specifically on making the `WP_Widget::form()` and `WP_Widget::update()` both JS-driven, there may also be an opportunity to allow widgets to opt-in to JS-driven rendering of a given widget (i.e. implementing `WP_Widget::widget()`, in JS). This would make a lot of sense if the widget defined its template in Mustache (or Twig) and then allowed the instance array to be applied to that template either server-side or client-side. The effect for client-side would be postMessage instant previews of changes to widgets in the Customizer. The PHP-driven performant alternative to this would be partial-refresh as outlined in #27355.
By using JS-driven widgets, we will be able to use control templates for the widget controls as opposed to having to include a separate copy of the widget form with each control's params. This can drastically reduce the page weight, since the control template only needs to be included once.
By implementing JS-driven widget controls, the user experience of managing widgets would be vastly improved and the server load would be greatly reduced.
Depends on #35574 (Add REST API JSON schema information to WP_Widget)
See feature plugin: https://github.com/xwp/wp-js-widgets" westonruter
Popular 35210 Add notification area to Customizer westonruter Customize normal normal 14 Future Release enhancement reviewing has-patch 2015-12-23T19:19:00Z 2016-11-15T03:27:59Z "There is currently no standard location for showing notifications in the Customizer, whether success messages or failures. Currently in the Customizer, if there is a failure to save due to a server error or connectivity problem, there is no visual indicator that a failure happened other than that the Save & Publish button doesn't get disabled. When an error does happen, there should be an error message displayed there.
In #34893, validation constraints are added to settings in the customizer. When validation constraints fail, the error messages should be shown in the notification bar. Likewise, in #34923 there is a proposal to be able to create new pages in the Customizer: the first iteration is just to add new blank pages with only the title supplied, and upon saving we need to be able to provide edit post links for those new pages so that the body content can be fleshed out. These links can be displayed in a notification bar. (These links can also be included in the nav menu item controls.)
The notification bar should facilitate plugins to inject their own messages and indicate failures vs successes.
Tickets dependent on the notification area:
* #29932: There is no error reporting in the Customizer
* #31582: Catching PHP Fatal Errors on WordPress Theme Customizer
* #34893: Improve Customizer setting validation model
* #34923: Introduce basic content authorship in the Customizer" westonruter
Popular 17128 POMO library performance considerations I18N normal normal 14 Future Release enhancement new has-patch 2011-04-13T20:21:18Z 2015-03-24T15:32:50Z "Profiling a localized WordPress instance with WPLANG defined as 'de_DE' on my testbed shows that loading the .PO files for WP core and TwentyTen increases the frontend runtime by about 45 percent and the backend runtime by about 30 percent.
This is the profiling environment:
* WordPress 3.2-bleeding r17633
* TwentyTen 1.1
* No active Plugins
* Idling webserver on localhost
* Apache 2.2.9
* PHP 5.2.6
* MySQL 5.0.67
* Xdebug 2.1.1
* webgrind 1.1
* Windows 7 SP1
Without WPLANG defined, runtimes for various code paths are as follows:
* Front page with 10 simple posts: 2300 ms
* Admin Dashboard: 3000 ms
* RSS XML feed output: 1130 ms
With the de_DE l10n in effect, runtimes increase as such:
* Front page with 10 simple posts: 4300 ms
* Admin Dashboard: 4280 ms
* RSS XML feed output: 2950 ms
I wonder whether anyone is able to reproduce this grave performance degradation. A sample output from webgrind showing various POMO functions as the top offenders is attached.
" wet
Popular 34109 Incorrect URL scheme for media in the admin area when using administration over HTTPS jeremyfelt Media normal major 14 Future Release defect (bug) assigned has-patch 2015-10-01T11:24:35Z 2016-10-07T18:53:59Z "It seems that we no longer have a ticket addressing this issue.
On a site where `siteurl` and `home` use the `http` scheme but `FORCE_SSL_ADMIN` (or `force_ssl_admin()`) is set to true, media in the admin area is incorrectly served with the `http` scheme and therefore produces mixed content warnings. When `siteurl` uses the `https` scheme, media is served over `https` as expected.
This affects the media library, the media manager, featured images, comments on attachments, actively editing an image on its attachment editing screen, and media-new.php.
Curiously, the attachment editing screen itself isn't affected until you click 'Edit Image', which means there's most likely a bug there.
This was previously tackled by #15928 ([31614]) for 4.2, but was reverted in #32112 ([32342]) for 4.2.2 because it resulted in media with the `https` scheme being inserted into post content, which is not desirable (eg. due to a self-signed cert or restrictions placed on access to the `https` host).
It's likely that altering the behaviour of `wp_get_attachment_url()` will have unintended consequences (as above), so we might need to consider the introduction of a new function which is used specifically for media item URLs in the admin context. The introduction of a `$scheme` parameter to `wp_get_attachment_url()` ''might'' work, but probably not." johnbillion
Popular 22938 Presentation of hierarchical taxonomy in Media modal should be checkboxes rather than comma-separated tag list wonderboymusic Media 3.5 normal normal 14 Future Release enhancement assigned 2012-12-14T14:10:16Z 2016-09-23T17:24:07Z Since 3.5, using register_taxonomy_for_object_type on attachments, if the taxonomy used is hierarchical, whereas in the edit attachment UI you see the normal list of checkboxes, in the corresponding modal it is presented as a comma-separated list of slugs, as if it were a non-hierarchical taxonomy (tags rather than categories). I'm sure this is not a bug / mistake / oversight, but at best it's a little unintuitive (you need to have memorised the category slugs to add new ones) and worst a bit dangerous (risk of adding unwanted categories), and it would be great if in future it was presented here too as a list of checkboxes. yeswework
Popular 14671 "Deprecate the ""accepted args"" argument in add_filter() and add_action()" Plugins normal normal 14 Future Release enhancement new dev-feedback 2010-08-22T20:00:17Z 2016-12-08T06:14:08Z "There is no harm in passing additional arguments to action/hook callbacks. Why do we force developers to explicitly ask for additional arguments to be passed? It is a maximum, and it doesn't matter if the maximum is exceeded. We can just pass all the arguments, all the time. Callbacks can use them, or ignore them. {{{add_action()}}} and {{{add_filter()}}} can lose their 4th argument.
Ran this by koopersmith and beaulebens, they couldn't find any reasons this would be a problem." markjaquith
Popular 9864 Performance issues with large number of pages Posts, Post Types 2.7.1 normal normal 14 Future Release defect (bug) assigned dev-feedback 2009-05-18T19:20:59Z 2016-12-07T21:15:19Z "'''Environment:'''
- Default install, default theme, no plugins, reasonable server configuration (typical execution, memory limits). In my particular case, that was set to 30 seconds, 384 MB.
'''To reproduce:'''
- Create a large number of pages (5,000+)[[BR]]
- Try to edit a page
'''What happens:'''
- Maximum execution time error
{{{
Fatal error: Maximum execution time of 30 seconds exceeded in \wp-includes\post.php on line 1998
}}}
'''Workaround to prevent error:'''
- set_time_limit to 0 as server admin
'''My diagnosis:'''
Suspect that the immediate problem is that get_pages() inside wp-admin/post.php, line 2173, performs a query that selects EVERYTHING:
{{{
$query = ""SELECT * FROM $wpdb->posts $join WHERE (post_type = 'page' AND post_status = 'publish') $where "";
}}}
Now, in this case this query (AFAIK) is just supposed to pull up the page list (with IDs, titles and parents). What it actually does is it pulls up ALL of the post data. This works fine for low number of pages, but on a larger data set this causes a chokepoint. After all, the end result is just supposed to be a dropdown with a list of pages.
'''Workaround to improve performance:'''
- comment out line 273 in wp-admin\edit-page-form.php and skip displaying the page parent in the edit screen
'''The bigger picture:'''
Well, the ENTIRE list of pages is queried in this 'edit page' screen (see screenshot # 2 - with a dropdown that contains 5,000+ entries.) I think this is a design limitation and it looks clumsy once the list gets larger. Rather than patch the display routines, I think this thing needs to be replaced with something that can search / paginate piecemeal server-side.
" pp19dd
Popular 12567 make post_submit_meta_box more generic Posts, Post Types normal normal 14 Future Release enhancement new 2010-03-10T00:46:20Z 2015-01-26T20:24:17Z "Currently there isn't a way to modify the meta boxes which set the post status. The function post_submit_meta_box in wp-admin/includes/meta-boxes.php is a closed function with post statuses hard coded. A new post status registered using register_post_status is available to the query object and plugins but cannot be added to the post status select box in the publish meta box.
A lot of the post_submit_meta_box is hardcoded to the default post status types.
Consider the use case where you want posts to only be visible to logged in users. A custom post status selectable by the user in add/edit post could be used which is then added or excluded in the query (filtered by posts_where) depending on whether the user is logged in or not. This way core can handle the non-visible posts the way private or future posts are handled. " themattharris
Popular 11302 Bulk editing posts should pre-fill fields with the same value / allow for removal Quick/Bulk Edit 2.9 normal normal 14 Future Release enhancement new 2009-12-01T20:48:41Z 2016-12-04T23:18:19Z "All I need is quickly move some posts from one category to another.
How to simulate this problem:
Create 2 posts in Uncategorized category.
Check both of them - Bulk actions - Edit.
There is no category selected even if both posts are in Uncategorized. When I check Category1 and click Update, both posts are now in Uncategorized and also in Category1. But no chance remove them from Uncategorized with Bulk actions." pavelevap
Popular 9547 Taxonomy - interesting 'unused' term_order column in table term_relationships. Taxonomy 2.8 high normal 14 Future Release enhancement assigned dev-feedback 2009-04-16T15:19:42Z 2015-12-13T07:48:49Z "During development of plugin [http://wordpress.org/extend/plugins/xili-language/ xili-language], and to sort term by term list of languages in a taxonomy, I discover unused column '''term_order''' in ''term_relationships'' table and lack of functions in core about this column. Like medias in post, here the user can define languages list with first, second, third,... languages for his website (and xml header). Taxonomy tools are here very powerful without adding tables or annoying coding.
([http://plugins.trac.wordpress.org/browser/xili-language/tags/0.9.8.2/xili-language.php see code here line 1309-1370]).
Before to complete these very basic functions,…
Is it forecast to have more basic / generic functions using '''term_order''' in taxonomy.php ?
[http://core.trac.wordpress.org/ticket/9546 Related ticket]" michelwppi
Popular 20875 Introduce wp_cache_get_multi() boonebgorges Cache API normal normal 13 Future Release enhancement assigned dev-feedback 2012-06-07T13:56:28Z 2016-09-07T20:41:49Z "Both options (see #10274) and themes (see #20103) could benefit from a cache backend that implements get_multi(). For options, this means we can use individual keys. For both themes and options, we'd be able to make fast multiple gets.
Both APC and Memcached (but not Memcache) implement multiple-get. A fallback would be looping over get().
Separately, as this would be a new function we use in core, we probably need to start doing some kind of versioning for drop-ins like db.php and object-cache.php." nacin
Popular 16557 Ability to disable redirect_guess_404_permalink() Canonical 3.1 normal minor 13 Future Release enhancement new dev-feedback 2011-02-14T12:37:02Z 2016-04-03T20:45:51Z "Can you make redirect_guess_404_permalink() pluggable or have its return value pass-through a filter so that developers can override it?
I know I can remove_filter('template_redirect', 'redirect_canonical') but redirect_canonical is too useful to be disabled. Only disabling URL guessing would be great.
Thanks a lot,
MK" msafi
Popular 29606 Reorder images via drag and drop is not working in WP 4 adamsilverstein Gallery 4.0 normal normal 13 Future Release defect (bug) assigned close 2014-09-09T19:56:57Z 2016-11-02T10:08:34Z "When I create a gallery and then try to reorder the images via drag and drop, it does nothing. In WordPress 3.9 it was working, but not in WP 4.
I have tried this with Firefox in a fresh WP installation with no plugins, using both twenty-fourteen and _s theme." gsarig
Popular 21352 wp_lostpassword_url() on multisite Login and Registration 3.3 normal normal 13 Future Release enhancement new 2012-07-23T15:58:23Z 2016-04-07T10:42:52Z "The wp_lostpassword_url() function on Multisite outputs the link to the primary domain not the current domain.
Although it works its not what should be expected if a user is registered to use blog ID 2 but not Blog ID 1.
The lost password email generated also links back to the primary domain not the current domain.
" philly max
Popular 3670 Removing CDATA close tag ( ]]> ) unbalances the CDATA block andy Posts, Post Types 2.1 normal minor 13 Future Release defect (bug) new needs-unit-tests 2007-01-25T05:55:47Z 2015-07-24T12:23:05Z "I'm
not sure if this is a bug per se, but it breaks included JS in my
posts that are escaped with a CDATA section. I've basically commented
out the following line in the_content() every time I upgrade:
//$content = str_replace(']]>', ']]>', $content);
A user on the wp-testers list indicated that this was part of making sure that included CDATA blocks didn't break RSS feeds. I don't use CDATA sections directly in my RSS feeds, so I haven't tested this. In my particular case, the JS is used to embed Flash movies (e.g. YouTube videos) in an XHTML compliant way (without embed tags). I have a custom plugin I've written that strips out the JS and replaces it with the embed tag in the RSS feed.
Perhaps we should use a flag to activate this when the app is going through a feed. Ideally, though, it would simply be removed. Odds are that the CDATA block is being used for a JS block in a post body, and since most RSS aggregators don't allow JS by default, it would be safe to simply remove CDATA blogs if is_feed() is set." scenic
Popular 5034 Impossible to have duplicate category slugs with different parents Taxonomy 2.3 high normal 13 Future Release feature request assigned has-patch 2007-09-21T19:29:20Z 2015-03-25T23:18:09Z "I'm using Wordpress as a CMS tool where categories are used as macro level grouping.
Windows XP -> Utilities
Windows Vista -> Utilities
This is no longer possible with WP 2.3, which ignores parent category when testing whether a slug is unique." snakefoot
Popular 27669 Stale `db_version` value after update with external object cache Upgrade/Install 3.9 normal critical 13 Future Release defect (bug) reopened has-patch 2014-04-04T13:00:53Z 2016-09-08T23:04:22Z "This is similar to #26173 but not quite the same.
My site runs trunk with the WordPress Beta Tester and Memcached plugins. The site just updated to [27916] and I'm getting the ""No Update Required"" loop which prevents any access to the admin area.
The `db_version` option in my database has been updated to the correct value (`27916`) but `get_option('db_version')` on any admin page returns a stale value (`26691`). Unlike #26173, the option has been updated with the correct value but the cache remains stale (instead of updating the option with a stale value).
On `/wp-admin/upgrade.php` the object cache is suspended so the non-stale value is returned, which results in the ""No Update Required"" message." johnbillion
Popular 35574 Add REST API JSON schema information to WP_Widget Widgets 2.8 normal normal 13 Future Release enhancement new needs-unit-tests 2016-01-22T12:24:06Z 2016-06-06T20:43:31Z "With the REST API, there is an emerging-established way in WordPress for describing a data structure, such as a widget instance.
One aspect of the REST API endpoint schema is the `default` values for given fields on a property. Widgets often have duplicated logic between the `WP_Widget::widget()`, `WP_Widget::update()`, and `WP_Widget::form()` methods for checking if a given `$instance` property has been set, and if not, supplying a default value. In some cases, these `isset` checks are ''not'' performed resulting in PHP notices if the methods are programmatically invoked with an empty array. With JSON Schema defined, we would provide `$instance` defaults upon which the current stored `$instance` can be merged.
Widgets in WordPress are assumed to be arrays, with the applied filters and function return values. With a schema defined, the data type of a widget instance would be guaranteed. Meta in the REST API is a challenge given that it may or may not contain serialized PHP. Widgets are stored in serialized PHP arrays in WP options (though it is possible to store them in posts, per #32474). Additionally, the instance arrays may also contain PHP objects for classes that cannot be cleanly serialized into JSON, and having a REST API JSON schema defined for a widget would guarantee that a widget instance can be represented in JSON. This would, in turn, allow widgets to be exposed as [https://github.com/WP-API/WP-API/issues/19 endpoints] in the REST API, and it would allow widget instances to be completely manipulated with JavaScript (such as in the Customizer, as described in #33507).
By adding schema information to `WP_Widget`, we get a lot more than having default `$instance` data available. For one, the widget form can be automatically generated based on the schema if one is not defined (i.e. if `noform` is returned from the `WP_Widget::form()` method). (This may actually be focus of the Fields API.)" westonruter
Popular 29792 Grunt: Add a precommit task to check for CSS syntax errors netweb Build/Test Tools normal normal 12 Future Release enhancement assigned 2014-09-29T13:07:40Z 2016-05-05T15:21:11Z "We need to do a better job of catching sad syntax errors and problems in our CSS before commit - things like parse errors, empty rules, units on zero values, and possibly duplicate properties (when alone, not as a part of a group). There may also be a thing or two that we could enforce per our own standards, such as requiring a comment to follow any declaration with `!important`.
CSSLint seems to do most of these, provided we turn off the majority of its checks. Many of those checks (vendor prefixes, selector specificity, etc.) either are not relevant to our set up (due to Autoprefixer, for example) or are just not feasible given our current CSS and possibly not desirable for this project.
Interested to know if there are any other tools out there that perhaps fit the job better, and defining the parameters of what we would like to check." helen
Popular 35689 Pagination issue on front page after 4.4.1 update Canonical 4.4.1 normal normal 12 Future Release defect (bug) reviewing 2016-02-01T14:36:06Z 2016-09-08T18:46:10Z "This is a spinoff of the remainder of #35344. See ticket:35344#comment:60 and on.
> It seems to be that the remaining issues being experienced is this scenario, which is sounding like a combination of #35482 and this ticket.
> * Static page on front, no posts page defined
> * `query_posts()` or `$wp_query = new WP_Query()` used within the template to display the first page of posts
> * /page/2/ would then load page 2 of the posts index with no static page in sight.
> The problem I face, is that /page/2/ should NOT be the archive of posts, it should be the second page of the static home page (You can paginate posts/pages using the tag in your content).
" samuelsidler
Popular 20977 Add Dynamic Comment Statuses Comments 3.4 normal normal 12 Future Release enhancement new dev-feedback 2012-06-15T17:12:07Z 2016-09-03T13:29:45Z It would be great to add some filters/actions that would allow plugin developers to add additional statuses to comments. supercleanse
Popular 18623 Allow themes to pre-register multiple custom backgrounds Customize 3.3 normal minor 12 Future Release feature request new dev-feedback 2011-09-08T21:53:35Z 2016-04-21T05:58:21Z We currently have the ability to register multiple header images and to randomly cycle through them or allow users to select one and stick with it. Is there anything that would prevent a similar implementation for custom backgrounds? zamoose
Popular 36809 "Remove target=""_blank"" checkbox in Advanced Link Modal" Editor normal normal 12 Future Release enhancement new 2016-05-10T19:12:48Z 2016-10-12T10:23:36Z "I'd like to propose that the streamlining and usability improvements to the Link Modal started in #33301 be continued by removing or modifying the ""Open Link in New Tab/Window"" checkbox for inserting `target=""_blank""` in the editor.
== `target=""_blank""` Should Rarely be Used
There are [https://www.w3.org/TR/WCAG20-TECHS/G200.html very few intended uses] for `target=""_blank""` and those that exist (such as when a form is the main content of the page) apply to few pages.
Additionally, when `target=""_blank""`, the best practice is that [https://www.w3.org/TR/WCAG20-TECHS/G201.html users should be given advance warning] with text or an accessible icon, something almost never seen in the wild.
`target=""_blank""` is a way for website builders to remove control of a website visitor's browser and is abused much more than it's appropriately used. (It also provides [https://www.jitbit.com/alexblog/256-targetblank---the-most-underestimated-vulnerability-ever/?mc_cid=db4f3ea20f&mc_eid=b8aa59508b an attack vector for phishing attacks].) Chris Coyier has a great article listing the [https://css-tricks.com/use-target_blank/ many bad reasons people do this]. Unfortunately, this has become a [https://mrwweb.com/the-worst-practice-cycle/ fake ""best practice.""] I think WordPress can do the internet an immense favor by making this harder to do.
== Two Options for Changing this
=== Remove the Checkbox Entirely
This is my preferred solution. I believe that anyone who has the appropriate background knowledge to accurately assess when it's appropriate to use `target=""_blank""` will also have the knowledge to use the Text editor to add it via HTML and meet the other usability requirements.
This seems consistent with the ""decisions not options"" philosophy of WordPress development. Given the rare usage of this feature it ''should'' be cumbersome to add. I suspect that the anger at losing this feature will be the primary reason given for not doing this, but I don't think that outweighs the numerous reasons given above. This isn't really that different from removing the `title` attribute textbox that gave 25%+ of the web a nudge toward better usability.
'''WordPress can make the web a better place where visitors have more control over their browsers with this change.'''
=== Make It Irritating to Use
If people aren't willing to entirely remove the `target=""_blank""` checkbox, I believe that checking it should ''always'' trigger a modal window explaining when and when not to use `target=""_blank""`. This is intentionally irritating and it should be. If editors are insistent on interfering with their visitors browsing preferences, they should have to work to do it. [http://www.erikaskin.com/index.php?/projects/design-to-annoy/ Designing to annoy] can be an effective technique, and this feels like an appropriate situation for doing so if removing the checkbox is considered unfeasible." mrwweb
Popular 13429 Updating Link URL on image within Admin with Gallery Gallery 2.9.2 normal normal 12 Future Release defect (bug) new dev-feedback 2010-05-18T01:43:42Z 2016-04-21T20:00:20Z "Image insertion no longer allows url to off site resource within Gallery.
When inserting a gallery you are unable to specify the Link URL. It keep reverting back to the default." vshoward
Popular 18738 Improving cron spawning and other non-blocking HTTP requests HTTP API normal normal 12 Future Release enhancement assigned has-patch 2011-09-21T17:03:50Z 2016-12-04T16:09:58Z "The order of preference for transport methods in the HTTP API is cURL, streams, fsockopen. However cURL and streams cannot perform non-blocking requests, but fsockopen can. Therefore, fsockopen should be the highest priority transport method for non-blocking HTTP requests.
Here's an example. I have a script at `http://ctftw.com/sleep.php` which sleeps for 5 seconds.
{{{
$start = microtime( true );
wp_remote_get( 'http://ctftw.com/sleep.php', array(
'blocking' => false
) );
$end = microtime( true );
var_dump( $end - $start );
}}}
When the cURL or streams transports are used, this request blocks the page for 5 seconds (the default request timeout is 5 seconds).
Let's disable the cURL and streams transports (leaving only fsockopen) and try again:
{{{
add_filter( 'use_curl_transport', '__return_false' );
add_filter( 'use_streams_transport', '__return_false' );
$start = microtime( true );
wp_remote_get( 'http://ctftw.com/sleep.php', array(
'blocking' => false
) );
$end = microtime( true );
var_dump( $end - $start );
}}}
This request does not block the page because fsockopen returns immediately after sending the request.
== Cron Spawning ==
This is a benefit to core because it improves the cron spawner (and can potentially fix #8923). The cron spawner uses a timeout of 0.01 seconds and a non-blocking request, but actually takes longer than 0.01 seconds.
Example:
{{{
$cron_url = get_option( 'siteurl' ) . '/wp-cron.php?doing_wp_cron';
$start = microtime( true );
wp_remote_post( $cron_url, array(
'timeout' => 0.01,
'blocking' => false
) );
$end = microtime( true );
var_dump( $end - $start );
}}}
This request takes around 1.1 seconds on the three servers I've tested it on.
Let's disable cURL and streams again (leaving only fsockopen) and see what we get:
{{{
add_filter( 'use_curl_transport', '__return_false' );
add_filter( 'use_streams_transport', '__return_false' );
$cron_url = get_option( 'siteurl' ) . '/wp-cron.php?doing_wp_cron';
$start = microtime( true );
wp_remote_post( $cron_url, array(
'timeout' => 0.01,
'blocking' => false
) );
$end = microtime( true );
var_dump( $end - $start );
}}}
On each of my three servers I see a time of around 0.001 seconds.
We can therefore improve the cron spawner by setting fsockopen as the preferred transport method for non-blocking HTTP requests.
In an attempt to address #8923, we can change the cron request timeout to 1 second. If fsockopen is used, the request is lightning fast at ~0.001 seconds. If it's not available and the HTTP API falls back to cURL or streams then it takes ~1.1 second, which is the same time it takes currently. (Hopefully that makes sense.)
Patch coming up for those who want to test it." johnbillion
Popular 22100 Treat built-in image sizes the same as custom image sizes Media normal normal 12 Future Release enhancement new has-patch 2012-10-04T15:39:44Z 2015-09-02T02:03:00Z "Goals:
0. Have a solid API for working with intermediate image size definitions.
1. Don't hardcode default image sizes; register them like any other.
2. ~~Introduce a 'pregenerate' arg, which will allow defining an image size that will not be automatically generated right after upload.~~
Related tickets: #15311, #21810" scribu
Popular 30377 wp_check_filetype is broken when checking urls with parameters johnbillion Media 4.0 normal normal 12 Future Release enhancement reviewing needs-unit-tests 2014-11-18T05:05:03Z 2016-12-06T13:57:56Z "The function in ./wp-includes/media.php named wp_check_filetype has a bug.
It works properly when checking a url such as http://example.org/coolfile.mp4 but as soon as you add parameters to it (a common practice when attempting to embed un-cached or amazon pre-signed urls) like so: http://example.org/coolfile.mp4?extra=true&params=true ... it fails to return the extension / content type.
The fix for this should be *very* easy. The preg_match in this function that looks like this currently:
{{{
$ext_preg = '!\.(' . $ext_preg . ')$!i';
}}}
could be adjusted to ignore the query string (if there is one) and just return the true extension like so:
{{{
$ext_preg = '!\.(' . $ext_preg . ')(\?.*)?$!i';
}}}
I've tested this change in my local environment and it works great.
" supercleanse
Popular 29890 Make menu descriptions available to be displayed on the front-end helen Menus 3.0 normal normal 12 Future Release enhancement assigned has-patch 2014-10-08T13:29:52Z 2015-06-09T16:07:46Z "When the refreshed menu UI was introduced in r14248, it came with the possibility to add a description to each menu item. When that description textarea is displayed, [https://core.trac.wordpress.org/browser/tags/4.0/src/wp-admin/includes/nav-menu.php#L182 it's accompanied by the help text]:
{{{The description will be displayed in the menu if the current theme supports it.}}}
Yet there is currently no way for themes (that I'm aware of) to actually display these descriptions. Let's change that!
Added incentive would be one less callback in #29799 Twenty Fifteen." obenland
Popular 23169 Introduce register_post_status_for_object_type Posts, Post Types normal normal 12 Future Release enhancement new 2013-01-10T08:35:46Z 2015-10-04T00:29:44Z Similar to what `register_taxonomy_for_object_type` does with taxonomies. kovshenin
Popular 14691 Allow commas in tag names Taxonomy 3.0.1 normal normal 12 Future Release enhancement new 2010-08-25T09:51:09Z 2015-08-26T02:19:07Z "Adding tags to posts via the web interface involves a lot of what boils down to
{{{
explode( ',', join( ',', array( $tag_name, ... ) ) );
}}}
both in PHP and JS.
We settled on commas so we could have tags with spaces in them (see #10320, for example).
It'd be nice if tags (and other taxonomies) could have commas in them, though. Example use case: normalized locations (""Portland, OR""). Admittedly, commas in tag names is an edge case.
The attached treats tag inputs as ""real"" CSV strings instead of just exploding by commas.
That way, you can enter:
{{{
hello, ""hello, world""
}}}
in the tags input field and the following tags would be added to the post.
* hello
* hello, world
This addresses commas in tag names but makes entering double quotes in tag names more annoying. If you wanted a tag named {{{double""quote}}}, you'd have to enter the following.
{{{
""double""""quote""
}}}
This may also help with #7897." mdawaffe
Popular 19373 wp_insert_post() should not contain current_user_can() checks Taxonomy 3.0 normal major 12 Future Release enhancement new has-patch 2011-11-27T17:02:31Z 2016-06-17T09:58:45Z "wp_insert_post() is a utility function, it should not have a reliance on user capabilities. There are only two places in this function where there is a current_user_can() check - for updating custom taxonomies and for setting post slugs. All other checks (can user publish posts, etc.) are properly handled outside of the utility function.
wp_insert_post() should be safe to use in code that is run without a user context, for example via CRON. With the current code, this is the case *except* for the custom taxonomy feature. This inconsistency can cause a BrilliantDeveloperTM to lose a good deal of time debugging why the same data being passed in is coming back with different results.
For 3.4 (please!), perhaps we can figure out a way to move the checks for user capabilities on taxonomies out of the utility function and into the controller/procedural code. I'm happy to author and submit a patch once an approach has been determined.
For other developers who run into this and need to work around it, either of these 2 options work:
1. call wp_set_post_terms() to add your taxonomies after calling wp_insert_post()
2. set up a ""current user"" in your script before calling wp_insert_post()" alexkingorg
Popular 19912 Add Widget Groups and Locations Widgets 3.3.1 normal normal 12 Future Release feature request new dev-feedback 2012-01-28T04:54:13Z 2016-02-02T23:31:59Z "Currently, if a widget cannot be properly matched to a sidebar when switching themes, it is moved to the ""Inactive widgets"" section (debated for quite a while here: #17979).
With the addition of the planned appearance improvements, it would be nice if we could let the user manipulate widgets as a group. Instead of trying to be too clever, we can let the user review where the widgets are positioned in their theme.
Conceptually, this is very similar to how nav menu locations currently operate. Menu items are grouped in menus (created by the user), which can be assigned to menu locations (created by the theme). Likewise, widgets would be organized into groups (created by the user), and could be assigned to widget locations (created by the theme). Currently, ""widget areas"" are on double-duty — they act as both ""widget groups"" and ""widget locations"".
I think the first step is to add the concept of ""widget groups"" into the current API and turn the existing ""widget areas"" into locations mapped to these groups.
If we're looking to compartmentalize the patches, these initial changes could initially be added without modifying the widgets UI. Instead, we could temporarily link a widget group to a widget area behind the scenes. That said, the benefits could only be fully realized with a few tweaks to the widgets UI." koopersmith
Popular 28580 Speed up customizer by lazy-loading controls and settings as needed westonruter* Customize 3.4 normal normal 11 Future Release enhancement accepted 2014-06-18T22:17:36Z 2016-11-27T19:28:28Z "As more and more controls and settings get added to the customizer, it's performance is bound to take an increased hit, especially for themes that do not implement `postMessage` transport for controls. The Widget Customizer work showed that settings and controls can be created dynamically after the customizer loads. From the start we should consider dynamically instantiating controls, even entire sections, at the moment that they are accessed. As part of this, the JS should be cleaned up to make it a bit easier to create new controls. Right now it involves a bit of DOM manipulation to attach controls to the right section. Likewise, there is no JS API for Customize sections (accordions).
See also #27406, which introduces the ability to group sections. These would need a JS API as well.
The Customizer preview should `postMessage` the panels, sections, controls that it expects up to the Customizer pane and they can be created on demand; see #28709." westonruter
Popular 29989 Hide Media Buttons on small screens Editor high normal 11 Future Release enhancement new has-patch 2014-10-16T03:48:31Z 2015-10-20T04:05:09Z "On small screens, the media buttons above the post editor can take a up a lot of room, especially if plugins have added extra buttons.
It would be nice if they were hidden (perhaps in a dropdown) for small screens.
This would also be useful for the new distraction free writing mode." pento
Popular 37110 Update to jQuery 3.* External Libraries normal normal 11 Future Release task (blessed) new 2016-06-15T17:15:25Z 2016-12-07T20:53:31Z [https://blog.jquery.com/2016/06/09/jquery-3-0-final-released/ jQuery 3.0 has been released]. There are a number of [https://jquery.com/upgrade-guide/3.0/ breaking changes] and the browser minimums have been updated, so we need to figure out how to handle the update as it won't be the normal straight forward update. jorbin
Popular 29513 Move heavy lifting of wp_mail() to child class of PHPMailer Mail 4.0 normal normal 11 Future Release enhancement new dev-feedback 2014-09-04T18:10:10Z 2016-07-14T15:29:03Z "If a plug-in is sending an e-mail, the class `PHPMailer` has a lot of useful methods (e.g. `addStringAttachment()`), but these are not available when using `wp_mail()`, which is a requirement to work with numerous other plug-ins owing to the hooks it triggers.
`wp_mail()` does a number of things:
1. Instantiates a `PHPMailer` instance
2. Sets default values (e.g. ""from"" headers, charset, content type etc. )
3. Parses the passed arguments and feeds it to the `PHPMalier` instance.
4. Executes a ""pre-send"" routine, (e.g. triggering hooks `wp_mail_from`, `phpmailer_init` etc)
5. Sends the e-mail
The attached patch does a number of things:
1. Defines a `WPMailer` class ( a child of `PHPMailer`)
2. Defines a `WPMailerFactory` class which creates an instance with appropriate default values
3. Defines 'helper' methods which do the 'heavy lifting' of (3) above
4. Overrides the preSend method of PHPMailer to execute the 'pre-send routine' present in `wp_mail()` (i.e. (4) above)
5. Refactors `wp_mail()` to ""operate"" `WPMailer()` instance
The result is that developers can either use `wp_mail()` or `$wpmailer = WPMailerFactory::getMailer()` to send e-mails, and both will behave identically (in terms of default values, and hooks being triggered), while maintaining backwards compatibility.
This would also effectively close tickets #28407, #28059, #23291, #15539 , #11376 and maybe others.
== Remarks ==
'''Why just not use `phpmailer_init`?'''
This hook is very useful, but offers no context in which `wp_mail()` is called. As an example, suppose a plug-ins sends an e-mail with an ""on-the-fly"" purchase receipt attached. At `phpmailer_init` I don't know the purchase ID from which to generate and attach the receipt.
'''Class/method naming standards'''
I've used PHPMailer's naming standards which I understand conflicts slightly with WordPress' naming standards. A future iteration of this patch could well change this if that is deemed best.
'''Global $phpmailer'''
The global `$phpmailer` is redundant, as the factory creates a fresh instance for each request. Or at least it ''would''. The ''only'' reason the patch still uses this global, is that all the relevant unit tests pass without any further changes. Subject to this ticket being accepted in principle, these tests should be updated along with the patch.
'''Backwards compatability'''
Assuming `wp_mail()` hasn't been overriden by a plug-in/theme, then the is no change in behaviour. If it has been overridden, it's clear from the original function that the `$_GLOBAL['phpmailer']` should not be expected to exist, nor even the required classes to be loaded. As such they can be expected to operate independently of the changes made here, which are non-destructive.
'''Uni tests'''
For me, the mail group unit tests pass with 1 skipped. For some reason some tests failed (e.g. `Tests_DB::test_bail()`), but these failed even without this patch." stephenharris
Popular 15448 wp_mail() sets Content-Type header twice for multipart emails nacin Mail normal normal 11 Future Release enhancement reviewing has-patch 2010-11-17T12:15:04Z 2016-09-01T18:17:03Z "When trying to send emails via `wp_mail()` with a Content-Type of multipart/alternative, the Content-Type header will be set with `$phpmailer->ContentType`, and again with `$phpmailer->AddCustomHeader()`, which causes two Content-Type headers in the email:
{{{
Content-Type: multipart/alternative;
boundary=""example_boundary""
Content-Type: multipart/alternative; charset=""""
}}}
This appears to cause errors in Outlook, as there is no boundary on the latter.
The cause of this is `PHPMailer::GetMailMIME()`, as it does not know that the email is a multipart email. The easiest way to achieve this appears to be to simply allow the user to set the AltBody via `wp_mail()`. In order to achieve backwards compatibility, `wp_mail()` should work out which part is the text/plain one and which is the text/html one based on the boundary.
I'll be working on a patch for this." rmccue
Popular 23205 New Media Uploader slow for sites with many images Media 3.5 normal normal 11 Future Release enhancement new dev-feedback 2013-01-15T17:17:02Z 2015-09-07T21:48:16Z "The new media uploader added in 3.5 looks very nice. Unfortunately, its functionality is worse for sites with thousands of images. I think this can be combated by allowing us to select the ""Upload Files"" page as our default after clicking ""Add Media,"" and rather than ""All Media Items"" be the page it jumps to after the image is uploaded, instead have it jump to ""Uploaded to this Post."" Is there any way the WordPress team can make this default? Or add the option to make it default? It's made posting on my site 10 times more annoying, especially for those posts with 40-50 images. And I'm sure there are others who feel the same." salromano
Popular 18271 Item hierarchy should be maintained when adding to menu Menus 3.2.1 normal minor 11 Future Release defect (bug) new dev-feedback 2011-07-27T20:13:35Z 2016-07-12T15:20:48Z "Situation:
Create a hierarchy of categories or pages and go to create a custom menu. In the meta boxes on the left hand side, the categories and pages are shown in hierarchical arrangement. Select all categories (for example) and add to menu.
Expected behaviour:
All links are added to custom menu and the hierarchy is maintained appropriately
Actual behaviour:
Hierarchy is lost and all menu items are top-level
This was originally raised by Jane in #17029 however the changeset in the ticket only applies to showing hierarchy in the meta boxes and doesn't cover maintaining hierarchy when adding to menu." JohnONolan
Popular 18672 "Implement rel=""prev"" and rel=""next"" for archives" joostdevalk Permalinks 3.3 normal normal 11 Future Release enhancement new 2011-09-15T12:37:23Z 2016-12-06T22:05:42Z "As can be seen here:
http://googlewebmastercentral.blogspot.com/2011/09/pagination-with-relnext-and-relprev.html
Google now uses rel=""prev"" and rel=""next"" to navigate paginated archives. As we already do a lot of these types of links (rel=""index"", rel=""start"" etc.) I think we should add these. I'll come up with a first version of a patch." joostdevalk
Popular 18857 get_plugin_page_hookname uses menu_title to construct subpage load-hooks SergeyBiryukov* Plugins 3.1.4 normal normal 11 Future Release defect (bug) accepted needs-unit-tests 2011-10-04T15:16:33Z 2016-11-16T11:29:14Z "The load-hook for PluginSubPages isn't working anymore if the PluginPage is translated.
The reason seems to be that the get_plugin_page_hookname function uses the menu_title instead of the menu_slug to create the hookname.
I attached a possible fix." apocalip
Popular 14569 Assign plugins on a per-site-basis Plugins normal normal 11 Future Release feature request new 2010-08-09T09:35:55Z 2015-02-27T15:18:25Z It's possible to assign themes per site with WordPress Multisite. However it isn't possible to assign plugins per site. Some plugins are only used for the mainsite and I don't want them to be visible in subsites. ChantalC
Popular 16706 "Queries using ""category__and"" are slow on large databases" chriscct7 Query 3.1 normal normal 11 Future Release enhancement assigned has-patch 2011-02-28T22:20:52Z 2015-10-08T17:22:22Z "Summary: Using ""category!__and"" in query_posts() generates a dependent subquery in MySQL with extremely poor performance (""Using temporary, Using filesort"") when one of the categories has a large number of posts. The result is so slow that WordPress appears to completely hang. Changing the query structure avoids the filesort and solves it.
Details:
We have a customer doing this as part of a theme in WordPress 3.1:
{{{
query_posts(array(
""category__and"" => array(1, 461),
""posts_per_page"" => 6
));
}}}
The database is fairly large. There are 45,610 posts in category 1, and 167 posts in category 461. The resulting database query runs for so long that it effectively hangs (it doesn't finish within 30 minutes).
The generated MySQL query looks like:
{{{
SELECT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts WHERE 1=1 AND ( wp_posts.ID IN (
SELECT object_id
FROM wp_term_relationships
WHERE term_taxonomy_id IN (1,461)
GROUP BY object_id HAVING COUNT(object_id) = 2
) ) AND wp_posts.post_type = 'post' AND (wp_posts.post_status = 'publish') GROUP BY wp_posts.ID ORDER BY wp_posts.post_date DESC LIMIT 0, 6;
}}}
An ""explain"" on this query shows that it generates a dependent subquery that devolves to a filesort:
{{{
+----+--------------------+-----------------------+-------+------------------+------------------+---------+-------------+-------+-----------------------------------------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+--------------------+-----------------------+-------+------------------+------------------+---------+-------------+-------+-----------------------------------------------------------+
| 1 | PRIMARY | wp_posts | ref | type_status_date | type_status_date | 44 | const,const | 8177 | Using where; Using index |
| 2 | DEPENDENT SUBQUERY | wp_term_relationships | range | term_taxonomy_id | term_taxonomy_id | 8 | NULL | 25665 | Using where; Using index; Using temporary; Using filesort |
+----+--------------------+-----------------------+-------+------------------+------------------+---------+-------------+-------+-----------------------------------------------------------+
}}}
I've tried adding indexes, optimizing, and so on to get the filesort to go away, but I can't get it to do so, at least not with MySQL 5.0.x.
The filesort comes from the ""GROUP BY ... HAVING"". Changing the query to avoid those fixes this. For example, this appears to produce the same results:
{{{
SELECT SQL_CALC_FOUND_ROWS wp_posts.* FROM wp_posts WHERE 1=1 AND
(
SELECT COUNT(1)
FROM wp_term_relationships
WHERE term_taxonomy_id IN (1,461)
AND object_id = wp_posts.ID
) = 2
AND wp_posts.post_type = 'post' AND (wp_posts.post_status = 'publish') GROUP BY wp_posts.ID ORDER BY wp_posts.post_date DESC LIMIT 0, 6;
}}}
But it finishes in a fraction of a second and generates cleaner ""explain"" output with no filesort:
{{{
+----+--------------------+-----------------------+------+--------------------------+------------------+---------+----------------------+------+--------------------------+
| id | select_type | table | type | possible_keys | key | key_len | ref | rows | Extra |
+----+--------------------+-----------------------+------+--------------------------+------------------+---------+----------------------+------+--------------------------+
| 1 | PRIMARY | wp_posts | ref | type_status_date | type_status_date | 44 | const,const | 8177 | Using where |
| 2 | DEPENDENT SUBQUERY | wp_term_relationships | ref | PRIMARY,term_taxonomy_id | PRIMARY | 8 | database.wp_posts.ID | 1 | Using where; Using index |
+----+--------------------+-----------------------+------+--------------------------+------------------+---------+----------------------+------+--------------------------+
}}}
So my suggestion is that the ""category!__and"" query be changed to something like this that avoids filesorts. (I could provide a patch if people agree that this change is a reasonable approach.)" tigertech
Popular 20746 Accessing non-existing theme folder in Network install gives 500 error Rewrite Rules 3.3.2 normal normal 11 Future Release defect (bug) reopened has-patch 2012-05-25T10:28:39Z 2016-07-11T14:19:37Z Accessing non-existing theme folder in Network install gives 500 error and following error in error log: ''Request exceeded the limit of 10 internal redirects due to probable configuration error.'' arkimedia
Popular 22895 user_can_admin_menu() is Type-Insensitive for Users who Can't Create Pages johnbillion* Role/Capability 3.5 normal normal 11 Future Release defect (bug) accepted dev-feedback 2012-12-12T18:32:53Z 2016-11-02T23:00:05Z "Utilization of the new separation edit_posts /create_posts capability separation reveals a flaw in admin menu privilege checking.
The issue occurs when:
1. For any post type other the ""post"", the user has $type->cap->edit_posts but not $type->cap->create_posts
2. User also does not have a manage_terms capability for any associated taxonomies
In that situation, access to ""edit.php?post_type=whatever"" fails unless the user has the ""edit_posts"" cap for the ""post"" type.
This occurs because:
1. '''wp-admin/includes/menu.php''' removes solitary submenus that have the same destination as the parent
2. '''get_admin_page_parent()''' returns nullstring if there is no $submenu item
3. '''user_can_access_admin_page()''' performs a type-sensitive capability check only if get_admin_page_parent() returns an existing $submenu key.
For now, my plugin workaround is to hook into 'admin_menu' and add a dummy submenu with nullstring caption. " kevinB
Popular 38227 Term Status API Taxonomy normal normal 11 Future Release task (blessed) new 2016-10-04T15:52:34Z 2016-10-21T13:13:41Z See #37914, #37915, and make/core post (coming in a moment). boonebgorges
Popular 22810 Support for theme changelogs Themes normal normal 11 Future Release enhancement new 2012-12-07T14:39:22Z 2016-01-12T18:06:33Z "Plugins' changelogs are shown in the WordPress plugin repository in tabs, eg. http://wordpress.org/extend/plugins/events-manager/changelog/.
Plugins' changelogs are also linked to when viewing available updates in WP-admin, so the siteadmins can know if the update could mess with their customizations.
Theme changelogs are not visible in either place. They should be supported in both places. Also http://codex.wordpress.org/Theme_Review should be updated to reflect that the theme changelogs are much recommended if not mandatory to use and to specify the exact format for them. Currently it uses language that is not clear for those who don't speak English as their first language: ""In lieu of..."" and then ""...Themes are recommended to include a changelog"", which doesn't let the theme author know what format should the changelog be in.
At the moment I've seen changelogs for themes in different formats, but none of them is supported.
Summary of the issues:
1. Add support for theme changelogs on https://wordpress.org/extend/themes/ theme pages in tabs.
2. Add support for theme changelogs in wp-admin theme list views.
3. Clarify Theme Review codex page on the supported format(s) and use more simple English than ""in lieu of""." Daedalon
Popular 34281 Allow admins to send users a 'Reset Password' link adamsilverstein Users 4.4 normal normal 11 Future Release enhancement assigned dev-feedback 2015-10-13T02:15:01Z 2016-11-23T19:04:13Z "Following #24633 and #34180
As Pippin said:
> it'd be really nice for admins to be able to manually generate a new password for user accounts and then automatically send that new password via email.
As an extension of that, should we be able to easily send users a link to reset their passwords? It would greatly improve supporting communities. Instead of explaining ""Go to domain.com/wp-admin/ and click on lost password and put in your info..."" you can just press a button and send a link. Done.
I was able to make it a plugin but I'm epically failing at getting the ajax/js stuff to work right as a core patch :(
Screenshot: https://cloudup.com/cWNmv6T0SXI
Code: https://cloudup.com/c2SpsmqXb14
This doesn't actually change the password or even force it. If you, as an admin, change the password of a user, they get an email anyway. This uses just emails them the reset link. " Ipstenu
Popular 33473 "Shortcodes + Widgets. Unified ""component"" API (aka Content Blocks)" Widgets normal normal 11 Future Release feature request new 2015-08-20T21:53:57Z 2016-03-18T12:28:58Z "Looking ahead and seeing that Shortcake is getting a lot of support, I've noticed that shortcodes and widgets are beginning to look fundamentally the same. They are both view components that express some sort of input fields for dynamic ""instance"" data. So I'm wondering what the general feeling would be toward a unified ""Component"" API.
Lets say you're a designer implementing a theme and you have a stylized block for displaying an author. At times you might want to express that in a sidebar, and other times you might want to use it inline in page content. The HTML output is fundamentally the same, and differences only deal with where the input data is coming from (shortcode attrs vs. widget data) and minor presentational differences based on context. This could be very simply expressed as a single class or function pattern that does the work of registering the shortcode and widget under the hood for you. A client or someone downloading a theme often won't know that they want a component to work inside a sidebar or inside the content until they realize it isn't available.
The benefit of a unified API is that you double the usable components you have to work with. There are great developers making widget bundles and other great developers making shortcodes, but not many doing both. All this to say, it's actually pretty straightforward to implement a class version of this API that handles registering both types of object for you. I have a working version of this in a plugin already. I'm just curious if anyone else thinks this is a problem worth pursuing. Thoughts?
Aside: You could make a case that template parts aren't all that different from shortcodes and widgets and might also benefit from input fields (customizer anyone?), at which point you'd have a component that could truly go anywhere." brentjett@…
Noteworthy 26350 !important audit Administration 3.8 high major 10 Future Release defect (bug) new has-patch 2013-12-02T01:06:14Z 2016-07-21T21:59:55Z "After the MP6 merge many CSS rules became ""very !important"". Some are so !important that overwrite other !important...
Looking at wp-admin.css: in trunk there are 65 `!important` compared to 22 in 3.7." azaozz
Noteworthy 28599 Better Visual Focus Indication in Admin Menu Administration 3.8 normal normal 10 Future Release defect (bug) new has-patch 2014-06-20T06:22:58Z 2016-09-26T17:33:18Z "Breaking this issue away from #28267 ""Unify focus styles across the admin."" The left navigation menu system now uses color changes to indicate visual focus. In the default scheme, when the main menu item is selected the background goes from dark gray to black and when a submenu item is selected the text goes dark blue, both hard to discern. Color alone cannot be the only indicator. For those who cannot perceive color changes, a secondary marker is required. For instance, in the situation where a blue glow is used to show focus on an input, there is the color and the shading in the glow: two elements. The solution should work in the eight available admin color schemes.
Some suggestions have been made including:
• Helen reports that a blue glow does not look good
• White outline around menu item with white outline also around selected submenu item
• Reversing the colors coupled with another undefined indicator element
• Triangle to the left of main menu item and selected submenu item
• Underline under main menu item and selected submenu item (might be mistaken for links)
Tracking label: #a11y-color" AccessibleJoe
Noteworthy 11515 Admin needs standardized way of handling messages (notices) displayed to the user Administration 3.0 normal normal 10 Future Release enhancement new 2009-12-19T19:53:03Z 2016-11-01T14:39:43Z "If you try to upload a media item under Media > Add new without an uploads directory, you get the following vague error message:
{{{
Error saving media attachment.
}}}
If you try instead to upload from the post edit page, you get a much more helpful message:
{{{
Unable to create directory /path/wp-content/uploads. Is its parent directory writable by the server?
}}}
In each case, the root error is the same, but the second error message points the way to a solution. Even if the user doesn't know herself what that message means, it's a message that provides the necessary information to someone else who does and is trying to help the user. The first message is completely useless, as it states only what we already know: something went wrong.
The reason Media > Add new doesn't offer a helpful message is that the error is generated on one page request, and ''then'' the user is redirected to another page.
We need a standard, cross-page-load way of conveying messages in admin.
I've thought of a few possible ways of doing this:
* Define and use a standardized set of error codes and associated error messages. This is similar to what happens currently on many pages: the unhelpful ""Error saving media attachment."" appears when the message argument is set to ""3."" What I'm suggesting would use a common set of message codes across the admin and be much more detailed. So the above situation would instead produce a message like ""Unable to create the uploads directory.""
* Save error messages to a cookie. Unlike the previous method, this would allow messages to be made particular to their event.
* Have some kind of user messaging stack. New messages would be pushed into a user's stack (stored in usermeta) and popped off after a certain time, or when read, etc. This has the advantage of lasting across sessions and browsers and being usable for other applications, such as PMs between users.
What do you think?" filosofo
Noteworthy 21573 NOBLOGREDIRECT interfering with 404 errors Bootstrap/Load 3.4.1 normal normal 10 Future Release defect (bug) new 2012-08-14T07:32:06Z 2015-06-22T17:01:54Z When the `NOBLOGREDIRECT` constant is defined, 404 pages on the main site will not work and instead redirect to URL defined in `NOBLOGREDIRECT`. This is the cause of the `maybe_redirect_404` action/function, which is not needed and should be removed. bungeshea
Noteworthy 6286 "Proposed changes to ""E-mail me whenever"" Discussion Options" Comments 2.5 normal normal 10 Future Release enhancement new 2008-03-18T19:14:55Z 2015-10-11T17:55:46Z "WRT the ""E-mail me whenever"" options on the Discussion options page:
[[Image(http://img132.imageshack.us/img132/4215/picture1vf1.png)]]
1. For ""a comment is helf for moderation,"" the ""me"" is ambiguous. It should specify that it means the blog admin e-mail address.
1. For ""anyone posts a comment,"" again, ""me"" is ambiguous. In this case ""me"" means the author of the post. The comment notification setting is personal, and therefore should be set in the profile options (where it can retain the ""me""). Some authors may want e-mail notification, others might not." markjaquith
Noteworthy 10931 Verify Comment Email Addresses of Registered Users Comments 2.8 normal normal 10 Future Release enhancement assigned has-patch 2009-10-08T14:34:44Z 2016-05-23T19:17:35Z "When leaving a comment with an email address of a registered user, WordPress should force the visitor to login or change the email address in the comment form.
Anyone can impersonate a blog's user if they know the user's email address." mtdewvirus
Noteworthy 32052 Add out of the box support for MO file caching I18N 4.2 normal normal 10 Future Release enhancement new 2015-04-22T08:53:40Z 2016-11-03T07:22:40Z "While profiling WordPress with [https://blackfire.io Blackfire] we found that parsing an ''mo'' file is a heavy task, and it's done on each page.
[[Image(default-mo.png, link=https://blackfire.io/profiles/a03c95c9-fafe-459e-a36a-e69edb2ed25d/graph)]]
We propose to use the Object Cache API to not re-parse the file if it hasn't changed.
This way any non English installations with a plugin implementing the Object Cache API could benefit of a significant performance improvement.
You can see here a comparison showing the performance improvement:
[[Image(mo-cache-comp.png, link=https://blackfire.io/profiles/a03c95c9-fafe-459e-a36a-e69edb2ed25d/graph)]]
We found that a few plugins are doing the same thing but they are not used very much and we think it could be great to have it mainstream." nicofuma
Noteworthy 32398 wp-admin/media-new.php is a terrible experience helen Media normal normal 10 Future Release enhancement assigned 2015-05-14T15:32:30Z 2015-07-02T17:05:26Z "`media-new.php` is a holdover, not just from the pre-4.0 media library grid view days, but from the pre-3.5 media modal days. The way it handles showing completed uploads at the bottom is ugly as all, and it involves opening new tabs and other rough interactions.
Per [https://make.wordpress.org/flow/2015/01/29/retiring-media-new-php/ ryan's musings and vizrec]:
* Offer grid view’s uploader interface in list/bulk view as well.
* Remove media-new.php.
* Remove the Media > Add New submenu.
* Celebrate." helen
Noteworthy 29213 Introduce capability for access to nav-menus.php johnbillion Menus 3.0 normal normal 10 Future Release enhancement assigned needs-unit-tests 2014-08-14T16:22:16Z 2016-11-04T03:43:18Z "Management of the nav menus currently requires `edit_theme_options` capability, a capability associated with administrators which grants the power to make many wide sweeping changes. There should be a discrete capability `edit_nav_menus` just for managing menus, one that is inherited for anyone who has `edit_theme_options` by default. This was done for Customizer access in #28605 with the introduction of a `customize` capability.
Originally brought up in #14386.
For introducing a `manage_widgets` capability, see #31020." westonruter
Noteworthy 22589 Network Admin + Ajax requests jeremyfelt Networks and Sites normal normal 10 Future Release enhancement reviewing has-patch 2012-11-26T09:12:18Z 2016-06-28T10:44:59Z "Currently there is no Network admin based ajax handler, forcing plugins which exist solely within the Network Admin to either use `wp-admin/admin-ajax.php` or using the `load-{$page_hook}` hook to perform any actions.
This is primarily a problem when the plugin only includes code on a conditional such as `is_network_admin()`, which would be false for a `/wp-admin/admin-ajax.php` request, as a result, only the `load-{$page_hook}` option above is viable for those.[[BR]]
As a work around, plugins can include code on `is_network_admin() || DOING_AJAX` to allow the usage of admin-ajax.php.
Of course, the User Admin also suffers the same issue.
I didn't see any previous tickets, and kind of want to say the existing 'workaround' is appropriate, but recording it here so we can at least close it as wontfix if appropriate." dd32
Noteworthy 23168 Introduce remove_post_status Posts, Post Types normal normal 10 Future Release enhancement new 2013-01-10T08:32:49Z 2015-10-04T00:29:26Z Plugins and themes should be able to remove the default post statuses defined by core. kovshenin
Noteworthy 15551 Custom post type pagination redirect Query 3.1 normal normal 10 Future Release defect (bug) reopened 2010-11-23T21:50:06Z 2016-11-15T00:19:32Z "We seem to be having a problem with a redirect on a custom post page (e.g., http://www.example.com/show/slug/).
Everything on the page shows correctly. The template pulls in posts with the following query:
{{{
'show', 'meta_value' => $show->ID, 'paged' => get_query_var('paged'), 'caller_get_posts' => true)); ?>
}}}
After the posts we display pagination links (e.g., http://www.example.com/show/slug/page/2/). In our rewrite rules, we include the following rule which should handle these URLs:
{{{
'show/([^/]+)/page/([0-9]{1,})/?$' => 'index.php?show=$matches[1]&paged=$matches[2]',
}}}
Instead of the page displaying and allowing us to pull in the second page of posts, the browser is being redirected back to the original page (http://www.example.com/show/slug/) with a 301. I see that this is happening inside the redirect_canonical function. The following code in wp-includes/canonical.php replaces /page/2/ with / causing the redirect:
{{{
// paging and feeds
if ( get_query_var('paged') || is_feed() || get_query_var('cpage') ) {
if ( !$redirect_url )
$redirect_url = $requested_url;
$paged_redirect = @parse_url($redirect_url);
while ( preg_match( ""#/$wp_rewrite->pagination_base/?[0-9]+?(/+)?$#"", $paged_redirect['path'] ) || preg_match( '#/(comments/?)?(feed|rss|rdf|atom|rss2)(/+)?$#', $paged_redirect['path'] ) || preg_match( '#/comment-page-[0-9]+(/+)?$#', $paged_redirect['path'] ) ) {
// Strip off paging and feed
$paged_redirect['path'] = preg_replace(""#/$wp_rewrite->pagination_base/?[0-9]+?(/+)?$#"", '/', $paged_redirect['path']); // strip off any existing paging
$paged_redirect['path'] = preg_replace('#/(comments/?)?(feed|rss2?|rdf|atom)(/+|$)#', '/', $paged_redirect['path']); // strip off feed endings
$paged_redirect['path'] = preg_replace('#/comment-page-[0-9]+?(/+)?$#', '/', $paged_redirect['path']); // strip off any existing comment paging
}
}}}" cbsad
Noteworthy 21790 When set a static front page WP main query isn't set correctly SergeyBiryukov Query 3.4.1 normal normal 10 Future Release defect (bug) assigned 2012-09-04T13:50:26Z 2016-10-13T13:41:42Z "In my project I use on several places pre_get_posts filter. When setting a static frontpage and blog page I get several notices on my screen. When I var_dump the main query the only value that is set it the page_id.
Even the post_type isn't set." markoheijnen
Noteworthy 30044 Use subqueries for AND clauses in WP_Meta_Query Query 4.1 normal normal 10 Future Release enhancement new 2014-10-19T19:04:07Z 2016-09-01T10:23:39Z "See #24093, starting about here, for background: https://core.trac.wordpress.org/ticket/24093#comment:10
When multiple clauses are passed to `WP_Meta_Query` under the scope of an AND relation, a new table JOIN is required for each clause. With very large meta tables, this can lead to poor performance. We should investigate the performance implications of using subqueries for some of these queries to avoid the joins, much like what happens in `WP_Tax_Query` for NOT IN and AND operators.
Note that the improvements to OR queries in [29953] probably mean that subqueries will not be faster in most cases where relation=OR.
First step toward this would be to see some benchmarks using data of different kinds: small databases; large sets of posts with relatively small postmeta tables; large sets of posts with large amounts of postmeta. As pento notes here https://core.trac.wordpress.org/ticket/24093#comment:30, we'll also need to look at how performance differs between supported versions of MySQL." boonebgorges
Noteworthy 34560 High memory usage ( and possible server error) editing post with many/large revisions adamsilverstein Revisions 3.6 normal major 10 Future Release defect (bug) assigned needs-unit-tests 2015-11-02T23:42:27Z 2016-07-20T00:51:47Z "**Version:** This issue was seen under WordPress 4.3.1, but it likely applies to any modern version of WordPress, even as far back as [https://github.com/WordPress/WordPress/blob/2.9-branch/wp-admin/edit-form-advanced.php 2.9] or maybe earlier.
**Expected Behavior:** A WordPress user should be able to happily create thousands of revisions of pages (or blog posts) containing megabytes of HTML text, limited only by the amount of server memory needed to contain the specific edited revision of the page or post (minus baseline memory needs). So, for example, if you have a 256MB PHP memory limit, you should be able in theory to edit pages of 100MB or more for thousands of revisions (ignoring non-memory constraints like CPU usage, database configuration, communication timeouts, or browser-side limitations). Certainly you should be able to edit a page or post of under 1MB for hundreds of revisions given 256MB of allowed PHP memory (or even just with a 32MB memory limit given few plugins). While editing in WordPress will have limits based on available memory or CPU use or communications timeouts and the memory demand of the current revision being edited, those editing limits should not be substantially affected by the number of revisions of a post previously saved or the sizes of previously saved revisions.
**Exhibited Behavior:** Right now, you will unhappily see ""500 server error"" and ""white screen of death"" results eventually if you, say, edit a 400K page for hundreds of revisions, even with a 256MB server memory limit. Here is an example error from a server with 256MB memory limit resulting from trying to edit a page after saving about 350 revisions of a page that grew to be 437,042 bytes in size:
{{{
[02-Nov-2015 14:40:42 UTC] PHP Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 437043 bytes) in /usr/home/narrafirma/public_html/narrafirma.com/wp-includes/wp-db.php on line 1389
}}}
**Steps to reproduce:** Create a new WordPress page. Put 500K or so of text in it (or any other large amount, the smaller the amount, the more revisions needed to be saved). Save the page for hundreds of revisions. Failure will occur when the number of revisions times the post size exceeds the PHP available memory minus the core memory need of WordPress+plugins. To speed this failure process, reduce the memory available to PHP.
**Likely cause:** The file edit-form-advanced.php has the following section of code which retrieves all revisions for a post using wp_get_post_revisions and then counts the result (twice) to display a count of revisions on the page. While the current approach has a certain elegant simplicity and is easy to understand, the approach is unfortunately computationally inefficient because retrieving all the revisions of a post just to count them potentially consumes a lot of memory, a lot of CPU time, and a lot of database bandwidth when there are many revisions of a post if some are of significant size.
From [https://github.com/WordPress/WordPress/blob/4.3.1/wp-admin/edit-form-advanced.php edit-form-advanced.php (4.3.1)]:
{{{
$publish_callback_args = null;
if ( post_type_supports($post_type, 'revisions') && 'auto-draft' != $post->post_status ) {
$revisions = wp_get_post_revisions( $post_ID );
// We should aim to show the revisions metabox only when there are revisions.
if ( count( $revisions ) > 1 ) {
reset( $revisions ); // Reset pointer for key()
$publish_callback_args = array( 'revisions_count' => count( $revisions ), 'revision_id' => key( $revisions ) );
add_meta_box('revisionsdiv', __('Revisions'), 'post_revisions_meta_box', null, 'normal', 'core');
}
}
}}}
**Suggested fix:** Retrieve the count of revisions in some other way with custom SQL. Alternatively, add an option in when retrieving revisions via ""wp_get_post_revisions"" (in ""wp-includes/revision.php"") to only retrieve the metadata for the revision (like size, timestamp, user, and so on) and use that option in this code. Incidentally, another minor optimization for this code fragment may be to store the count of revisions in the code above so the counting process is not done twice (depending perhaps on how count is implemented versus variable allocation costs in PHP).
**Caveats:** I have only tested this error condition for a page, but I am assuming this issue will apply to blog posts as well (or any kind of posts with revisions). I am not sure what other implications there would be from such a change, like if the revisions' contents were needed elsewhere later for comparisons -- although such a situation could potentially be dealt with by selectively loading specific revision's contents as needed for diff comparisons, even if all the metadata might be needed up front.
**Other potential benefits of the proposed fix:** Beyond avoiding server errors and white screens, making the proposed change may speed up opening long posts and pages for editing by reducing server load substantially. When editing even small posts with a few revisions, this change will still likely speed up the initial opening of the editor at least slightly.
**Use cases:** An example situations of a large page with multiple revisions is where a team uses a WordPress page to track component version deployment status of a large system. Another use case is when a WordPress page grows into a book-length document through repeated editing by someone :-) who is also used to saving a lot to avoid losing work from browser crashes.
**Additional suggestion for further code review:** All uses of ""wp_get_post_revisions"" and any similar functions, as well as all uses of ""count"", could be reviewed in the WordPress codebase looking for similar computational inefficiencies.
" pdfernhout
Noteworthy 6531 Recursively search for files in theme and plugin editors chsxf Themes 2.5 normal minor 10 Future Release defect (bug) assigned 2008-04-01T19:44:11Z 2016-08-06T18:22:36Z "Themes (like Subtle: http://gluedideas.com/downloads/subtle/) might contain numerous CSS files. The theme editor, however, does not recognize any other CSS files other than ''style.css''.
The files might be located some levels deeper in sub directories like '/wp-content/themes/glued-ideas-subtle-01/assets/css/print.css'." torbens
Noteworthy 7795 Activate and Deactivate Theme hooks Themes 2.7 normal normal 10 Future Release enhancement assigned 2008-09-26T20:40:53Z 2015-06-07T19:15:28Z Currently, there is no standard way of checking whether of theme is activated, deactivated and uninstalled. Plugins have this capability and themes should also have the same to ensure that both share similar functionality. jacobsantos
Noteworthy 31746 get_blogs_of_user() can be very slow when a user is a member of thousands of sites johnbillion Users 3.0 normal normal 10 Future Release defect (bug) reviewing has-patch 2015-03-24T02:19:45Z 2016-09-27T16:44:27Z When a user belongs to thousands of sites, the array of `$blogs` can become rather large. Considering get_blogs_of_user is called in many places on every page-load when a user is logged in, Some optimization should happen here. Not counting the multisite admin pages, `get_blogs_of_user()` is called from the functions `is_user_member_of_blog()`, `get_dashboard_url()`, and `WP_Admin_Bar::initialize()`. I propose the results of the function to at least be stored to a static variable to prevent multiple lookups to the same information. I also propose that a pre-fetch filter (pre_get_blogs_of_user ?) be added so that a plugin can override that information and provide something more efficient if the need arises. jtsternberg
Noteworthy 10457 Parse shortcodes in text widgets by default westi Widgets 2.8 normal normal 10 Future Release enhancement reopened 2009-07-21T11:27:06Z 2016-11-14T11:09:21Z Currently, shortcodes are only parsed within post content. It would, to my mind, be a nice enhancement to allow them to be parsed from within text widgets as well. The implementation is trivial, so the only real question is what problems this might throw up. ionfish
Noteworthy 26504 Semantic elements for non-link links Administration 3.8 normal normal 9 Future Release task (blessed) reopened has-patch 2013-12-09T14:29:18Z 2016-11-04T14:55:44Z "Using the [http://heydonworks.com/revenge_css_bookmarklet/ revenge.css bookmarklet] on the dashboard gives a very [http://d.pr/i/yVYh clear indication] that some of the links on there are semantically incorrect - they should be buttons, even if they should look like links.
The Actual Buttons Are Actual section of this [http://coding.smashingmagazine.com/2013/08/20/semantic-css-with-intelligent-selectors/ article] sums it up nicely why.
Unless the accessibility team have indicated otherwise, each of the 74+ occurrences (only counting PHP files, more in JS files) of links with `href=""#""` should probably be a `