__group__ ticket summary owner component _version priority severity milestone type _status workflow _created modified _description _reporter Needs Dev / Bug Wrangler Feedback 46354 Update Count - Value Should Change as Updates are Applied Administration 5.1 low trivial Future Release enhancement new dev-feedback 2019-02-26T22:58:59Z 2020-02-14T10:54:33Z "The Update Count, shown in the Admin Bar, and the Admin Menu (against 'Dashboard' > 'Updates', and optionally against 'Plugins') should change to reflect the outstanding number of Updates available as Updates are Applied, whether they are applied individually on the Plugin Screen, or in bulk through the Updates Screen. This is not a high priority issue at all, but an extremely minor cosmetic change. I suspect that Javascript could be used to change the value as an Update completes successfully in any scenario. " Lucanos Needs Dev / Bug Wrangler Feedback 58547 Twenty Seventeen: Calendar block header cells should be centered Bundled Theme 6.2.2 normal trivial Awaiting Review defect (bug) new dev-feedback 2023-06-15T17:51:49Z 2023-06-15T19:01:32Z "The th elements in the Calendar block are not centered like the rest of the text in the Calendar which looks odd. " nkeller15 Needs Dev / Bug Wrangler Feedback 50026 Twenty Twenty: Full height with short content Bundled Theme normal trivial Awaiting Review enhancement new dev-feedback 2020-04-28T22:35:16Z 2023-06-21T23:01:09Z "With the `twentytwenty` theme, when the height of the content in a page does not fill up the entire viewport, the page ends up with extra trailing whitespace. If we treat the `` as a flex box the page will always be filled: {{{ body { display: flex; flex-direction: column; min-height: 100vh; } main#site-content { flex: 1 } }}} " beaucollins Needs Dev / Bug Wrangler Feedback 45417 Lack of actions when wp_cache_flush is called Cache API normal trivial Future Release enhancement new dev-feedback 2018-11-26T14:08:25Z 2018-12-02T22:48:40Z "The function definition of wp_cache_flush doesn't have a do_action call, and neither does WP_Object_Cache->flush. https://core.trac.wordpress.org/browser/tags/4.9.8/src/wp-includes/cache.php#L97 https://core.trac.wordpress.org/browser/tags/4.9.8/src/wp-includes/cache.php#L498 I want to be able to run additional code whenever the object cache is flushed but currently I can't. Fixing this should be as trivial as adding {{{ do_action('wp_cache_flush'); }}} to the function definition of wp_cache_flush. I don't care about the name of the action or if it runs before or after the flush, I'd just like to have this functionality in the core. Preferably before WordPress 6.0. " k1sul1 Needs Dev / Bug Wrangler Feedback 36564 Last Modified for Comments Comments 4.4 normal trivial Future Release enhancement new needs-unit-tests 2016-04-17T20:44:59Z 2017-02-12T10:37:16Z "Related #28463, #19495. Posts have a last modified and last modified gmt, but comments have no such thing. There are several proposals indicating a need for comment revision, or tracking when the comment is first created. Wanted to explore the idea of having last modified and last modified gmt stored as comment meta triggered by update_comment as a simple, low impact way of adding this feature that could be used by a variety of plugins. This could be implemented by plugin hooking to edit_comment, but if such a feature is to be useful, it needs a standard storage format." dshanske Needs Dev / Bug Wrangler Feedback 58180 Specify the REGEXP format for meta_query Database 6.2 normal trivial Awaiting Review enhancement new needs-docs 2023-04-24T05:47:20Z 2023-08-01T11:33:44Z "Because of the fact that `meta_query` parameter with `['compare' => 'REGEXP', 'key' => 'foo', 'value' => '^bar']` working as substitution to raw SQL-request like `... foo.meta_key REGEXP ^bar ...` please, specify this explicitly in the [https://developer.wordpress.org/reference/classes/wp_meta_query/ documentation] - especially the fact that this REGEXP should not be wrapped in `/`" letraceursnork Needs Dev / Bug Wrangler Feedback 60070 Typo in wp-includes/class-json.php General normal trivial Awaiting Review defect (bug) new dev-feedback 2023-12-14T10:25:56Z 2024-01-27T21:12:45Z "If we go through wp-includes/class-json.php on line number 186 we can see it is mentioned: ""multibye"". It should be ""multibyte""." jayadevankbh Needs Dev / Bug Wrangler Feedback 21273 Automatically open help panel Help/About normal trivial Future Release enhancement new dev-feedback 2012-07-14T19:04:20Z 2021-10-18T19:07:40Z "The help screen is highly inaccessible. Developers are not able to link to content in the help panels if you need to point users to specific directions for your plugin. This patch is a quick stab at it to see if it's worth while. What it does it allow direct links to the help panel. Upon pageload, it'll automagically open up to the correct panel. Usage: 1. Install the patch 2. Click http://wordpress.dev/wp-admin/index.php#tab-panel-help-layout Again, this is a quick stab. The concept could definitely be improve/abstracted and DRYed up. Let me know your thoughts :-)" ptahdunbar Needs Dev / Bug Wrangler Feedback 49356 Add hook into get_user_locale() I18N 5.4 normal trivial Awaiting Review enhancement new dev-feedback 2020-02-04T10:09:30Z 2020-03-19T11:17:49Z "Hey there Like its friend get_locale(), get_user_locale() could benefit of a filter hook named ""user_locale"". What do you think?" juliobox Needs Dev / Bug Wrangler Feedback 48951 email_too_short is not good email validation candidate Mail 5.4 low trivial Awaiting Review feature request new dev-feedback 2019-12-12T14:23:07Z 2020-08-09T18:18:07Z "Currently, both `is_email` and `sanitize_email` will invalidate/sanitize valid emails: {{{#!php 'admin@mailserver1' 'm@m' }}} Both are valid emails. ICANN just discourages using them. The problem comes when you work with decoupled WordPress, and the front end is using custom validation that allows such emails, but WordPress doesn't so you don't have consistent behavior. Plus this is just wrong, as the official specification allows such mails. https://en.wikipedia.org/wiki/Email_address#Valid_email_addresses " dingo_d Needs Dev / Bug Wrangler Feedback 54091 Attachment details pane navigation not working after opening 81st (or greater) item and refreshing the browser antpb Media 5.8 normal trivial 6.6 defect (bug) assigned dev-feedback 2021-09-08T19:02:34Z 2024-02-21T16:16:25Z "Setup: - clean 5.8; - twentytwentyone active; - no plugins active. Steps to reproduce: - open media page; - click on the 41st item in the list; - notice the left arrow is enabled (which is to be expected, since there are previous items); - refresh the page. Notice the left arrow now - it's disabled. Not sure if this is intended, but since the item isn't loaded (in the grid), there's no previous but there's only next, which points to the first item. Clicking the right arrow goes to the it and you can't go back to the previous item." ppetrov2c Needs Dev / Bug Wrangler Feedback 19272 Add Filter to Nav Menu Support Themes Text bhargavbhandari90 Menus normal trivial Future Release enhancement assigned needs-docs 2011-11-16T22:47:52Z 2022-07-01T09:51:33Z "Frameworks could use a filter here to customize the message: `_n('Your theme supports %s menu. Select which menu you would like to use.', 'Your theme supports %s menus. Select which menu appears in each location.', $num_locations )`. For example, it may be the child theme that doesn't support the menus. Also, if none are supported (say via add_theme_support), then when it's zero, it says: ""Your theme supports 0 menus. Select which menu appears in each location."" (which doesn't make much sense). So adding a filter can enable theme developers to further customize. An example use case: {{{ add_filter( 'nav_menu_theme_support_text' , 'wps_nav_menu_theme_support_text' ); function wps_nav_menu_theme_support_text ( $num_locations ) { if ( $num_locations == 0 ) $text = 'Your child theme does not support custom menus.'; else $text = _n('Your theme supports %s menu. Select which menu you would like to use.', 'Your theme supports %s menus. Select which menu appears in each location.', $num_locations ); return $text; } }}}" wpsmith Needs Dev / Bug Wrangler Feedback 53450 [WP_Meta_Query] Add faster LIKE based 'STARTSWITH' and 'ENDSWITH' compare modes for value query Query normal trivial Future Release enhancement new needs-docs 2021-06-18T15:57:59Z 2022-09-20T14:56:48Z "Currently the ""LIKE"" compare mode for meta value compares is only usable for ''contains'' queries as it always adds wildcards around all queries {{{LIKE '%query%'}}}. This makes one use the more complex REGEXP compare mode for queries which easily could be written with {{{LIKE '%query'}}} or {{{LIKE 'query%'}}}. As LIKE is faster than REGEXP it is preferable to use LIKE. See: http://billauer.co.il/blog/2020/12/mysql-index-pattern-matching-performance/ In addition people don't have to use the much more complex regex. Which tends to introduce errors in my experience as most people just copy & paste but do not understand how regex really works (not meant as an offense). So REGEXP should be avoided if possible. I would suggest naming the new compare types {{{STARTSWITH}}} and {{{ENDSWITH}}}. Also adding their {{{NON ...}}} counter parts to match up the ''LIKE'' behaviour. **Maybe** also add an alias for ''LIKE'' named {{{CONTAINS}}} as the current naming ''LIKE'' suggests that you could pass in the wildcards yourself. Which is not the case and thus misleading. But this is just for the sake of the tickets completenes. The pull request only contains code and tests for the new modes. As an alternative I thought about reworking the current LIKE mode to allow custom wildcard passing. But this will clearly break backward compat and thus I discarded this approach." janthiel Needs Dev / Bug Wrangler Feedback 53252 Track WP-CLI version in Site Health wpscholar Site Health 5.8 normal trivial Awaiting Review enhancement assigned dev-feedback 2021-05-21T18:32:45Z 2022-09-05T21:20:07Z Currently, there is no data about WP-CLI in Site Health. Assuming that WP-CLI is present, we should display the version number in the Site Health info tab. wpscholar Needs Dev / Bug Wrangler Feedback 53298 Checking if wp-config-sample.php file exists before checking if wp-config.php exists Upgrade/Install 5.7.2 normal trivial Awaiting Review defect (bug) new dev-feedback 2021-05-29T20:34:43Z 2023-07-12T06:17:11Z "Currently in WordPress core, wp-admin/setup-config.php checks if wp-config-sample.php file exists before checking if wp-config.php exists. If the sample file exists, it then checks if the wp-config.php file exists, and if so, suggests deletion if necessary. For security, some WordPress users may delete the sample file, and restrict open_basedir for directory above that of the web root directory. Because of these two cases, the current order produces the follow error: `PHP message: PHP Warning: file_exists(): open_basedir restriction in effect. File(/var/www/example/wp-config-sample.php) is not within the allowed path(s): (/var/www/example/web:/var/www/example/private:/var/www/example/tmp:/tmp:...) in /var/www/example/web/wp-admin/setup-config.php on line 46` If the check for existence of sample file could be moved after checking if wp-config.php exists, we could avoid this error and avoid checking if sample file exists if wp-config.php does and not checking both if they both do. i.e. Moving the section commented `Support wp-config-sample.php one level up, for the develop repo.` to after the section commented `Check if wp-config.php exists above the root directory but is not part of another installation.` in `wp-admin/setup-config.php`" machineitsvcs Needs Docs or Unit Tests 51725 Canonical redirect and user_trailingslashit() Canonical 5.5.2 normal trivial Awaiting Review defect (bug) new needs-unit-tests 2020-11-07T01:06:54Z 2024-01-25T11:39:58Z "Hi, this bug is quite difficult to spot and it appears only when ''redirect_canonical()'' function is used to force the canonical redirect on front page and the trailing slashes are not added to the permalinks. Happily it is nothing serious. **How to reproduce this bug?** **Step 1. Remove the trailing slashes from WP permalinks:** First of all, you need to use ""Custom structure"" mode in Permalinks settings and remove the trailing slash (''/%postname%/'' => ''/%postname%'') in the adjacent input field. Therefore, the value of ''$wp_rewrite->use_trailing_slashes'' is changed to false. **Step 2. Trigger the canonical redirect on front page** Now let's disable the feed URL by redirecting the visitors trying to access it: {{{#!php ''http://example.com''). The problem is that the PHP notice is displayed then: ''Notice: Undefined index: path in /var/www/vhosts/maciejbis.net/example.com/wp-includes/canonical.php on line 576
'' I guess that the source of the problem is here (line 501): https://core.trac.wordpress.org/browser/tags/5.5.1/src/wp-includes/canonical.php#L501 {{{#!php $redirect['path'] = user_trailingslashit( $redirect['path'] ); }}} Unfortunately because of ''user_trailingslashit()'' function, the slash is removed and value is set to ''null''. The value of `$redirect['path']` should not be changed in this particular case (value '/' should be preserved). My first suggestion is to exclude ''user_trailingslashit()'' function there and not use it when value of `$redirect['path']` variable is just a single slash '/': {{{#!php $redirect['path'] = ( $redirect['path'] === '/' ) ? $redirect['path'] : user_trailingslashit( $redirect['path'] ); }}} Another idea is to do the same but directly in ''user_trailingslashit()'' function: https://core.trac.wordpress.org/browser/tags/5.5.1/src/wp-includes/link-template.php#L51 Basically this piece of code: {{{#!php if ( $wp_rewrite->use_trailing_slashes ) { $string = trailingslashit( $string ); } else { $string = untrailingslashit( $string ); } }}} can be replaced with: {{{#!php if ( $wp_rewrite->use_trailing_slashes ) { $string = trailingslashit( $string ); } else if ( $string !== '/' ) { $string = untrailingslashit( $string ); } }}} " mbis Needs Docs or Unit Tests 46227 Add Rel-Feed Link to Header Feeds low trivial Future Release enhancement reviewing needs-unit-tests 2019-02-10T17:35:29Z 2021-05-13T20:03:29Z "When the front page is not the posts page, proposing that Core add a link in the header to the actual posts page, using the rel=feed designator. https://blog.whatwg.org/feed-autodiscovery Example This would allow a system to figure out where the posts page is." dshanske Needs Docs or Unit Tests 45702 make_clickable() doesn't handle linked text being a URL with spaces within it Formatting low trivial Future Release defect (bug) new needs-unit-tests 2018-12-19T07:22:42Z 2019-04-03T16:39:31Z "As reported in https://meta.trac.wordpress.org/ticket/3998 > {{{ > https://codex.wordpress.org/Roles and Capabilities > }}} > turns into: > {{{ > https://codex.wordpress.org/Roles and Capabilities > }}} > Looks like either `make_clickable()` or `bbp_make_clickable()` is trying to make the URL clickable without taking the existing `` tag into account. As I've commented on the ticket: ---- This is a problem in `bbp_make_clickable()`, but is also present in `make_clickable()`. Given the input string of `https://codex.wordpress.org/Roles and Capabilities` both will return the invalid output. Both contain the following to correct it: {{{ return preg_replace( '#(]+?>|>))]+?>([^>]+?)#i', ""$1$3"", $r ); }}} But as the resulting HTML is the following it's not matched (due to the `` - which assumes that neither the linked text never has spaces or isn't a URL) {{{ https://codex.wordpress.org/Roles and Capabilities }}} Adjusting the regular expression to the following does work however for this specific case: {{{ return preg_replace( '#(]+?>|>))]+?>([^>]+?)([^<]*)#i', ""$1$3$4"", $r ); }}} As a work around, you can remove the spaces from the linked text, which avoids it: `https://codex.wordpress.org/Roles and Capabilities`. ---- Also created https://bbpress.trac.wordpress.org/ticket/3237" dd32 Has Patch / Needs Testing 24795 OS X Treatment Administration 3.6 normal trivial Future Release enhancement new has-patch 2013-07-18T15:54:01Z 2017-02-05T14:09:10Z "Just a minor annoyance. Certain things are inherently different about using a Mac over any other Operating system. Specific to my case is keymappings. While I suspect most Mac users are smart enough to read ""Ctrl + A"" and translate that to ""CMD + A"", we should be explicit when we can. This patch inrtroduces pluggable function is_osx() that is really basic. Sadly, relies on User Agents and so is inherently flawed, but mainly useful anyway. Using this function, the Permalinks Options screen uses Command A instead of CTRL A when .htaccess is not writable. A little thing but annoying enough to warrant a patch." technosailor Has Patch / Needs Testing 44910 function for discriminating during auto saving Autosave normal trivial Awaiting Review feature request new has-patch 2018-09-07T05:33:12Z 2018-09-07T06:01:17Z "I want a function to distinguish auto saving like **wp_doing_cron** or **wp_doing_ajax**. The following code can be simplified. before {{{ if ( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) { //do something } }}} after {{{ if ( wp_doing_autosave() ) { //do something } }}} " mt8.biz Has Patch / Needs Testing 55112 Twenty Twenty-Two: Button design Bundled Theme 5.9 normal trivial Awaiting Review enhancement new has-patch 2022-02-08T10:22:04Z 2022-02-08T14:44:45Z "It seems button elements are not styled in Twenty Twenty-Two such as {{{ }}} The browser default button appears with such code. It would be great if they have a style like other default themes. " umchal Has Patch / Needs Testing 60462 Twenty Twenty: Cover template overflows browser bar on mobile Bundled Theme normal trivial Awaiting Review enhancement new has-patch 2024-02-07T14:36:50Z 2024-02-07T23:32:42Z "Hey there! Twenty Twenty's cover template fills the whole background with the article image. This works as expected on desktop. On mobile however, some content gets covered by the browser bar. Replacing ''vh'' with ''dvh'' fixes that: {{{#!css .screen-height { min-height: 100dvh; } }}}" twiddler Has Patch / Needs Testing 58189 post_type parameter in update_post_caches() accepts more than a single post type Cache API normal trivial Awaiting Review defect (bug) new has-patch 2023-04-25T09:16:03Z 2023-07-16T05:57:03Z In `update_post_caches()`, the `post_type` parameter is documented as only accepting a single post type, which is inaccurate. It actually accepts a single post type, 'any' for any post type, and also an array of post types. DrewAPicture Has Patch / Needs Testing 37077 Replacing one variable handler for another to ensure proper conditional check occurs 100%. Formatting 4.5.2 normal trivial defect (bug) reopened has-patch 2016-06-11T23:18:57Z 2019-06-04T19:59:27Z "I have a likely non-reproduceable problem that, nonetheless, still indicates a failure of a conditional check in wp-class.php. I'd been receiving log file non-critical php errors/warnings for months referencing the rawurlencode() on line 528 getting an array variable. Which is not allowed for that function, hence the error. When I changed line 526's conditional check from {{{ if ( !is_scalar($this->query_vars[$wpvar]) ) }}} to {{{ if ( ( !is_scalar($this->query_vars[$wpvar]) || is_array($this->query_vars[$wpvar]) ) ) }}} the errors went away. Bad plugin/theme code, notwithstanding, the fact that the conditional check fails at all indicates a need for ""refinement"". That's the whole point of these checks, to ensure bad code doesn't take down a website. I'm even wondering if a more streamlined code change for line 526 to {{{ if ( !is_string($this->query_vars[$wpvar]) ) }}} is more appropriate as string variables are all that rawurlencode() allows. I hated changing any core file. But, I was able to quickly address a small issue that shouldn't have been allowed by the core. I don't think this change would impact anyone, the function build_query_string() this code falls within has been depreciated, anyway. BTW, I'm not sure why is_scalar() is failing. However, I came across a few instances across the web with similar quirks. Everyone of those problems was addressed in a similar fashion (i.e. using is_array() or !is_string() instead of !is_scalar()). Source code from wp-class.php: {{{ 521 public function build_query_string() { 522 $this->query_string = ''; 523 foreach ( (array) array_keys($this->query_vars) as $wpvar) { 524 if ( '' != $this->query_vars[$wpvar] ) { 525 $this->query_string .= (strlen($this->query_string) < 1) ? '' : '&'; 526 if ( !is_scalar($this->query_vars[$wpvar]) ) // Discard non-scalars. 527 continue; 528 $this->query_string .= $wpvar . '=' . rawurlencode($this->query_vars[$wpvar]); 529 } 530 } }}}" chadschulz Changes Requested 60138 make_clickable() processing emails start with www. incorrectly. Formatting normal trivial Awaiting Review defect (bug) new changes-requested 2023-12-22T10:23:05Z 2024-02-15T16:25:53Z make_clickable() processes www.blablabla.bla@gmail.com email as ftp address and appends https:// instead of mailto: olyahryhorenko17 Has Patch / Needs Testing 59169 Deprecated arguments description is a bit misleading. General normal trivial Awaiting Review defect (bug) new close 2023-08-22T23:31:30Z 2023-08-23T09:39:10Z "Here: https://developer.wordpress.org/reference/functions/get_bloginfo/ in the description of the function “Deprecated arguments include: ‘siteurl’ – Use ‘url’ instead” is a bit misleading. “‘siteurl’ – Use ‘wpurl’ instead” is correct." sulemanhelp Has Patch / Needs Testing 60430 Spell enqueuing consistently General normal trivial Awaiting Review defect (bug) new has-patch 2024-02-03T14:44:20Z 2024-02-27T21:45:58Z "Small Typo corrections in below files (Inline Documents) - In wp-includes/widgets/class-wp-widget-custom-html.php Line no 58 - In wp-includes/script-loader.php line no 2430 - In wp-includes/widgets/class-wp-widget-text.php line no 47 {{{ enqueueing }}} it should be {{{ enqueuing }}} " shailu25 Has Patch / Needs Testing 59330 Improvement in wp_parse_args for mutli-dimensional arrays General 6.3.1 normal trivial Awaiting Review enhancement new has-patch 2023-09-12T13:36:22Z 2023-09-17T15:54:28Z "I noticed the function doesn't work well when multi-dimensional arrays are present: Example: Consider having following default params and settings. {{{ $defaults = array( 'settings' => array( 'option1' => 'default-value-1', 'option2' => 'default-value-2' ) ); $settings = array( 'settings' => array( 'option1' => 'new-value-1', ) ); $return = wp_parse_args($settings, $defaults); }}} The above example will return: {{{ Array ( [settings] => Array ( [option1] => new-value-1 ) ) }}} It will completely ignore the option2 key. My suggestion is to update wp_parse_args from: {{{ if (is_array($defaults) && $defaults) { return array_merge($defaults, $parsed_args); } }}} with: {{{ if ( is_array( $defaults ) && $defaults ) { return array_replace_recursive($defaults, $parsed_args); } }}} " Stachethemes Has Patch / Needs Testing 51227 Update paginate_links dots to account for total pages General 5.5.1 normal trivial Awaiting Review enhancement new has-patch 2020-09-03T00:06:12Z 2020-09-03T00:08:51Z "Currently, under certain conditions the pagination shows dots when it would make more sense to show a number. Example: If you have the following variables: {{{ Mid size: 2 End size: 1 Total pages: 5 Current page: 1 }}} Then it will visually output as follows: {{{ Prev 1 2 3 ... 5 Next }}} With current changed to 5 then it will show dots at 2 instead. In this case, it would make more sense to show the number instead of dots. " mikeybinns Has Patch / Needs Testing 58948 Use Elvis operator (`:?`) to replace repeating ternary patterns (`a ? a : b`) General 6.3 normal trivial Awaiting Review enhancement new close 2023-07-31T17:54:39Z 2023-10-17T20:11:44Z "This is a somewhat big change, but a simple one at that. Replaces `a ? a : b` patterns of ternary statements to use the Elvis operator `a ?: b`. Null coalescing operator (`??`) was added in PHP 7.0, which WordPress now requires as the minimum version. However, to make this ticket focused and easier to review, this ticket only proposes the Elvis operator. On tainted lines, it follows WordPress CS to use uppercase constants (`NULL` instead of `null`, for example), and removes a few cases of unnecessary braces. Apart from them, the diff output should be quite minimal and straight forward. Perhaps, the review will be easier with word-diff (`git show --word-diff`), or on GitHub, where it highlights word diffs in the line-diff mode. Thank you." ayeshrajans Has Patch / Needs Testing 60565 download_url() returns inaccurate error message on missing URL argument audrasjb HTTP API 6.4.3 normal trivial 6.6 enhancement reviewing has-patch 2024-02-16T20:53:37Z 2024-02-19T19:48:29Z "Expected: {{{#!php "" class=""regular-text code"" /> 2) "" class=""small-text"" /> }}} " dilipbheda Has Patch / Needs Testing 56599 """All"" view not selected for all relevant views for custom post type" Posts, Post Types 4.2 normal trivial Awaiting Review defect (bug) new has-patch 2022-09-19T10:58:34Z 2022-09-19T14:24:10Z When the screen options get saved, the parameter `mode=list` gets appended to the URL. For the posts table, the “All” view gets the `.current` HTML class, since `\WP_Posts_List_Table::is_base_request()` returns `true`. For all other post types—including pages—it returns `false`. alpipego Has Patch / Needs Testing 60646 Docs: Incorrect return type specified for get_post_custom with negative post ID value Posts, Post Types 5.8 normal trivial Future Release defect (bug) new has-patch 2024-02-27T15:11:58Z 2024-03-08T12:03:04Z "On the documentation page for `get_post_custom`, the return type section says: ""False for an invalid $post_id (non-numeric, zero, or negative value)."" https://developer.wordpress.org/reference/functions/get_post_custom/ However, the function applies `absint` to the `$post_id`. So if its value would be negative (i.e. -10), this would be converted a positive value (10), and `get_post_meta` would be called for that post. This post ID can then either exists (resulting in an array being returned) or not (empty string). Perhaps a negative numerical value should not converted? There's a potential for mix-ups? If we keep the code as is, the docs should probably specify that negative values are converted to positive." roytanck Has Patch / Needs Testing 44270 Non-public custom post types have rewrite rules enabled by default Posts, Post Types normal trivial Awaiting Review defect (bug) new has-patch 2018-05-29T22:02:32Z 2018-10-03T17:54:46Z "Is there a reason for the pairing of `public => false` with `rewrite => true` for default custom post type arguments? If there isn't can we change the default `rewrite` to inherit `public` at runtime? I often see a large rewrite rules array from plugin/theme private post types not declaring `rewrite => false` - if there's no need for them seems bit of a waste - a default WP install is 17 rules per post type, 17 possible unnecessary regex checks per-request. Usually it's two or three CPTs I see per site and they stack up quick." TheDeadMedic Has Patch / Needs Testing 56335 use hash_equals to check password hash Security normal trivial Awaiting Review enhancement new close 2022-08-04T22:43:13Z 2022-10-12T18:14:08Z "today in wp-includes/class-phpass.php under function CheckPassword we find {{{ # This is not constant-time. In order to keep the code simple, # for timing safety we currently rely on the salts being # unpredictable, which they are at least in the non-fallback # cases (that is, when we use /dev/urandom and bcrypt). return $hash === $stored_hash; }}} and while i agree that a constant-time comparison is probably not needed, it's a trivial change to fix it, and better safe than sorry. I suggest changing it to {{{ if(PHP_VERSION_ID >= 50600){ return hash_equals($stored_hash, $hash); } else { # This is not constant-time. In order to keep the code simple, # for timing safety we currently rely on the salts being # unpredictable, which they are at least in the non-fallback # cases (that is, when we use /dev/urandom and bcrypt). return $hash === $stored_hash; } }}} PHP_VERSION_ID was introduced in 5.2.7, and i doubt WordPress still need to support PHP5.2. Unsure if WordPress still support 5.5? if the answer is no, the entire PHP_VERSION_ID can be removed. " hanshenrik Has Patch / Needs Testing 51211 Implement a consistent function to obtain the sitemap location Sitemaps 5.5.1 normal trivial Awaiting Review enhancement new has-patch 2020-09-02T01:52:56Z 2023-12-28T11:22:44Z "Would it be possible to implement a function that returns the active XML sitemap location? With so many major plugins choosing to disable the WP core sitemap to continue using their own, it is difficult for others to easily know which is actually being used– especially if those plugins have the option of disabling their sitemap functionality (which means we can't simply detect if the plugin is active to know). Notable sitemap locations: - **WordPress Core:** wp-sitemap.xml - **Yoast SEO:** sitemap_index.xml - **The SEO Framework:** sitemap.xml Perhaps the function can be as simple as applying a filter inside that plugins can hook into to modify the location? Something like the following: {{{ function get_sitemap_uri(){ return (string) apply_filters('sitemap_uri', home_url('/') . 'wp-sitemap.xml'); } }}} " GreatBlakes Has Patch / Needs Testing 33405 "Pagination - use of helip / ""..."" not logic in some cases" Themes 4.2.4 lowest trivial enhancement new has-patch 2015-08-18T16:40:31Z 2019-06-04T21:27:45Z "Hi there, I believe there is some improvement potential in the logic of the pagination. The ""..."" indicator does not really serve its purpose, in case you have it only hiding one page link - see attached screenshot. Would propose to change the function generating the pagination to only use it in case it at least covers 2 page links." th23 Has Patch / Needs Testing 50556 "Special characters in Theme Name in ""Add Themes"" page" Themes normal trivial Awaiting Review enhancement new has-patch 2020-07-04T08:02:13Z 2020-07-07T04:31:50Z "A lot of themes has special characters e.g. `&` in their name. It doesn't look good when those are being replaced in the ""Add Themes"" page with their Character Reference counterpart like `&`. [[Image(https://i.imgur.com/Weatfga.png)]] This patch aims to fix the issue." itowhid06 Has Patch / Needs Testing 45825 Use of same loop variable in inner foreach loop can be error-prone Upgrade/Install 5.0.2 low trivial Future Release enhancement new has-patch 2019-01-04T11:06:20Z 2019-04-15T06:24:06Z "It is not a good practice and not recommended to use the same loop variable in both outer and inner loop. In `wp-admin/install-helper.php` function `maybe_drop_column` does the following: {{{ function maybe_drop_column( $table_name, $column_name, $drop_ddl ) { ... foreach( ... as $column ) { ... foreach( ... as $columns ) { ... } } } }}} I would recommend to change the inner loop variable to `$recheck_column`." subrataemfluence Has Patch / Needs Testing 44032 Use random_bytes() for generating keys and salts Upgrade/Install normal trivial Awaiting Review enhancement new has-patch 2018-05-09T23:21:52Z 2018-05-12T09:06:46Z "While auditing WordPress for remote queries the servers make, I noticed the generation of salts in wp-admin.php is wasteful with an unnecessary loop inside a loop. If the system php supports random_int it also supports random_bytes. Attached patch generates 64 byte (512 bit) salts without needed the 64 round loop inside the 8 round loop loop." alicewondermiscreations Needs Reporter Feedback / Steps To Reproduce 45874 Content Section is overlapping the menu background valentinbora* Administration 5.0.2 normal trivial Awaiting Review enhancement accepted reporter-feedback 2019-01-09T12:36:13Z 2024-01-17T20:19:39Z "Hi, Just uploading some content into WordPress dashboard and saw a little layout bug, I'm not sure if it is kept like this but I thought, maybe it should be behind the menu background completely. As I have uploaded a screenshot, once the menu height finishes then the content is showing below. it should be behind the menu bar. [[Image(http://ahmadgulzar.com/wpscr.png)]] it can be fixed by just changing z-index of #adminmenuback from 1 to 3 {{{ #adminmenuback { position: fixed; top: 0; bottom: -120px; z-index: 3; } }}} Thanks " ahmadgulzar Needs Reporter Feedback / Steps To Reproduce 55994 Twenty Seventeen: Header image zooms in when scrolling down on Mobile Safari Bundled Theme normal trivial Awaiting Review defect (bug) new reporter-feedback 2022-06-16T14:44:08Z 2023-06-21T17:40:17Z "Steps to replicate - Open TwentySeventeen demo site in Mobile Safari (https://twentyseventeendemo.wordpress.com). - Watch the header image as you scroll down the page. (Note that this only seems to happen in Mobile Safari, and doesn't appear in Chrome/Safari on the desktop even with a small window) The header image zooms in slightly when scrolling down, providing a jarring experience for the viewer. The header image should not change size when scrolling. Originally reported here: https://github.com/Automattic/themes/issues/678" mrfoxtalbot Needs Reporter Feedback / Steps To Reproduce 46233 Twenty Sixteen: Theme includes Screen Reader Text inside Card Bundled Theme low trivial Awaiting Review defect (bug) new reporter-feedback 2019-02-11T12:47:41Z 2021-10-26T23:35:14Z The function twentysixteen_entry_meta includes the screen reader text inside the span property using the author mf class. That means when parsed it would say, 'Author David Shanske' The screen reader text should be inside the byline span but outside the author vcard span. dshanske Needs Reporter Feedback / Steps To Reproduce 35503 "Dashboard page: comment status in ""Activity"" group box shows incorrect" Comments 4.4.1 normal trivial feature request new reporter-feedback 2016-01-17T21:54:34Z 2019-06-04T19:33:54Z "'''STEPS TO REPRODUCE''': log in (subscriber user), create new comment for post, log in (administrator user), approve comment on Dashboard page using ""Activity"" group box, click ""Approved (1)"", click ""Go back one page"" in browser. '''EXPECTED RESULT''': comment status - Approved '''ACTUAL RESULT''': comment status - Unapproved This problem was found in browsers Firefox 44.0b9, Chrome 47.0.2526.111 m" antonrinas Needs Reporter Feedback / Steps To Reproduce 57626 Searches to add a link in post-edit, to be sortable/filterable to better find tags Editor normal trivial Awaiting Review enhancement new reporter-feedback 2023-02-03T14:30:14Z 2023-03-20T13:51:02Z "Currently when adding a link to a post, I can search for a term and get back a mix of posts, pages and tags. This is the intended behaviour. However, if the search term I am using is broad (e.g. 'Movies') and there are more than 20 posts on my site featuring the word Movies (this is often the case for a broad term), then WordPress will prioritise returning me 20 search results that are all posts, and will not return the Movies tag. This is a general sorting issue, the search function prioritises posts over tags. I'd like see a change where an exact tag match would always appears as the top result. If not, then an option to filter the search, perhaps with checkboxes to show Posts/Pages/Tags etc." joshduffetywong Needs Reporter Feedback / Steps To Reproduce 46226 PeerTube 'automatic' embed Embeds normal trivial Future Release feature request new reporter-feedback 2019-02-10T14:55:06Z 2019-09-03T18:42:12Z "Would it be possible to add support for automatic Peertube embeds, the same as YouTube embeds work. https://peertube.video/videos/watch/217eefeb-883d-45be-b7fc-a788ad8507d3 " haywardgb Needs Reporter Feedback / Steps To Reproduce 56905 css media query issue General 6.0.3 normal trivial Awaiting Review defect (bug) new reporter-feedback 2022-10-25T13:24:22Z 2022-10-25T16:29:28Z "The media queries used for the responsivness for mobile use a max-width of 767px and the min-width for the tablet one is 768px. However max-width is exclusiv so when the screen is exactly 767px you are neither in mobile or tablet mode. Unfortunately, when i put a window in half screen mode it is precisely 767px so this number is not that odd and other user could experience the same issue. (Tested on wordpress 6.0.3 and google chrome)" damien4444 Needs Reporter Feedback / Steps To Reproduce 49117 WP default themes' translations keep being installed when updating WordPress Upgrade/Install 5.3.2 normal trivial Awaiting Review defect (bug) new reporter-feedback 2020-01-02T14:05:43Z 2023-05-29T12:31:23Z "This happens every website I maintain, and it has been happening ever since I got in the field of web design with wordpress. I'm reporting it because I couldn't find any refference to the issue on the net. To keep the clutter to a minimum, I regularly add following lines to config.php: {{{ define( 'CORE_UPGRADE_SKIP_NEW_BUNDLED', true ); define( 'WP_DEFAULT_THEME', 'whatever-the-theme-is' ); }}} WP default themes' (3 twentywhatever themes) translations keep being installed in wp-content/languages/themes when updatig wordpress, no matter what WP version it is updating to, or what the default theme is. Not a big issue, but still a bug and a nuisance." 3dwebvision Needs Patch 49820 Input and select elements are misaligned in the admin area Administration 5.4 normal trivial Awaiting Review defect (bug) new 2020-04-05T16:36:03Z 2020-04-13T07:38:57Z When placed side by side with inline select boxes, input elements are vertically misaligned in the admin area. Setting vertical-align to middle after line 78 of the /wp-admin/css/forms.css file – similarly to how select boxes are defined later in this stylesheet – seems to fix the problem. luigipulcini Needs Patch 54857 "New column ""template"" in pages/""screen options"" (enhancement)" Administration normal trivial Awaiting Review enhancement new 2022-01-19T11:15:03Z 2022-05-18T13:55:48Z " With WP5.9 FSE themes, editable “templates” are introduced . Therefore, in the list of “Pages” should now be a new column that displays the selected template name for each page. I suggest to offer a new checkable column option “Templates” within Pages/“Screen Options” to get a better overview of the assigned templates. " iStag Needs Patch 59458 Duplicate PHP version in PHPUnit job names on GitHub Actions Build/Test Tools low trivial Future Release defect (bug) new 2023-09-26T14:00:05Z 2023-10-16T09:20:06Z "1. Go to [https://github.com/WordPress/wordpress-develop/commits/trunk Commits] page. 2. Click on any of the GitHub Actions result icons (a green check mark or a red cross mark). 3. Note the duplicate PHP version in the job names, e.g.: {{{ PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.11 PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.11 multisite PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.4 PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.4 multisite PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.6 PHPUnit Tests / PHP 7.0 / PHP 7.0 / MariaDB 10.6 multisite ... }}} The same is displayed in GitHub Actions checks on individual PRs. Appears to be related to [56439]." SergeyBiryukov Needs Patch 45741 Theme block style dependencies while enqueuing Bundled Theme 5.0.2 normal trivial Awaiting Review enhancement new 2018-12-22T13:17:50Z 2021-11-30T16:02:34Z "Bundled themes enqueue a block style, such as /css/blocks.css in twentytwelve. These css rules sometimes overwrite the rules in the files with handles ''wp-block-library'' and ''wp-block-library-theme'' While the dependencies seem to be maintained, for the sake for completeness, shouldn't dependencies be made explicit in bundled themes' functions.php files? For example, dependencies in this enqueue? {{{ wp_enqueue_style( 'twentytwelve-block-style', get_template_directory_uri() . '/css/blocks.css', array( 'twentytwelve-style' ), '20181018' ); }}} " superpoincare Needs Patch 51508 Fix for canonical.php Canonical 2.3 normal trivial Awaiting Review enhancement new 2020-10-13T12:20:40Z 2020-11-15T07:09:35Z "In extremely rare cases it is impossible to determine the path {{{#!php wp_dtl_exam_results * -> wp_dtl_exam_resultmeta */ function example_database_creation_for_wordpress_trac() { global $wpdb; require_once( ABSPATH . 'wp-admin/includes/upgrade.php' ); $charset_collate = $wpdb->get_charset_collate(); $table_name = $wpdb->prefix . 'dtl_exam_resultmeta'; // MY ERROR IS: PRIMARY KEY (answer_id), // IT SHOULD BE: PRIMARY KEY (meta_id), // But the dbDelta function doesn't notice that, and says it created a table when it didn't. $sql = <<'; echo 'The table creation SQL:' . ""\n\n""; echo $sql; echo ""\n -- \n""; // This should give some warning or at least say table creation failed. It doesn't. It says the table was created. echo 'dbDelta results: ' . ""\n\n""; if ( $result ) foreach( $result as $m ) echo $m . ""\n""; else echo '(no results from dbDelta)'; echo ""\n -- \n""; // This should show the table name by checking information_schema, but it's an empty array echo 'Table query from INFORMATION_SCHEMA, this should show the table name: ' . ""\n\n""; $table_exists = $wpdb->get_results( ""SELECT TABLE_NAME FROM INFORMATION_SCHEMA.TABLES WHERE TABLE_SCHEMA = '"". DB_NAME .""' AND TABLE_NAME = '"". $table_name .""';"" ); var_dump( $table_exists ); echo ''; exit; } example_database_creation_for_wordpress_trac(); }}} " radgh Needs Patch 46366 Posted Date - Field Arrangement - Reflect Locale Format OR Combine Fields Date/Time 5.1 normal trivial Awaiting Review enhancement new 2019-02-27T23:01:22Z 2019-05-27T17:19:04Z "In the ""Quick Edit"" form, as well as the Classic Editor's ""Publish"" Metabox, show 5 fields for entering the Publish Date for a Page/Post. [Month (Select)] [Day (Text)], [Year (Text)] @ [Hour (Text)]:[Minutes (Text)] This is the American format, with Month first, but is not a common format outside of the US. Even when the Date format is changed in Settings, that selected format is not used to arrange the Date Entry fields noted above. Suggestion: Integrate a JS Library which allows DateTimes to be entered in various formats, in a single field, and then be processed to produce a value in the format which is required. Example: I should be able to write a DateTime as ""2019-2-28 10:00"" and for that to be converted to ""2 Feb 2019 10AM""." Lucanos Needs Patch 53791 Small UI annoyance in block editor Editor normal trivial Awaiting Review defect (bug) new 2021-07-27T01:52:57Z 2021-07-27T02:29:05Z "When you have a paragraph block selected and click outside the paragraph block, the paragraph block stays selected but the righthand menu quickly jumps from Block to Post to Block, creating a flash of content which provides a bad user experience. See my short video (0:42) for a demonstration: https://www.youtube.com/watch?v=FpRg4vC8W2E" curtiskessler Needs Patch 53630 Prior State Recall for Panes in Editor (Collapse/Expanded) Editor 5.7.2 normal trivial Awaiting Review enhancement new 2021-07-08T18:54:18Z 2021-07-08T18:54:18Z "Background: I recently interacted with a site creator who posted this topic in the WordPress.org support forums: https://wordpress.org/support/topic/add-new-post-screen-layout/ Upon further exploration, I noted that it is possible to toggle various panes (especially pertaining to plugin features) to display or not display. However, if you toggle them to display (the default setting), the editor screen/viewport can become quite small, as much real estate is reserved for these panes. If a user toggles the panes to NOT display, it is not ideal, as they may need access to these panes sporadically. A possible solution would be to enable state memory. Essentially, each pane can be expanded or collapsed using a small arrow in the top right of the pane already. Screenshot: https://cloudup.com/cgzDJjk4UWu MY FEATURE REQUEST: Remember the state of each pane so that when the user returns to the editor, the various panes are in their last state (expanded or collapsed)." dansoschin Needs Patch 58663 Emoji: Consider eliminating expiry-based invalidation of wpEmojiSettingsSupports sessionStorage cache Emoji 6.3 lowest trivial Future Release defect (bug) new 2023-06-28T20:06:05Z 2023-07-19T16:09:30Z "Currently the results of the emoji-loader's tests for whether or not emoji are supported get cached in the browser's `sessionStorage` for 1 week. For most users, this expiration will never be reached since the browser tab would be closed and the `sessionStorage` cleared anyway. For the minority of users who keep a single tab open for weeks at a time, including those who restore tabs after installing an OS update, there can be scenarios where (1) the OS or Twemoji was updated to support emoji but the cache causes Twemoji to still be loaded, or (2) the emoji support was not changed and yet the browser re-checks support after a week unnecessarily. See [https://github.com/WordPress/wordpress-develop/pull/4562#discussion_r1243983163 GitHub pull request discussion] for more context and possible solutions. Nevertheless, as of #58472 the emoji tests have been greatly optimized so the cost of re-calculating support unnecessarily is not a meaningful performance hit, especially since ever since emoji support was introduced until now, the tests were being run on every page load anyway. This may not be worth the effort to resolve." westonruter Needs Patch 59729 By setting int to the parameter of the function path_is_absolute(), a Notice will always be output. Filesystem API 2.5 normal trivial Awaiting Review defect (bug) new 2023-10-25T10:12:11Z 2023-10-25T10:12:11Z "I found this problem from my client's server logs. The simplest way to reproduce it is as follows. {{{ % wp eval 'var_dump(path_is_absolute(1));' PHP Warning: Trying to access array offset on value of type int in /var/www/html/wp-includes/functions.php on line 2123 Warning: Trying to access array offset on value of type int in /var/www/html/wp-includes/functions.php on line 2123 PHP Warning: Trying to access array offset on value of type int in /var/www/html/wp-includes/functions.php on line 2133 Warning: Trying to access array offset on value of type int in /var/www/html/wp-includes/functions.php on line 2133 bool(false) }}} This occurs because the first character of String is processed as an array within the function. The client had written code like this: {{{ $new_path = path_join( $path, get_the_ID() ); }}} I think get_the_ID() should be cast to String, but why not make the function return False if it's not a String as well?" mt8.biz Needs Patch 51768 In documentation, replace references to 'list' with 'array' General normal trivial Awaiting Review defect (bug) new 2020-11-13T11:28:48Z 2020-11-14T15:00:02Z "In ticket #39049, a patch was submitted to replace the word 'list' with 'array' in one function. On that ticket, there was a [https://core.trac.wordpress.org/ticket/39049#comment:2/ comment] saying that ""the terms array and list are often used interchangeably in documentation throughout WordPress core. In fact, searching for ""a list of"" in core returns almost 150 results."" For this ticket, replace all occurrences of 'list' in function documentation with 'array'. " johannadevos Needs Patch 43654 "Silence ""JQMIGRATE: Migrate is installed with logging active, version x.y.z""" General low trivial Awaiting Review defect (bug) new close 2018-03-28T14:56:40Z 2021-11-17T19:05:55Z "jQuery Migrate annoyingly announces itself in the console when it loads. This message is not useful. Can we silence it? `JQMIGRATE: Migrate is installed with logging active, version 1.4.1`" markjaquith Needs Patch 55330 Set global_styles_svg_filters transient to return true causing symbol `1` to be appeared on the screen in a production mode General 5.9.1 normal trivial Awaiting Review enhancement new 2022-03-07T18:14:12Z 2022-03-08T06:49:37Z "WordPress 5.9.1 PHP 8.0.15 When I set `global_styles_svg_filters` to return true (to prevent from being set - I don't use `theme.json` but request is sending so I want to disable it) it renders `1` at the top of the website Steps to reproduce on TwentyTwentyTwo theme: 1. Paste these lines in `functions.php` {{{#!php sanitize_locale_name( [ 'test@test' => 'test@test' ] ); array(1) { 'test@test' => string(8) ""testtest"" } }}} This is not uncommon for WordPress functions that rely upon `preg_replace()` and a number of other sanitize functions behave similarly. I would expect an array input to return either `''` as `array( .. )` is not a valid string." dd32 Needs Patch 54716 """Remember me"" label changed to ""Keep me logged in""" Login and Registration 2.0 normal trivial Awaiting Review enhancement new 2021-12-31T22:36:46Z 2022-02-20T22:29:05Z "I think the label ""Remember me"" to be misleading. The default ""Remember Me"" checkbox behaviour is: >If checked your browser keeps you logged in for 14 days. >If unchecked you're logged out when you quit the browser, or after two days. The checkbox function is not to remember the user identity, but to keep the authentication valid. The task of remembering the user credentials is on the browser. I think that ""Keep me logged in"" would be clearer and more consistent with other services around the internet. ""Keep me logged in on this computer"" is even more accurate. There are variation on the wording, like [Keep me|Stay][logged in|signed in]. Twenty years ago I would just have suggested to add a tooltip (title) with an explanation, but it has already been established in #24766 that title attributes are to be phased out. Amazon uses a full blown popup to explain the function of the checkbox. [[Image(amazon-signin.png)]] Although a totally minor issue I would like to have a discussion about this. " Cyberchicken Needs Patch 49328 Add filter/action to append link to the login form footer inside the #login container Login and Registration normal trivial Awaiting Review enhancement new 2020-01-30T09:40:26Z 2020-01-30T22:07:05Z "At the moment, when using login_footer action, you can add the HTML at the bottom of login page. I think it can be useful to be able also to add some message or custom links to the #nav or #backtoblog area of the login form. At the moment, the only way is to use the hack described [here](https://wordpress.stackexchange.com/questions/99251/how-do-you-add-a-custom-link-to-the-wordpress-login-page) and it doesn't work for not English pages." oksanaromaniv Needs Patch 54452 Image Aspect Ratio on resize Media 5.8.2 normal trivial Awaiting Review enhancement new 2021-11-16T10:54:08Z 2021-11-16T10:54:08Z "With the picture block the css resize the picture width but never the height so it break is aspect ratio. Just need to add a height: auto to .wp-block-image img ." edgarwes Needs Patch 47436 Menu depth doesn't affect menu-item-has-children Menus 5.2.1 normal trivial Awaiting Review defect (bug) new 2019-05-30T17:19:32Z 2021-08-21T22:47:18Z "Hi, When you add a depth of 1 to wp_nav_menu it removes all the sub menus, but it leaves menu-item-has-children class on the original menu li tags, which means it is styled like it has a dropdown." mikeybinns Needs Patch 35538 "AllPosts page UI: link ""All"" has incorrect color" Posts, Post Types 4.4.1 normal trivial Awaiting Review defect (bug) new 2016-01-19T23:15:48Z 2023-07-09T20:45:45Z "STEPS TO REPRODUCE: 1) Log in (administrator), remove all posts. 2) Create new post. Go to AllPosts page. 3) Remove post to trash by clicking ""Trash"" menu item. EXPECTED RESULT: ""All (0)"" link color #000 ACTUAL RESULT: ""All (0)"" link color #0073aa" antonrinas Needs Patch 46423 Posts on wp-admin page should be ordered by date_gmt and not date Posts, Post Types normal trivial Awaiting Review defect (bug) new 2019-03-05T19:28:23Z 2021-02-08T16:37:24Z "I believe the dates should be ordered by the absolute value of time (ie, UTC time) instead of by timezone. To illustrate, Current post sequence > Two [@ UTC 1900 (my timezone is set to New York UTC-5 1300)] > One [@ UTC 1800 (my timezone is set to UTC 1800)] Since 1300 is before 1800. Ordered by my `date` ---- Proposed post sequence > One [@ UTC 1800 (my timezone is set to UTC 1800)] > Two [@ UTC 1900 (my timezone is set to New York UTC-5 1300)] Since 1800 is before 1900. Ordered by absolute `date_gmt`." nickylimjj Needs Patch 43372 $wp_query->max_num_pages return value as float Query 4.9.4 normal trivial Awaiting Review defect (bug) new 2018-02-20T16:32:40Z 2022-02-10T15:13:40Z "As a page number, Integer would make more sense than Float. This is not a big problem but kinda annoying when you do strict comparison on this value. since no one will define a page number as float." ironghost63 Needs Patch 46285 Search colums of WP User Query vars is not updated after applying user_search_columns filter Query 4.9.8 normal trivial Awaiting Review defect (bug) new 2019-02-20T08:21:54Z 2019-02-20T08:21:54Z While preparing the query variables of WP_User_Query , it appears that, after applying user_search_columns filter, the possibly modified array search_columns in WP_User_Query->query_vars argument is not updated . wonderyan Needs Patch 49555 Reorder WP_Query methods for a more logical placement Query normal trivial Future Release enhancement new 2020-03-01T18:03:01Z 2020-03-01T18:22:05Z "Conditional tag functions were initially ordered alphabetically in the source files. With some changes over the years, new functions were introduced and placed next to the closest related function. Now the order is mixed, and the placement of some individual functions like `is_month()` makes no sense in the overall structure. It would be helpful if the methods were ordered in a more logical manner, perhaps based on the [https://developer.wordpress.org/reference/classes/wp_query/#parameters Parameters] section of the DevHub reference, though that could also use some improvement. For the record, the current order is as follows: ||=In `wp-includes/query.php`=||=In `wp-includes/class-wp-query.php`=|| ||`is_archive()`||`::is_archive()`|| ||`is_post_type_archive()`||`::is_post_type_archive()`|| ||`is_attachment()`||`::is_attachment()`|| ||`is_author()`||`::is_author()`|| ||`is_category()`||`::is_category()`|| ||`is_tag()`||`::is_tag()`|| ||`is_tax()`||`::is_tax()`|| ||(moved to `deprecated.php`)||`::is_comments_popup()`|| ||`is_date()`||`::is_date()`|| ||`is_day()`||`::is_day()`|| ||`is_feed()`||`::is_feed()`|| ||`is_comment_feed()`||`::is_comment_feed()`|| ||`is_front_page()`||`::is_front_page()`|| ||`is_home()`||`::is_home()`|| ||`is_privacy_policy()`||`::is_privacy_policy()`|| ||`is_month()`||`::is_month()`|| ||`is_page()`||`::is_page()`|| ||`is_paged()`||`::is_paged()`|| ||`is_preview()`||`::is_preview()`|| ||`is_robots()`||`::is_robots()`|| ||`is_favicon()`||`::is_favicon()`|| ||`is_search()`||`::is_search()`|| ||`is_single()`||`::is_single()`|| ||`is_singular()`||`::is_singular()`|| ||`is_time()`||`::is_time()`|| ||`is_trackback()`||`::is_trackback()`|| ||`is_year()`||`::is_year()`|| ||`is_404()`||`::is_404()`|| ||`is_embed()`||`::is_embed()`|| ||`is_main_query()`||`::is_main_query()`||" SergeyBiryukov Needs Patch 56168 Add a way easily perform advanced post fields queries Query normal trivial Awaiting Review feature request new 2022-07-07T13:12:12Z 2022-07-07T13:12:12Z "Currently if you want to perform advanced queries on the posts table you have to add your custom SQL to the query with the `posts_where` filter. For example, let's say we want to get the next page with a `menu_order` value greater than the current page we would currently do something like: {{{#!php query['menu_order_gt'] ?? null; if ( is_numeric( $value ) ) { $where .= "" AND {$wpdb->posts}.menu_order > {$value} ""; } return $where; }, 10, 2 ); $query = new WP_Query( [ 'post_type' => 'page', 'posts_per_page' => 1, 'menu_order_gt' => (int)get_post_field( 'menu_order' ) ] ); }}} I suggest adding a class like `WP_Meta_Query` but for post fields meaning we could achieve the same result as above but in a much cleaner and simpler way... {{{#!php 'page', 'posts_per_page' => 1, 'field_query' => [ [ 'field' => 'menu_order', 'value' => (int)get_post_field( 'menu_order' ), 'compare' => '>', 'type' => 'NUMERIC' ] ] ] ); }}} " thelevicole Needs Patch 57753 Quickedit characters on date fields Quick/Bulk Edit 6.1.1 normal trivial Awaiting Review defect (bug) new 2023-02-17T09:45:45Z 2023-02-22T20:51:17Z "I know this isn't a massive issue as content editors should use their common sense, but it seems like a user can enter random characters into the date/times via quick edits - Select a post - Press ‘Quick Edit’ - Try to insert letters, special characters in the ‘year’, ‘month’, ‘hour’, ‘minutes’ fields - Press ‘Enter’ " garbagedisco Needs Patch 60426 Update WP_Test_REST_TestCase::assertErrorResponse() to allow custom failure messages REST API normal trivial Awaiting Review enhancement new 2024-02-02T12:21:08Z 2024-02-23T13:31:59Z "According to the WordPress coding standards, it is recommended that if there are more than 2 assertions in a single test method, these assertions should include custom failure messages to explain the nature of any failed assertions. However, in the current state of the `WP_Test_REST_TestCase::assertErrorResponse()` helper method, it contains 2 assertions, making it impossible to add a custom message explaining the error. To align with coding standards and improve the clarity of test failures, I propose updating the method's signature as follows: {{{ protected function assertErrorResponse($code, $response, $status = null, $failure_message) }}} This change will allow developers to include a custom message when using the `WP_Test_REST_TestCase::assertErrorResponse()` method, improving the ability to diagnose issues during testing. Furthermore, all the instances where this method is being used across the codebase need to be refactored to include the new `$failure_message` parameter, ensuring consistency." antonvlasenko Needs Patch 52320 Empty entries in WP_Scripts 'extra' field Script Loader 4.5 normal trivial Awaiting Review defect (bug) new 2021-01-18T08:55:06Z 2021-02-23T18:56:23Z "When WordPress registers all the scripts in `wp_default_scripts()` the `add_inline_script()` will often add `false` to the extra field of the script. That `false` value does not do anything and can be easily removed by comparing against empty data from `get_data()` in `add_inline_script()`. Doesn't look like this has any effect on anything, as `false` values will later on be ignored. But this will save a few extra bytes of memory. Steps to verify: * Get the `$wp_scripts` global * Check some registered scripts, for example `$wp_scripts->registered->editor->extra['after']`. It will have two array values - one is `false` and one is the actual data `window.wp.oldEditor = window.wp.editor;` Or via debugging by putting a breakpoint in `wp-includes/class.wp-scripts.php` in `add_inline_script()` for `$script = (array) $this->get_data( $handle, $position );`" vanyukov Needs Patch 48051 Keeping default theme but removing inactive themes? Site Health normal trivial Awaiting Review enhancement new 2019-09-16T16:46:18Z 2019-09-16T16:50:22Z "Let me start by saying the default site-health report under Tools > Site Health is quite useful. Many of my clients have praised the addition by the WP team! However, while studying the site health report undert Tools >> Site Health on a couple of clients websites I found something interesting in the confusing type of way…. when there are unused themes it says “Remove inactive themes” then when you remove all unused themes it switches over and says “Have default theme available” I understand the reason it suggests this but why not add text in the “remove unused themes” suggestion accordion that says “keep one default theme” or something to that effect. Personally, I would make the accordion title say ""Keep one default theme, remove all other unused themes"". But that is just me. This is a trivial thing that would make the report a bit more useful to inexperienced users. " binarywc Needs Patch 53572 "An ""acknowledged"" category for site health check for things managed outside of WordPress" Site Health 5.1 normal trivial Awaiting Review feature request new 2021-07-01T08:45:49Z 2021-10-16T21:16:54Z "I'd like to have an option to acknowledge single elements of the site health check or an option to mark them as read and done. Reason for this is that my managed wordpress hoster disables some features like the wordpress in-built updater to manage updates centralized and not from within the wordpress backends hosted by him. That's why wp_version_check() is disabled, but not that much of a problem to have it permanently affecting the site health. So the site health check should have more categories: something like ""done"" and an ""ignored"" (or ""acknowledged"") and and ""to do"" while ignored should affect the score as if it is done." paradonym Needs Patch 49014 Silence set_time_limit() call in wp-admin/includes/class-wp-upgrader.php Upgrade/Install normal trivial Awaiting Review defect (bug) reopened 2019-12-17T15:39:09Z 2019-12-24T04:03:22Z "Aggiornamento delle traduzioni per Twenty Twenty (it_IT)… Warning: scandir(/home/.dummy/temp/): failed to open dir: Permission denied in /home/user/wp/wp-includes/functions.php on line 2479 Warning: scandir(): (errno 13): Permission denied in /home/user/wp/wp-includes/functions.php on line 2479 Warning: array_diff(): Argument #1 is not an array in /home/user/wp-includes/functions.php on line 2479 Notice: set_time_limit() has been disabled for security reasons in /home/user/wp-admin/includes/class-wp-upgrader.php on line 468 Le traduzioni sono state aggiornate con successo. Tutti gli aggiornamenti sono stati completati. {{{#!php meta_key ) continue; $meta['value'] = ( $meta['value'] ); if ( current_user_can( 'edit_post_meta', $post_id, $meta['key'] ) ) update_metadata_by_mid( 'post', $meta['id'], $meta['value'] ); } elseif ( current_user_can( 'delete_post_meta', $post_id, $pmeta->meta_key ) ) { delete_metadata_by_mid( 'post', $meta['id'] ); } } else{ update_post_meta( $post_id, $meta['key'], $meta['value'] ); } } } }}} Regards, Arif Skype: arifamir33 " marifamir Commit Candidates 60732 Update old document URLs to new ones audrasjb* General normal minor 6.6 enhancement accepted commit 2024-03-08T15:53:24Z 2024-03-12T06:51:33Z "Some articles that was in https://wordpress.org/documentation/ was moved under https://developer.wordpress.org/advanced-administration/ and the old URLs has a redirect. However URLs in php files still refer to the old ones so I thought the URLs should be updated to avoid unnecessary redirects." mkismy Needs Dev / Bug Wrangler Feedback 37145 Admin submenu opens underneeth editor link tool Administration 4.5.2 low minor Future Release defect (bug) assigned dev-feedback 2016-06-22T07:00:54Z 2020-08-05T14:22:04Z "Sub menus of the admin menu opens underneath the editor's link tool. Possibly a z-index problem. [[Image(http://i.imgur.com/7PMPxb6.png)]]" Stoffe1 Needs Dev / Bug Wrangler Feedback 43963 Add admin body class for multisite blog ID and network admin context Administration normal minor Awaiting Review enhancement new dev-feedback 2018-05-04T16:58:17Z 2018-06-26T17:05:06Z "In multisite, it'd be great to have an admin body class to safely scope CSS to specific blogs (i.e. `blog-2` or `network-admin`) available by default. I often filter `admin_body_class` to add these. One situation where I often use this is conditional override of the text Site Title in the Admin Bar with a logo -- but only if the logo exists. PHP can certainly be used to check context before printing conditional CSS, but the body class adds a safe, client-side scope and clear approach for avoiding in-admin style collisions. Example: {{{ if ( ! empty( $logo ) ) { ?> body.blog- li#wp-admin-bar-site-name > a.ab-item:first-of-type, body.blog- #wpadminbar .ab-top-menu > li#wp-admin-bar-site-name.menupop:hover > .ab-item:first-of-type, body.blog- #wpadminbar .ab-top-menu > li#wp-admin-bar-site-name.menupop.hover > .ab-item:first-of-type { font-size: 0; // safely hide default text background-image: url(""""); background-size: ; background-position: center; background-repeat: no-repeat; min-width: 120px; } "" /> "" /> search_box( $tax->labels->search_items, 'tag' ); ?> }}} which needs to be indented properly to make it more understandable. This can be check in other files as well where we are writing HTML as well as PHP. In this tickets preview how exactly the code is written so I am adding a screenshot as well https://prnt.sc/kmcjeu" prashantvatsh Needs Dev / Bug Wrangler Feedback 47733 Undefined index HTTP_HOST in wp-includes/ms-settings.php on line 57 SergeyBiryukov Bootstrap/Load 5.2.2 normal minor Future Release defect (bug) reviewing dev-feedback 2019-07-18T17:10:16Z 2024-02-21T14:31:47Z "We get requests on our server of the form {{{ 175.143.12.??? - - [30/Jun/2019:10:22:45 +0200] ""GET / HTTP/1.0"" 500 73873 ""-"" ""-"" (dinse.eu) }}} This request uses HTTP/1.0 and results in a status code 500. The related entry in the PHP error log is {{{ [30-Jun-2019 08:22:45 UTC] PHP Notice: Undefined index: HTTP_HOST in /usr/www/xxxx/wp-includes/ms-settings.php on line 57 }}} 1. In ms-settings.php on line 57 it is not checked if {{{ $_SERVER['HTTP_HOST'] }}} is set. 2. Also I've found that in the case of this specific request {{{ $_SERVER['SERVER_NAME'] }}} is defined and not empty and can be used as a replacement. My suggestion is to first check if {{{ $_SERVER['HTTP_HOST'] }}} is set else check if {{{ $_SERVER['SERVER_NAME'] }}} is set and if both are not set to implement a graceful error handling. This may be related to #34353. WP 5.2.2 PHP 5.6.40 Server: Apache/2.4.25 (Debian) WP_DEBUG = true " JochenT Needs Dev / Bug Wrangler Feedback 46771 Twenty Eleven: Negative values for padding Bundled Theme 4.9.8 normal minor Awaiting Review defect (bug) new dev-feedback 2019-04-02T12:27:37Z 2023-11-08T09:50:29Z "Line 2799 #ie7 article.intro Value Error : padding-left -7.6% negative values are not allowed : -7.6% Line 2800 #ie7 article.intro Value Error : padding-right -7.6% negative values are not allowed : -7.6% " Malae Needs Dev / Bug Wrangler Feedback 54120 Twenty Fifteen: Fixed table layout Bundled Theme normal minor Awaiting Review defect (bug) new dev-feedback 2021-09-14T10:44:27Z 2022-07-08T17:16:46Z "The CSS for Twenty Fifteen contains a line forcing fixed layout for tables: {{{ table { border-collapse: separate; border-spacing: 0; border-width: 1px 0 0 1px; margin: 0 0 1.6em; table-layout: fixed; /* Prevents HTML tables from becoming too wide */ width: 100%; } }}} This causes unexpected behavior since you in Gutenberg have the option to select between a fixed or dynamic layout for table blocks, but this has no effect." Roenbaeck Needs Dev / Bug Wrangler Feedback 58474 Twenty Seventeen: Box shadow on Site Logo block looks odd Bundled Theme 6.2.2 normal minor Awaiting Review defect (bug) new dev-feedback 2023-06-07T15:26:43Z 2023-06-09T22:08:13Z "Steps to reproduce: 1. Activate the Twenty Seventeen theme 2. Add the Site Logo block to any page or post and add an image 3. Make sure link to home setting is toggled on 4. Save and view on front end " nkeller15 Needs Dev / Bug Wrangler Feedback 60064 Edit no-js CSS in bundled themes Bundled Theme normal minor Awaiting Review enhancement new dev-feedback 2023-12-13T21:56:39Z 2024-02-15T06:38:38Z "The CSS directive in `style.css` of the Twenty Fifteen theme `.no-js .main-navigation ul ul` should be altered to this `html.no-js .main-navigation ul ul` As other plugins like buddypress add their own `no-js` classes to the `body` which can cause conflicts. I have raised this with them directly: #buddypress9033 This could be widened into a broader ticket on a standard way of adding `no-js` classes that themes or plugins could follow as right now some add it to the `html` and some to the `body` class" shawfactor Needs Dev / Bug Wrangler Feedback 54303 [Object Cache] Allow global caching groups to be filterable / changed Cache API 5.8.1 normal minor Awaiting Review enhancement new dev-feedback 2021-10-21T13:02:06Z 2022-06-09T01:17:57Z "The Object Caching system differentiates between ""local cache groups"" and ""global cache groups"". This is essential for Multisite setups. Global cache groups store cached objects - as the name implies - globally. There is one cached object for all sites in the network. Whereas the local cache groups are stored individually per site. The cache groups are setup using the {{{wp_cache_...}}} API. Like https://developer.wordpress.org/reference/functions/wp_cache_add/ Which groups are actually global is setup in the Object Cache bootstrapping code here: https://github.com/WordPress/WordPress/blob/e791d7f5db8252ba66c7777c456ed80343a450aa/wp-includes/load.php#L732-L735 {{{ wp_cache_add_global_groups( array( 'users', 'userlogins', 'usermeta', 'user_meta', 'useremail', 'userslugs', 'site-transient', 'site-options', 'blog-lookup', 'blog-details', 'site-details', 'rss', 'global-posts', 'blog-id-cache', 'networks', 'sites', 'blog_meta' ) ); }}} This is hardcoded and not filterable in any (reasonable) way. Currently you have to rely on the actual Object Caching implementation to allow one to change the global cache groups. The current globals setup is fine for the assumption of a default WordPress installation. But as it is with customizable software like WordPress, this is not true in any case. For example: If one would split the user information and move it from the (global) network level to the individual sites, one would have to remove all the user related groups from the global cache groups. This is currently not possible at all. There are some possible solutions: 1. Make the array of global cache groups filtereable - This might be a timing issue because the object cache system is loaded very early. But it might work. 2. Add a function to the Object Cache API to actually remove cache groups from the globals list. - This is the {{{add}}} function: https://developer.wordpress.org/reference/classes/wp_object_cache/add_global_groups/ - This could be extended with a counterpart: {{{ public function remove_global_groups( $groups ) { $groups = (array) $groups; $this->global_groups = array_diff_key( $this->global_groups, $groups ); } }}} This could then be leveraged from plugins at any point of time. Yet it still might kick in too late due to the early nature of the object cache system. 3. If timing issues are an issue, instead of the filters, one could make the filtering available using a constant ( WP_OBJECT_CACHE_NON_GLOBAL_GROUPS => array( 'users', 'usermeta' ) ). Yet this depends on PHP7+ 4. Configure the global cachegroups late when filters are available and allow default WP filtering Is this an Edge case? Yes! But it still is quite a burden on the flexibility of the Object cache that could be solved :-)" janthiel Needs Dev / Bug Wrangler Feedback 16365 Comment transition for new comments Comments 3.1 normal minor enhancement new needs-docs 2011-01-24T21:07:46Z 2019-06-04T19:22:11Z "As far as I can tell wp_transitions_comment_status() does not get called for new 'comments' based on my testing and review of comment.php in wp-includes. There is a similar transition for posts that gets called for new 'posts' including hooks like 'new_to_publish' and 'new_to_private'. I feel that there should be a similar hook to this form comments so that plugins can hook into new comments differently from comments moved from one existing status to another (like comment_unapproved_to_approved'." MattyRob Needs Dev / Bug Wrangler Feedback 54211 Small css bug when using customize-controls in customizer.php Customize 3.4 normal minor Awaiting Review defect (bug) new dev-feedback 2021-10-02T11:21:51Z 2022-09-09T10:34:04Z The form code is wrong in the css for some elements. To reproduce problem, add in customizer.php custom two customize-control-radio and two customize-control-select. You see the 'radio' has extra 10px padding on bottom. The 'select' is missing the 10px padding. So it looks very bad when you organize the elements. So either remove the 10px or add the 10px to the 'select' css. akissz Needs Dev / Bug Wrangler Feedback 40779 function_exists() audit in wp-db.php Database low minor Awaiting Review defect (bug) new dev-feedback 2017-05-16T14:47:06Z 2021-06-01T12:50:59Z "A few `function_exists()` checks can be removed from `wp-db.php`, thanks to recent load order changes, probably nobody having looked in a while, and generally being afraid to break DB drop-ins: All of these functions are in files now loaded ahead of `require_wp_db()`: * `is_multisite` (load.php) * `_deprecated_function` (functions.php) * `mb_strlen` (compat.php) Bonus: * `mb_check_encoding()` could *maybe* be a new function in compat.php (it's used 3 times in core, using `@` or `function_exists`) ---- The only caveats are the installation process, and 10+ year-old HyperDB versions that do the old-school deep-integration thing, of directly including files – they'll need extra scrutiny." johnjamesjacoby Needs Dev / Bug Wrangler Feedback 19643 Allow array for $extra_fields in request_filesystem_credentials dd32 Filesystem API 3.0 normal minor defect (bug) reviewing dev-feedback 2011-12-22T07:47:38Z 2019-06-04T19:43:38Z The current implementation for passing extra fields through request_filesystem_credentials() does not allow for an array of data to be passed. I came across this issue when trying to process a bulk installation of plugins with my plugin installation class. My patch fixes this from what I can tell and doesn't break anything that I can see from my testing. griffinjt Needs Dev / Bug Wrangler Feedback 48689 PHP warnings after updating to WP 5.3: ftp_nlist() and ftp_pwd() expect missing parameters costdev Filesystem API 5.3 normal minor 6.6 defect (bug) assigned needs-unit-tests 2019-11-17T23:24:37Z 2024-02-06T05:48:16Z "I updated several websites to WP 5.3 without any problems. But on one wesite I got these PHP warnings both in the backend and in the website: {{{ Warning: ftp_nlist() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 402 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_nlist() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 402 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 681 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: ftp_pwd() expects parameter 1 to be resource, null given in /wp-admin/includes/class-wp-filesystem-ftpext.php on line 226 Warning: Cannot modify header information - headers already sent by (output started at /wp-admin/includes/class-wp-filesystem-ftpext.php:402) in /wp-includes/functions.php on line 5946 Warning: Cannot modify header information - headers already sent by (output started at /wp-admin/includes/class-wp-filesystem-ftpext.php:402) in /wp-admin/includes/misc.php on line 1252 Warning: Cannot modify header information - headers already sent by (output started at /wp-admin/includes/class-wp-filesystem-ftpext.php:402) in /wp-admin/admin-header.php on line 9 }}} I suppressed the ouput by ""muting"" the function calls with '@' in the file 'class-wp-filesystem-ftpext.php', i.e. changed {{{ftp_nlist()}}} to {{{@ftp_nlist()}}} etc.. I will be glad if any reason can be found and fixed until the next WP upgrade. " Hinjiriyo Needs Dev / Bug Wrangler Feedback 24925 Improve no disk space error handling when updating plugins Filesystem API normal minor Awaiting Review enhancement new dev-feedback 2013-08-02T11:25:24Z 2021-07-20T23:02:17Z "I received the following uninformative error message when trying to update a plugin (roughly translated from Finnish): {{{ Error on updating BulletProof Security. Cannot create folder. /[WPDIR]/wp-content/upgrade/bulletproof-security.tmp. }}} The error was caused by not having enough disk space. The plugin update should check if that's the reason for the error and then display a more informative error message." Daedalon Needs Dev / Bug Wrangler Feedback 46561 Make wp_normalize_path() on Windows resolve drive letter for drive–relative paths Filesystem API 3.9 normal minor Awaiting Review enhancement new dev-feedback 2019-03-19T09:18:48Z 2023-03-12T08:45:38Z "Though rarely used, Windows allows to omit drive letter in file path to treat is as drive–relative. This causes inconsistency where paths pointing to the same dir are not normalized to the same representation by `wp_normalize_path()`: {{{#!php 'a', 'º' => 'o', 'À' => 'A', 'Á' => 'A', 'Â' => 'A', 'Ã' => 'A', 'Ä' => 'A', 'Å' => 'A', 'Æ' => 'AE','Ç' => 'C', 'È' => 'E', 'É' => 'E', 'Ê' => 'E', 'Ë' => 'E', 'Ì' => 'I', 'Í' => 'I', 'Î' => 'I', 'Ï' => 'I', 'Ð' => 'D', 'Ñ' => 'N', 'Ò' => 'O', 'Ó' => 'O', 'Ô' => 'O', 'Õ' => 'O', 'Ö' => 'O', 'Ù' => 'U', 'Ú' => 'U', 'Û' => 'U', 'Ü' => 'U', 'Ý' => 'Y', 'Þ' => 'TH','ß' => 's', 'à' => 'a', 'á' => 'a', 'â' => 'a', 'ã' => 'a', 'ä' => 'a', 'å' => 'a', 'æ' => 'ae','ç' => 'c', 'è' => 'e', 'é' => 'e', 'ê' => 'e', 'ë' => 'e', 'ì' => 'i', 'í' => 'i', 'î' => 'i', 'ï' => 'i', 'ð' => 'd', 'ñ' => 'n', 'ò' => 'o', 'ó' => 'o', 'ô' => 'o', 'õ' => 'o', 'ö' => 'o', 'ø' => 'o', 'ù' => 'u', 'ú' => 'u', 'û' => 'u', 'ü' => 'u', 'ý' => 'y', 'þ' => 'th', 'ÿ' => 'y', 'Ø' => 'O', // Decompositions for Latin Extended-A 'Ā' => 'A', 'ā' => 'a', 'Ă' => 'A', 'ă' => 'a', 'Ą' => 'A', 'ą' => 'a', 'Ć' => 'C', 'ć' => 'c', 'Ĉ' => 'C', 'ĉ' => 'c', 'Ċ' => 'C', 'ċ' => 'c', 'Č' => 'C', 'č' => 'c', 'Ď' => 'D', 'ď' => 'd', 'Đ' => 'D', 'đ' => 'd', 'Ē' => 'E', 'ē' => 'e', 'Ĕ' => 'E', 'ĕ' => 'e', 'Ė' => 'E', 'ė' => 'e', 'Ę' => 'E', 'ę' => 'e', 'Ě' => 'E', 'ě' => 'e', 'Ĝ' => 'G', 'ĝ' => 'g', 'Ğ' => 'G', 'ğ' => 'g', 'Ġ' => 'G', 'ġ' => 'g', 'Ģ' => 'G', 'ģ' => 'g', 'Ĥ' => 'H', 'ĥ' => 'h', 'Ħ' => 'H', 'ħ' => 'h', 'Ĩ' => 'I', 'ĩ' => 'i', 'Ī' => 'I', 'ī' => 'i', 'Ĭ' => 'I', 'ĭ' => 'i', 'Į' => 'I', 'į' => 'i', 'İ' => 'I', 'ı' => 'i', 'IJ' => 'IJ','ij' => 'ij', 'Ĵ' => 'J', 'ĵ' => 'j', 'Ķ' => 'K', 'ķ' => 'k', 'ĸ' => 'k', 'Ĺ' => 'L', 'ĺ' => 'l', 'Ļ' => 'L', 'ļ' => 'l', 'Ľ' => 'L', 'ľ' => 'l', 'Ŀ' => 'L', 'ŀ' => 'l', 'Ł' => 'L', 'ł' => 'l', 'Ń' => 'N', 'ń' => 'n', 'Ņ' => 'N', 'ņ' => 'n', 'Ň' => 'N', 'ň' => 'n', 'ʼn' => 'n', 'Ŋ' => 'N', 'ŋ' => 'n', 'Ō' => 'O', 'ō' => 'o', 'Ŏ' => 'O', 'ŏ' => 'o', 'Ő' => 'O', 'ő' => 'o', 'Œ' => 'OE','œ' => 'oe', 'Ŕ' => 'R','ŕ' => 'r', 'Ŗ' => 'R','ŗ' => 'r', 'Ř' => 'R','ř' => 'r', 'Ś' => 'S','ś' => 's', 'Ŝ' => 'S','ŝ' => 's', 'Ş' => 'S','ş' => 's', 'Š' => 'S', 'š' => 's', 'Ţ' => 'T', 'ţ' => 't', 'Ť' => 'T', 'ť' => 't', 'Ŧ' => 'T', 'ŧ' => 't', 'Ũ' => 'U', 'ũ' => 'u', 'Ū' => 'U', 'ū' => 'u', 'Ŭ' => 'U', 'ŭ' => 'u', 'Ů' => 'U', 'ů' => 'u', 'Ű' => 'U', 'ű' => 'u', 'Ų' => 'U', 'ų' => 'u', 'Ŵ' => 'W', 'ŵ' => 'w', 'Ŷ' => 'Y', 'ŷ' => 'y', 'Ÿ' => 'Y', 'Ź' => 'Z', 'ź' => 'z', 'Ż' => 'Z', 'ż' => 'z', 'Ž' => 'Z', 'ž' => 'z', 'ſ' => 's', // Decompositions for Latin Extended-B 'Ș' => 'S', 'ș' => 's', 'Ț' => 'T', 'ț' => 't', // Euro Sign '€' => 'E', // GBP (Pound) Sign '£' => '', // Vowels with diacritic (Vietnamese) // unmarked 'Ơ' => 'O', 'ơ' => 'o', 'Ư' => 'U', 'ư' => 'u', // grave accent 'Ầ' => 'A', 'ầ' => 'a', 'Ằ' => 'A', 'ằ' => 'a', 'Ề' => 'E', 'ề' => 'e', 'Ồ' => 'O', 'ồ' => 'o', 'Ờ' => 'O', 'ờ' => 'o', 'Ừ' => 'U', 'ừ' => 'u', 'Ỳ' => 'Y', 'ỳ' => 'y', // hook 'Ả' => 'A', 'ả' => 'a', 'Ẩ' => 'A', 'ẩ' => 'a', 'Ẳ' => 'A', 'ẳ' => 'a', 'Ẻ' => 'E', 'ẻ' => 'e', 'Ể' => 'E', 'ể' => 'e', 'Ỉ' => 'I', 'ỉ' => 'i', 'Ỏ' => 'O', 'ỏ' => 'o', 'Ổ' => 'O', 'ổ' => 'o', 'Ở' => 'O', 'ở' => 'o', 'Ủ' => 'U', 'ủ' => 'u', 'Ử' => 'U', 'ử' => 'u', 'Ỷ' => 'Y', 'ỷ' => 'y', // tilde 'Ẫ' => 'A', 'ẫ' => 'a', 'Ẵ' => 'A', 'ẵ' => 'a', 'Ẽ' => 'E', 'ẽ' => 'e', 'Ễ' => 'E', 'ễ' => 'e', 'Ỗ' => 'O', 'ỗ' => 'o', 'Ỡ' => 'O', 'ỡ' => 'o', 'Ữ' => 'U', 'ữ' => 'u', 'Ỹ' => 'Y', 'ỹ' => 'y', // acute accent 'Ấ' => 'A', 'ấ' => 'a', 'Ắ' => 'A', 'ắ' => 'a', 'Ế' => 'E', 'ế' => 'e', 'Ố' => 'O', 'ố' => 'o', 'Ớ' => 'O', 'ớ' => 'o', 'Ứ' => 'U', 'ứ' => 'u', // dot below 'Ạ' => 'A', 'ạ' => 'a', 'Ậ' => 'A', 'ậ' => 'a', 'Ặ' => 'A', 'ặ' => 'a', 'Ẹ' => 'E', 'ẹ' => 'e', 'Ệ' => 'E', 'ệ' => 'e', 'Ị' => 'I', 'ị' => 'i', 'Ọ' => 'O', 'ọ' => 'o', 'Ộ' => 'O', 'ộ' => 'o', 'Ợ' => 'O', 'ợ' => 'o', 'Ụ' => 'U', 'ụ' => 'u', 'Ự' => 'U', 'ự' => 'u', 'Ỵ' => 'Y', 'ỵ' => 'y', // Vowels with diacritic (Chinese, Hanyu Pinyin) 'ɑ' => 'a', // macron 'Ǖ' => 'U', 'ǖ' => 'u', // acute accent 'Ǘ' => 'U', 'ǘ' => 'u', // caron 'Ǎ' => 'A', 'ǎ' => 'a', 'Ǐ' => 'I', 'ǐ' => 'i', 'Ǒ' => 'O', 'ǒ' => 'o', 'Ǔ' => 'U', 'ǔ' => 'u', 'Ǚ' => 'U', 'ǚ' => 'u', // grave accent 'Ǜ' => 'U', 'ǜ' => 'u', ); // Used for locale-specific rules $locale = get_locale(); if ( 'de_DE' == $locale || 'de_DE_formal' == $locale || 'de_CH' == $locale || 'de_CH_informal' == $locale ) { $chars[ 'Ä' ] = 'Ae'; $chars[ 'ä' ] = 'ae'; $chars[ 'Ö' ] = 'Oe'; $chars[ 'ö' ] = 'oe'; $chars[ 'Ü' ] = 'Ue'; $chars[ 'ü' ] = 'ue'; $chars[ 'ß' ] = 'ss'; } elseif ( 'da_DK' === $locale ) { $chars[ 'Æ' ] = 'Ae'; $chars[ 'æ' ] = 'ae'; $chars[ 'Ø' ] = 'Oe'; $chars[ 'ø' ] = 'oe'; $chars[ 'Å' ] = 'Aa'; $chars[ 'å' ] = 'aa'; } elseif ( 'ca' === $locale ) { $chars[ 'l·l' ] = 'll'; } elseif ( 'sr_RS' === $locale || 'bs_BA' === $locale ) { $chars[ 'Đ' ] = 'DJ'; $chars[ 'đ' ] = 'dj'; } elseif ( 'el' == $locale ) { $chars[ 'Ά' ] = 'Α'; $chars[ 'ά' ] = 'α'; $chars[ 'Έ' ] = 'Ε'; $chars[ 'έ' ] = 'α'; $chars[ 'Ί' ] = 'Ι'; $chars[ 'ί' ] = 'ι'; $chars[ 'ΐ' ] = 'ϊ'; $chars[ 'Ύ' ] = 'Υ'; $chars[ 'ύ' ] = 'υ'; $chars[ 'ΰ' ] = 'ϋ'; $chars[ 'Ή' ] = 'Η'; $chars[ 'ή' ] = 'η'; $chars[ 'Ό' ] = 'Ο'; $chars[ 'ό' ] = 'ο'; $chars[ 'Ώ' ] = 'Ω'; $chars[ 'ώ' ] = 'ω'; } $string = strtr($string, $chars); } else { $chars = array(); // Assume ISO-8859-1 if not UTF-8 $chars['in'] = ""\x80\x83\x8a\x8e\x9a\x9e"" .""\x9f\xa2\xa5\xb5\xc0\xc1\xc2"" .""\xc3\xc4\xc5\xc7\xc8\xc9\xca"" .""\xcb\xcc\xcd\xce\xcf\xd1\xd2"" .""\xd3\xd4\xd5\xd6\xd8\xd9\xda"" .""\xdb\xdc\xdd\xe0\xe1\xe2\xe3"" .""\xe4\xe5\xe7\xe8\xe9\xea\xeb"" .""\xec\xed\xee\xef\xf1\xf2\xf3"" .""\xf4\xf5\xf6\xf8\xf9\xfa\xfb"" .""\xfc\xfd\xff""; $chars['out'] = ""EfSZszYcYuAAAAAACEEEEIIIINOOOOOOUUUUYaaaaaaceeeeiiiinoooooouuuuyy""; $string = strtr($string, $chars['in'], $chars['out']); $double_chars = array(); $double_chars['in'] = array(""\x8c"", ""\x9c"", ""\xc6"", ""\xd0"", ""\xde"", ""\xdf"", ""\xe6"", ""\xf0"", ""\xfe""); $double_chars['out'] = array('OE', 'oe', 'AE', 'DH', 'TH', 'ss', 'ae', 'dh', 'th'); $string = str_replace($double_chars['in'], $double_chars['out'], $string); } return $string; } }}} " papazetis Needs Dev / Bug Wrangler Feedback 49129 Incorrect German Umlaut substitutions Formatting 5.4 normal minor Awaiting Review enhancement new dev-feedback 2020-01-04T00:18:46Z 2020-01-04T09:39:30Z "Hello, as a native speaker, I find the German Umlaut substitutions quite strange. Correctly, ü is turned into ue, but Ü is turned into Ue. Since the second character should be considered as part of the former character, the former capitalization should be respected. This is especially strange in uppercase text: FRÖHLICH -> FROeHLICH KÖNNEN -> KOeNNEN If it was changed to be all uppercase, it would work much better: FRÖHLICH -> FROEHLICH KÖNNEN -> KOENNEN When used at the start of a word, it would also work fine, if capitalized: ÖFFENTLICH -> OEffentlich ÜBERGANG -> UEbergang Therefore, I would propose changing the table located in wp-includes/formatting.php:1941 (https://github.com/WordPress/WordPress/blob/master/wp-includes/formatting.php#L1941) to the following: {{{ if ( 'de_DE' == $locale || 'de_DE_formal' == $locale || 'de_CH' == $locale || 'de_CH_informal' == $locale ) { $chars['Ä'] = 'AE'; $chars['ä'] = 'ae'; $chars['Ö'] = 'OE'; $chars['ö'] = 'oe'; $chars['Ü'] = 'UE'; $chars['ü'] = 'ue'; $chars['ß'] = 'ss'; }}} Though, to be entirely correct, the surrounding characters would have to be checked, which would be difficult, given the current architecture. There even is a capital ß now, which would be substituted with SS. I am happy to hear any second opinions on this. Best regards, Benedikt" bmuessig Needs Dev / Bug Wrangler Feedback 53262 "wp_robots() (via wp_die) triggers a ""doing_it_wrong_trigger_error"", but should not." General 5.7 normal minor Awaiting Review defect (bug) new dev-feedback 2021-05-23T21:43:29Z 2022-08-03T15:31:55Z "Hello there. In my plugin, I need to die early, like, right after the plugins are loaded, imagine this for a shortcut: `add_action( 'plugins_loaded', 'wp_die' );` This is the output: ''Notice: is_embed was called incorrectly. Conditional query tags do not work before the query is run. Before then, they always return false. Please see Debugging in WordPress for more information. (This message was added in version 3.1.0.) in /wp-includes/functions.php on line 5313'' {{{ # Time Memory Function Location 1 0.0002 369912 {main}( ) .../admin.php:0 2 0.0003 370552 require_once( '/wp-load.php' ) .../admin.php:34 3 0.0003 370960 require_once( '/wp-config.php' ) .../wp-load.php:37 4 0.0003 375568 require_once( '/wp-settings.php' ) .../wp-config.php:88 5 0.0410 1735152 do_action( ) .../wp-settings.php:423 6 0.0411 1735528 WP_Hook->do_action( ) .../plugin.php:484 7 0.0411 1735528 WP_Hook->apply_filters( ) .../class-wp-hook.php:316 8 0.0882 3856336 wp_die( ) .../class-wp-hook.php:292 9 0.0882 3874480 _default_wp_die_handler( ) .../common.php:275 10 0.0884 3876304 wp_robots( ) .../functions.php:3497 11 0.0884 3876304 apply_filters( ) .../robots-template.php:32 12 0.0884 3876712 WP_Hook->apply_filters( ) .../plugin.php:212 13 0.0884 3878216 wp_robots_noindex_embeds( ) .../class-wp-hook.php:292 14 0.0884 3878216 is_embed( ) .../robots-template.php:93 15 0.0884 3878216 _doing_it_wrong( ) .../query.php:881 16 0.0885 3879304 trigger_error ( ) .../functions.php:5313 }}} another notice will be trigger, same thing but line 13 will be `wp_robots_noindex_search`. Since WP 5.7 the `wp_robots()` function is called in a `wp_die()`, but `wp_die()` can be called before the query is done, this is not too soon to die ''(for once, got it?)''. A possible patch is to delay these default filters a bit later ''(wp-includes/default-filters.php)'' instead of adding them right away: {{{ add_action( 'wp', 'wp_late_robots_check' ); function wp_late_robots_check() { add_filter( 'wp_robots', 'wp_robots_noindex_embeds' ); add_filter( 'wp_robots', 'wp_robots_noindex_search' ); } }}} Thanks for your attention." juliobox Needs Dev / Bug Wrangler Feedback 53541 Arguments passed to load_template() should be extracted General 5.8 normal minor Awaiting Review enhancement new dev-feedback 2021-06-28T12:52:53Z 2021-06-28T16:24:41Z "As was originally voiced in this thread when ability to pass arguments to templates was added in v5.5, these arguments should be extracted. As a plugin developer today, the new $args passing does provide as good an experience in terms of simplicity and documentation as the older method of passing query vars. This is because query vars are extracted. So if I'm building a plugin that has a product template and I want to render out $product variables, or pass an object in $product, then which would I prefer to offer to theme developers: Use `$args['product']` to access the $product object. OR Use `$product` to access the product object. Clearly having the vars extracted makes them easier to access. Perhaps the objection to this is that aside from the exception made for query vars we normally try to avoiding using extract(). However in this case I think an exception is warranted. Otherwise the effort put into making argument passing available is somewhat wasted because plugin developers will likely prefer to use query vars simply because they are extracted automatically. Another potential way to enable this would be through an option argument passed to load_template (which would have to first go through locate_template() as well, and that would be $extract_args = false, or $extract_args = true. I'd opt for the later to set the default to extract, but just having that option would let developers control the naming of variables they make available in templates. Reference to the announcement, argument passing in 5.5 https://make.wordpress.org/core/2020/07/17/passing-arguments-to-template-files-in-wordpress-5-5/ load_template() on trak: https://core.trac.wordpress.org/browser/tags/5.7.1/src/wp-includes/template.php#L709 " caseymilne Needs Dev / Bug Wrangler Feedback 57672 Help: only repo plugins and such can be updated on the help page? Help/About normal minor Awaiting Review enhancement new dev-feedback 2023-02-08T13:55:14Z 2023-03-12T18:27:57Z "If you look at this string: https://translate.wordpress.org/projects/wp/dev/admin/nl-be/default/?filters%5Bstatus%5D=either&filters%5Boriginal_id%5D=76683&filters%5Btranslation_id%5D=99106010 if you read it literally, it looks like you can only get auto updates from items from the repo here on wp.org. Yet, there are premium plugins and theme's which can do this as well. Is this something were we should change the phrasing of this?" NekoJonez Needs Dev / Bug Wrangler Feedback 45143 "If the ""recover password"" form submit button is double-clicked two emails will be sent" Login and Registration normal minor Awaiting Review enhancement new dev-feedback 2018-10-22T08:44:48Z 2019-03-18T12:11:56Z "Some users tend to double-click all buttons and links. On the password recovery form (/wp-login.php?action=lostpassword) when the submit button is double-clicked, two emails will be sent. At this point the user is confused about which link to use to recover the password and fails finishing the recovery. It would be good for the submit button to have a time limit or some other means to prevent a double-click from happening." Tiia Rantanen Needs Dev / Bug Wrangler Feedback 60737 invalid_email or user_email ? Login and Registration trunk normal minor Awaiting Review enhancement new dev-feedback 2024-03-10T21:40:10Z 2024-03-10T21:40:10Z "Hey there, I'm talking about login error keys. Here are the 3 things we can find in the WP Core: {{{#!php add( 'invalid_email', __( 'Error: There is no account with that username or email address.' ) ); $errors->add( 'invalid_email', __( 'Error: The email address is not correct.' ) ); $errors->add( 'user_email', __( 'Error: The email address is not correct.' ), array('form-field' => 'email', ) ); }}} The 1st is an error message when you try to login using an email address that is not used as a user in this site, the key is ""invalid_email"" The 2nd is an error message when you try to register a new user with an email address that is not correctly formatted, the key is ""invalid_email"" The 3rd is an error message when you try to update your personal profile with an email address that is not correctly formatted, the key is ""user_email"" So we have 2 keys and 2 messages (like ""A1 A2 B2"", should be ""A1 B2 B2"") but the message 2 is sharing both, we should clearly decide is ""invalid_email"" is when the email does not exists in our site OR when the email is not correctly formatted. I suggest that the 2nd message should share the ""user_email"" and let the ""invalid_*"" for the login stuff, like we already have ""invalidcombo"" or ""invalid_username"" that shares the same kind of issue. thanks for your reading time" juliobox Needs Dev / Bug Wrangler Feedback 49687 wp_mail() - Why is no envelope sender defined? Mail 5.4 normal minor Awaiting Review enhancement new dev-feedback 2020-03-23T23:15:14Z 2022-11-17T08:47:39Z "As just figured out, some (mail) servers require the envelope sender to be set in order to accept outgoing emails. For the PHP built-in mail() function (https://www.php.net/manual/en/function.mail.php) this can be done using the additional parameter (e.g. ""-fwebmaster@example.com) as explained in example 4 of the PHP manual page. In order to use that option and set the envelope sender in PHPmailer either the sender attribute of the phpmailer object needs to be set ($phpmailer->Sender = ""sender@example.com"") or when using the setFrom() method of PHPmailer, the 3rd parameter needs to be set to true (=default). Unfortunately, the current implementation of wp_mail() explicitly sets that 3rd parameter to false, which prevents the envelope sender from being set (see https://core.trac.wordpress.org/browser/trunk/src/wp-includes/pluggable.php?rev=47494#L358). Is there any reason for doing so and could we change L358 to $phpmailer->setFrom( $from_email, $from_name, true ); ?" vbbp Needs Dev / Bug Wrangler Feedback 43046 `has_image_size()` returns false for Core image sizes Media 3.9 normal minor Future Release defect (bug) assigned dev-feedback 2018-01-08T21:37:31Z 2020-02-21T17:52:25Z "`has_image_size()` returns `false` (does not exist) for the four core image sizes (thumbnail, medium, medium_large, large). `get_intermediate_image_sizes()` returns these core image sizes merged with custom registered sizes through `add_image_size()`. `has_image_size()` should return true for the core image sizes, or the function docs should note that the core image sizes are not checked in the function." desrosj Needs Dev / Bug Wrangler Feedback 55535 Pre-populate Image Alt Text field with IPTC Photo Metadata Standard Alt Text joedolson* Media normal minor Future Release enhancement accepted dev-feedback 2022-04-05T21:45:25Z 2024-02-05T20:52:37Z "The IPTC Photo Metadata Standard includes the ability to embed Alt Text with a photo. Seems like it would be helpful if WordPress would check for this data when an image is uploaded, and, if it exists, pre-populate the Alt Text field with it. I could see this being especially useful for site owners who purchase stock photography; if the alt text is embedded with those images, it would save the site owner time, and it would also help ensure that an Alt Text itself is added -- and is an accurate description of the image (assuming the photographer or stock photo site actually enters a good description!). http://www.iptc.org/std/photometadata/specification/IPTC-PhotoMetadata#alt-text-accessibility" eatingrules Needs Dev / Bug Wrangler Feedback 25293 Switch_to_blog not switching the siteid Networks and Sites 3.0 normal minor Future Release defect (bug) new dev-feedback 2013-09-12T09:11:20Z 2017-06-08T20:17:36Z "When having multiple network on multisite making the following: {{{ switch_to_blog(1); $options = get_site_option( 'my_option' ); restore_current_blog(); }}} The options retrieved are the options of the current siteid and not the siteid of the switched blog. One of the options is to make something like this : {{{ global $wpdb; // Get the previous siteid $previous_site_id = $wpdb->siteid; $previous_blog_id = $wpdb->blogid; // Go to site 1 switch_to_blog(1); // Set the blog siteid to 1 $wpdb->set_blog_id( 1, 1 ); // Get the options $options = get_site_option( 'my_option' ); restore_current_blog(); $wpdb->set_blog_id( $previous_blog_id , $previous_site_id ); }}} Or {{{ // Get the previous siteid $site_id = $wpdb->siteid; // Set the blog siteid to 1 $wpdb->set_blog_id( $wpdb->blogid, 1 ); // Get the options $options = get_site_option( 'my_options' ); $wpdb->set_blog_id( $wpdb->blogid , $site_id ); }}} The thing is that the switch_to_blog function does not specify the switched siteid on the method $wpdb->set_blog_id if the network is not the same as the current blog." Rahe Needs Dev / Bug Wrangler Feedback 16853 Error 500 when a user has too many sites Networks and Sites 3.0.1 normal minor Future Release enhancement assigned dev-feedback 2011-03-14T11:15:57Z 2019-04-08T16:52:29Z "'''My installation''' [[BR]] 3.0.1 multi-site installation with more than 7500 blogs, with one user each. I also have one moderation user that can administer each of the blogs. [[BR]] [[BR]] '''The issue''' [[BR]] In the admin interface, when I go to Super-Admin -> Users, and when I display the page that contains my moderation user, I get ""''An error (500 Internal Server Error) has occured in response to this request''"". The page tries to display all the sites administered by him (around 7500 of them), hence the error. [[BR]] [[BR]] Updating to 3.1 didn't resolve the problem. [[BR]] [[BR]] '''Recommended enhancement''' [[BR]] For each user in the list, display only a certain number of sites, with a possibility to see all of that user's sites, if needed." luuzan@… Needs Dev / Bug Wrangler Feedback 52798 delete_option() does not clear cache if option is missing in database. Options, Meta APIs 2.1 normal minor Awaiting Review defect (bug) new dev-feedback 2021-03-12T19:31:51Z 2021-07-19T02:10:10Z "It's an old one, but this is the mirror of #25015. If, for some reason, an object does not exist in the database, but does exist in persistent object cache, calling `delete_option()` will fail and the cached option will continue to exist: {{{ wp> get_option( 'test-option' ); => bool(false) wp> update_option( 'test-option', 'example', false ); => bool(true) wp> get_option( 'test-option' ); => string(7) ""example"" wp> global $wpdb; wp> $wpdb->get_results( 'SELECT * FROM wp_options WHERE option_name=""test-option""' ); => array(1) { [0]=> object(stdClass)#1977 (4) { [""option_id""]=> string(3) ""121"" [""option_name""]=> string(11) ""test-option"" [""option_value""]=> string(7) ""example"" [""autoload""]=> string(2) ""no"" } } wp> $wpdb->delete( $wpdb->options, array( 'option_name' => 'test-option' ) ); => int(1) wp> $wpdb->get_results( 'SELECT * FROM wp_options WHERE option_name=""test-option""' ); => array(0) { } wp> get_option( 'test-option' ); => string(7) ""example"" wp> delete_option( 'test-option' ); => bool(false) wp> get_option( 'test-option' ); => string(7) ""example"" }}} I know what you're thinking, ""Don't ever delete directly on the database."" But recently when I ran into this, manual deletion wasn't the cause. More than likely it was some sort of race condition between distributed database or cache servers, or other arcane edge cases. The end result though was that the cache and database were out of sync and subsequent automated `delete_option()` calls were silently failing to clear the cache. The easiest solution would be to move the cache deletion before the database check: {{{ diff --git a/src/wp-includes/option.php b/src/wp-includes/option.php index 8692db7199..2f4a000ca1 100644 --- a/src/wp-includes/option.php +++ b/src/wp-includes/option.php @@ -648,6 +648,18 @@ function delete_option( $option ) { wp_protect_special_option( $option ); + if ( ! wp_installing() ) { + if ( 'yes' === $row->autoload ) { + $alloptions = wp_load_alloptions( true ); + if ( is_array( $alloptions ) && isset( $alloptions[ $option ] ) ) { + unset( $alloptions[ $option ] ); + wp_cache_set( 'alloptions', $alloptions, 'options' ); + } + } else { + wp_cache_delete( $option, 'options' ); + } + } + // Get the ID, if no ID then return. $row = $wpdb->get_row( $wpdb->prepare( ""SELECT autoload FROM $wpdb->options WHERE option_name = %s"", $option ) ); if ( is_null( $row ) ) { @@ -665,18 +677,6 @@ function delete_option( $option ) { $result = $wpdb->delete( $wpdb->options, array( 'option_name' => $option ) ); - if ( ! wp_installing() ) { - if ( 'yes' === $row->autoload ) { - $alloptions = wp_load_alloptions( true ); - if ( is_array( $alloptions ) && isset( $alloptions[ $option ] ) ) { - unset( $alloptions[ $option ] ); - wp_cache_set( 'alloptions', $alloptions, 'options' ); - } - } else { - wp_cache_delete( $option, 'options' ); - } - } - if ( $result ) { /** }}} but that's also before the `delete_option` hook. Instead, the cache purging logic block could be duplicated right before returning `false`: {{{ diff --git a/src/wp-includes/option.php b/src/wp-includes/option.php index 8692db7199..ab0a3f79f2 100644 --- a/src/wp-includes/option.php +++ b/src/wp-includes/option.php @@ -651,6 +651,19 @@ function delete_option( $option ) { // Get the ID, if no ID then return. $row = $wpdb->get_row( $wpdb->prepare( ""SELECT autoload FROM $wpdb->options WHERE option_name = %s"", $option ) ); if ( is_null( $row ) ) { + + if ( ! wp_installing() ) { + if ( 'yes' === $row->autoload ) { + $alloptions = wp_load_alloptions( true ); + if ( is_array( $alloptions ) && isset( $alloptions[ $option ] ) ) { + unset( $alloptions[ $option ] ); + wp_cache_set( 'alloptions', $alloptions, 'options' ); + } + } else { + wp_cache_delete( $option, 'options' ); + } + } + return false; } }}} but that's not very clean, with that much duplicate code. I'm also open to suggestions if this is even a ""core"" bug, or if it should be the responsibility of the theme/plugin code to make sure the option cache is properly cleared?" emrikol Needs Dev / Bug Wrangler Feedback 26895 Deprecate recently_edited option Options, Meta APIs 3.8 normal minor enhancement new dev-feedback 2014-01-21T08:33:53Z 2019-06-04T20:45:22Z "recently_edited option is being set when a plugin or a theme file is edited by the builtin Editor. A search, in the WordPress 3.8 source code, tells me that the option is never being read. I suggest that we deprecate that option and replace it by an action where plugins can hook and get the value of the edited file." yani.iliev Needs Dev / Bug Wrangler Feedback 50233 Limit pagination for comments SergeyBiryukov Permalinks 5.4.1 normal minor Future Release defect (bug) reopened dev-feedback 2020-05-23T21:53:08Z 2022-04-26T03:30:27Z "you can look? please https://wordpress.org/support/topic/wordpress-infinite-link-problem/ Hello. WordPress has endless link problems for many years. Note: This problem happens when we paged comment example: Others: https://perishablepress.com/wordpress-infinite-duplicate-content/comment-page-2/ https://perishablepress.com/wordpress-infinite-duplicate-content/comment-page-2754/ others https://www.wpbeginner.com/beginners-guide/how-to-properly-ask-for-wordpress-support-and-get-it/comment-page-2754/ https://www.wpbeginner.com/beginners-guide/how-to-properly-ask-for-wordpress-support-and-get-it/comment-page-5754/ others https://www.isitwp.com/best-wordpress-404-error-plugins/comment-page-3754/ https://www.isitwp.com/best-wordpress-404-error-plugins/comment-page-5754/ Attention! There are no comments on these pages. But the links are entering the article. This is the problem for google search console. If there is no comment, that link should not work. How can I fix this? Paged comments from your admin panel. And you try too If we do not paginate, this is no problem. This problem happens in paginations.. If the setting is like this. screen shot: https://prnt.sc/smhi90" devrekli Needs Dev / Bug Wrangler Feedback 10483 Change post_name's length from 200 to 400 SergeyBiryukov Permalinks normal minor Future Release enhancement reviewing dev-feedback 2009-07-25T06:31:52Z 2023-12-29T16:39:52Z "Hello, guys! Thank you very much for providing such a great piece of software! I love WordPress very much! :) I use WordPress in Russian language and the URLs on my [http://www.ielnur.com blog] consist of Russian characters. There is a [http://www.ielnur.com/blog/2009/05/снова-бросить-курить-30-тидневное-испытание/ post] with not such a long URL in Russian, but since it gets encoded to special characters it becomes too long to get fit into `post_name` field of `post` table. I've found what code needs to be changed to increase the length. I make these changes every time a new version is released. I think it would be better to submit a patch here so that others people can benefit from it and I will not need to make those changes every release. I'm attaching the patch to this ticket and asking you to apply it to the code. Thank you very much again, guys! You do a great job! :) Cheers, Elnur" elnur Needs Dev / Bug Wrangler Feedback 38207 Disable Trackbacks by Default Keep Pingbacks On Pings/Trackbacks low minor Awaiting Review enhancement new dev-feedback 2016-10-01T19:21:01Z 2017-03-07T23:23:29Z "Trackback is a manual technology. Pingback is an automated technology(automatically pings sites linked to in post content). The question comes from me as the component maintainer and I'm opening this as a place for if the proliferation of Trackback Spam and the manual requirement has made it worth disabling the receipt and/or sending of trackbacks by default while leaving pingbacks enabled. I continue to be committed to pingback and the concept in general, but I have to ask regarding the interest in trackback. I'm putting out a call for comment in this regard. The only recent trackback related requests involve expensive queries to send trackbacks(See #36824). Related #37007." dshanske Needs Dev / Bug Wrangler Feedback 44853 Remove extra condition Plugins normal minor Awaiting Review enhancement new dev-feedback 2018-08-28T03:45:58Z 2018-09-04T17:06:56Z Remove extra `if` condition from `get_plugins` function. abhijitrakas Needs Dev / Bug Wrangler Feedback 45764 blog page and homepage the same list pages and not posts Posts, Post Types 5.0.2 normal minor Awaiting Review defect (bug) reopened dev-feedback 2018-12-25T11:47:36Z 2019-12-12T19:24:07Z "Hi I don't know when this was changed but if you set the same page as blog page aswell as your homepage the website starts listing pages on that blog and home page and not posts. Why was this changed and when? Thanks for any advice. " BackuPs Needs Dev / Bug Wrangler Feedback 57507 function wp_unique_post_slug inconsistent for numerical page slugs, e.g. 404 Posts, Post Types 6.1.1 normal minor Awaiting Review defect (bug) new dev-feedback 2023-01-19T11:03:36Z 2023-01-19T11:03:36Z " {{{ if ( $post_name_check || in_array( $slug, $feeds, true ) || 'embed' === $slug || preg_match( ""@^($wp_rewrite->pagination_base)?\d+$@"", $slug ) || $is_bad_hierarchical_slug ) }}} Will always return true for preg_match as long as 'page' is optional and it is a numerical slug, e.g. 404 {{{ preg_match( ""@^($wp_rewrite->pagination_base)?\d+$@"", $slug ) preg_match( ""@^(page)?\d+$, 404"") => 1 }}} Assuming pagination is the point for this check, a possible solution could be to check if post pagination navigation exists first. {{{#!php $pagination_based = get_the_post_navigation() ? preg_match( ""@^($wp_rewrite->pagination_base)?\d+$@"", $slug ) : false; if ( $post_name_check || in_array( $slug, $feeds, true ) || 'embed' === $slug || pagination_based || $is_bad_hierarchical_slug ) }}} Suggestion: Either allow numerical slugs if it does not interfere with paginations, or disallow it with a warning. " arve5 Needs Dev / Bug Wrangler Feedback 29999 update post overwrites slug if current_user is contributor Posts, Post Types 4.0 normal minor Awaiting Review defect (bug) new dev-feedback 2014-10-16T08:09:04Z 2024-03-07T21:30:46Z "The [http://codex.wordpress.org/Function_Reference/wp_update_post/ wp_update_post] function calls [http://codex.wordpress.org/Function_Reference/wp_insert_post/ wp_insert_post] which is located in [https://core.trac.wordpress.org/browser/tags/4.0/src/wp-includes/post.php#L3068/ wp-includes/post.php] in posts.php at lines 3168 - 3171 there is this code: {{{ // Don't allow contributors to set the post slug for pending review posts. if ( 'pending' == $post_status && !current_user_can( 'publish_posts' ) ) { $post_name = ''; } }}} this will remove post_name if the current user is a contributor without any message or notification. This creates an issue because scripts/plugins that uses wp_upadate_post usually don't handle this case (the documentation doesn't cover this also - I would update the documentation but I'm wondering if there's no other solution). I don't see the issues that a contributor changing the slug would create (a contributor vs an editor) anybody does?" jnhghy Needs Dev / Bug Wrangler Feedback 14077 Add support for removal of multiple features from a post type in remove_post_type_support Posts, Post Types 3.0 normal minor enhancement new dev-feedback 2010-06-24T18:10:59Z 2020-01-09T00:34:23Z "From [http://groups.google.com/group/wp-hackers/browse_thread/thread/1843101eba1f29fc this thread] add_post_type_support allows an array to be passed as the 2nd parameter, but remove_post_type_support doesn't. The patch attached adds the functionality." Utkarsh Needs Dev / Bug Wrangler Feedback 35537 AllPosts page: sorting is not remembered Posts, Post Types 4.4.1 normal minor Future Release enhancement new dev-feedback 2016-01-19T22:43:43Z 2017-02-06T09:13:22Z "STEPS TO REPRODUCE 1) Log in (administrator). 2) Remove all posts. 3) Create 3 new posts with titles accordingly ""1"", ""2"", ""3"" 4) Go to AllPosts page. 5) Click on ""Title"" column header to sort posts by title (as a result: posts is sorted in order 1,2,3). 6) Click ""Published (3)"". 7) Click ""All (3)"" EXPECTED RESULT: posts is sorted in order 1,2,3 ACTUAL RESULT: posts is sorted in order 3,2,1" antonrinas Needs Dev / Bug Wrangler Feedback 52888 Docs: Update get_children function SergeyBiryukov Posts, Post Types normal minor Future Release enhancement reviewing dev-feedback 2021-03-23T01:38:42Z 2022-09-20T00:31:17Z get_children documentation is very confusing to read, an entire essay for what could be said in a single paragraph, so I've rewritten it. ribaricplusplus Needs Dev / Bug Wrangler Feedback 15394 "Ancient ""Are you sure you want to do this"" now confusing" Security 3.1 normal minor Future Release defect (bug) new dev-feedback 2010-11-11T21:51:26Z 2019-05-17T10:48:08Z "The default failing nonce message did not pass the wife test. Asking ""Are you sure you want to do this?"" now that there is no longer ""OK"" and ""Cancel"" buttons is confusing and my wife just asked me ""How do I tell I'm sure?"" Not sure about the best wording, I took the same approach as Twitter's expired OAuth token links with a message that does not let user think there is something to confirm." ozh Needs Dev / Bug Wrangler Feedback 47210 Allow html on site health titles and description Site Health 5.2 normal minor Awaiting Review enhancement new dev-feedback 2019-05-10T07:37:41Z 2022-09-05T20:27:28Z "Hello there, In /wp-admin/site-health-info.php#L115 we have this: {{{ }}} So we don't allow HTML content ? why!? I propose the usage of wp_kses_* to allow clean html content. Also line#141 we have this: {{{ printf( '

%s

', $details['description'] ); }}} We clearly allow any html, so I propose to sanitize using wp_kses_* too, we don't want embed/iframe/script here right? Thank you for your feedback." juliobox Needs Dev / Bug Wrangler Feedback 57826 Either core themes should not be automatically installed OR their presence should not be a site health issue Site Health normal minor Awaiting Review enhancement new dev-feedback 2023-02-28T21:12:33Z 2023-03-01T20:28:34Z WordPress automatically installs new core themes over time. The inactive presence of these core themes is then detected as a site health issue. One or the other of these things should not be true. zergling81 Needs Dev / Bug Wrangler Feedback 50047 Taxonomy parent select field not cleared after creating category Taxonomy 5.4 normal minor Awaiting Review defect (bug) new dev-feedback 2020-05-01T15:25:33Z 2020-05-01T16:53:13Z "When creating a new category in the create category view and a parent is selected, the parent selector field is not reset to ""None"" after successful submission. The same is true for custom select fields added to this view. Don't know if this behavior is on purpose but IMO doesn't make sense?" wordnixe Needs Dev / Bug Wrangler Feedback 45023 Improve parent and child category description example Taxonomy normal minor Awaiting Review enhancement new dev-feedback 2018-10-02T15:10:28Z 2018-10-03T17:56:54Z "The descriptive text under the Parent Category section of the Category page describes an example that may not be as easily understood or translatable compared to more universally translated words. Before: parent category ""jazz"" + child categories ""bebop"" and ""big band"". Screenshot: https://cloudup.com/inms-imkM-I After: parent category ""music"" + child categories ""jazz"" and ""rock"". Screenshot: https://cloudup.com/i31WAPdv7Wp This ticket proposes changing the description to the ""after"" example. Please see attachment below." joanrho Needs Dev / Bug Wrangler Feedback 19736 Add default body_class classes for Theme Names Themes 3.3.1 normal minor Future Release enhancement reopened dev-feedback 2012-01-04T16:58:07Z 2021-07-08T16:02:55Z "Although this may be more pure enhancement and quite possibly Mallory-Everest in nature, the idea of having a default `body_class` output for the Theme name seems to be a reasonable one. IF this is implemented it should also include a default class for a Child-Theme name as well as the Parent-Theme name. To that end, I am suggesting the following patch to the `body_class` function." cais Needs Dev / Bug Wrangler Feedback 38863 Text change when activating a theme Themes low minor Awaiting Review enhancement new dev-feedback 2016-11-19T02:43:03Z 2022-06-10T05:43:12Z "When switching themes, after activating we see: New theme activated. Visit site [/wp-admin/themes.php?marks=168#L168, /wp-admin/themes.php, L.168] Because it needs not to be a NEW theme, I suggest the following: ''Theme changed and activated succesfully.'' " Presskopp Needs Dev / Bug Wrangler Feedback 40412 Filter for theme actions to add extra buttons. Themes 4.7.3 normal minor Awaiting Review feature request new dev-feedback 2017-04-11T10:52:34Z 2017-04-11T10:56:26Z "In theme preview window we not have any filter to add extra buttons. > Not major. We'll add this with JS. ----- In file `\wp-admin\themes.php` {{{ echo implode( ' ', $current_theme_actions ); }}} Maybe like this: {{{ echo implode( ' ', apply_filters( 'wp_current_theme_actions', $current_theme_actions ) ); }}} Screenshot: [[Image(http://bsf.io/-dxku)]] " Mahesh901122 Needs Dev / Bug Wrangler Feedback 42008 Show warning that usernames can't be changed Upgrade/Install normal minor Future Release defect (bug) reviewing close 2017-09-27T16:10:48Z 2020-11-01T11:47:08Z "When we install WordPress, it says ""Please provide the following information. Don't worry, you can always change these settings later."" But When we want to change username, WordPress does not allow. See screenshots." rinkuyadav999 Needs Dev / Bug Wrangler Feedback 59182 Plugin/theme zip update screen max-width Upgrade/Install 5.5 normal minor Awaiting Review enhancement new dev-feedback 2023-08-24T09:55:54Z 2023-08-26T05:22:21Z "Hi, Can we set the max-width to 100rem instead of 40rem? Current CSS for wrap class. {{{ .update-php .wrap { max-width: 40rem; } }}} it should be {{{ .update-php .wrap { max-width: 100rem; } }}} let me know if this makes sense or not, please. For more information see mentioned screenshot below. " sumitsingh Needs Dev / Bug Wrangler Feedback 12756 WPMU does not handle files with two or more dots in the filename wpmuguru Upload 2.9.2 normal minor Future Release defect (bug) reopened close 2010-03-29T07:23:50Z 2022-10-14T18:47:54Z "* WPMU does download images that have two or more dots in the file name > E.g., One..jpg One...jpg One....jpg rewrites do work (checked) * this is clearly a WP issue: > /wp-content/blogs.php ... $file = BLOGUPLOADDIR . str_replace( '..', '', $_GET[ 'file' ] ); if ( !is_file( $file ) ) { status_header( 404 ); die('404 — File not found.'); } ... > WPMU removes two dots!!! > workaround: $file = BLOGUPLOADDIR . $_GET[ 'file' ]; // name.ly: workaround for files with two or more dots tested and works fine " Namely Needs Dev / Bug Wrangler Feedback 50188 Disable Media uploader if PHP file_uploads is disabled Upload normal minor Awaiting Review enhancement new dev-feedback 2020-05-16T19:32:36Z 2024-01-24T09:26:51Z "Based on ticket #50038, if the PHP configuration is {{{file_uploads = Off}}} we should disable the Media upload. Actually, when you upload a file and the file_uploads is disabled, WordPress uploads the file with a progress bar and, at the end, it gives an error because is disabled. This should affect the Media upload, probably it should tell something like ""You can't upload a file, please check the Site Health for more information"" (or something like that) but also, in any file upload (like the Image / Video / Audio on Gutenberg) should allow to pick from the media but not show the upload button, also the plugin / theme upload." JavierCasares Needs Dev / Bug Wrangler Feedback 48879 Changing Site Admin Email Assumes Username and Who Took the Action (which may be incorrect) Users 5.3 normal minor Future Release enhancement new dev-feedback 2019-12-04T20:12:16Z 2024-03-15T16:47:52Z "(Note that this is on MultiSite and I don't know exactly how it functions on a single site install.) I think the email message that is sent when someone updates a Site Admin Email Address should be modified as to NOT be addressed: Dear CURRENT_USER_NAME, and shouldn't say that ""YOU"" have recently requested to update the email. If I want to change the site admin email for a site, the confirmation email goes to the new email address (say, a client), but the email says ""Dear MadtownLems,"". We have had a few cases now where these emails alarmed users and thought they were phishing attempts or had been hacked. This is very confusing for our users, as they have received an email addressed to someone else, and it tells them that they tried to do something that they may not have tried to do. Rather, I believe the text would be much cleaner if it said something like: ""Someone ('MadtownLems') has requested to update the email address for the site..."" " MadtownLems Needs Dev / Bug Wrangler Feedback 11297 Don't email the admin when they create a user from the backend Users 2.9 low minor enhancement new dev-feedback 2009-12-01T12:05:31Z 2019-06-05T06:44:57Z "I just created the user myself. I already know I did it. I don't need to be told again. Emails should only be sent to the admin when a user registers themselves (if that is enabled). They shouldn't be sent when the admin manually creates a new user." caesarsgrunt Needs Dev / Bug Wrangler Feedback 20459 Super admin should be able to bypass banned/limited domains when creating users Users normal minor enhancement new dev-feedback 2012-04-16T16:12:25Z 2019-06-05T06:38:31Z "The function `wpmu_validate_user_signup()` is run whenever a new user is created, either through self-registration (wp-signup.php) or through manual user creation by an admin. `wpmu_validate_user_signup()` does two different kinds of validation: (1) validation that is more or less technically required by WP, like spaces in usernames, email/login uniqueness, etc. (2) checks against some admin-set membership restrictions, namely, email domain whitelist (limited_email_domains) and blacklist (`is_email_address_unsafe()` and banned_email_domains). The second kind of validation is problematic in the following use case: An MS install might restrict open membership based on email domains, but the admin might occasionally want to make exceptions to the rule and manually create an account. Currently, there are two ways to bypass the built-in checks: to temporarily remove the domain restrictions at Network Admin > Settings, or to filter `'wpmu_validate_user_signup'` and remove the error messages. Having to manually change settings for this purpose is pretty hackish. The filter method works, but my experience (from consulting with a fairly large number of MS network admins) is that this is a pretty common use case, so it seems like it should be supported by default. So I'm proposing that the domain checks be skipped when `is_super_admin()`. Patch attached." boonebgorges Needs Dev / Bug Wrangler Feedback 25419 Add icon support for widgets on the admin page and customize screens Widgets 3.9 low minor Future Release enhancement new dev-feedback 2013-09-25T17:05:07Z 2018-03-05T20:34:27Z With the incorporation of live widget previews (widget customizer), an available widget browser is displayed which lists all widgets along with a dashicon for each. These icons should be incorporated into the widgets admin page now, as well. westonruter Needs Dev / Bug Wrangler Feedback 60653 Block-based Widgets Editor - Site Logo Block is not listed. Widgets 6.4 normal minor Awaiting Review feature request assigned dev-feedback 2024-02-28T15:47:51Z 2024-03-12T19:18:51Z "It would be interesting to activate the Site Logo Block to appear in the Block-based Widgets Editor. [[Image(https://i.ibb.co/BLRLFp5/Captura-de-tela-2024-02-28-124402.png)]]" williansantana Needs Dev / Bug Wrangler Feedback 37096 Unit tests for xmlrpc_getposttitle() and xmlrpc_getpostcategory() along with patch to trim and unique returned values SergeyBiryukov XML-RPC 0.71 low minor Future Release enhancement reviewing dev-feedback 2016-06-14T00:24:25Z 2022-01-20T13:01:43Z In tonight's Contrib 2 core we created this unit test for xmlrpc_getposttitle() function pbearne Needs Early Attention 56091 Using %i for table/field names in wpdb::prepare() craigfrancis Database 6.1 low minor Future Release enhancement assigned has-patch 2022-06-28T19:10:52Z 2024-01-29T20:10:29Z "Now `wpdb::prepare()` supports `%i` for Identifiers (e.g. table/field names), via commit [53575], and ticket #52506. Queries within WP Core should use this, to ensure variables are always quoted, and avoid static analysis tools flagging unescaped SQL input (a non-`literal-string`) for the `$query` parameter: {{{#!php prepare( ""SELECT ID FROM $wpdb->posts WHERE post_type = %s"", $post_type ); $wpdb->prepare( ""SELECT ID FROM %i WHERE post_type = %s"", $wpdb->posts, $post_type ); }}} I'll write a patch for the first set, but I suspect there will be a lot of changes, and they should be checked carefully." craigfrancis Needs Early Attention 46550 Uncaught TypeError: setcookie() expects parameter 5 to be string, bool given in... Networks and Sites 5.2 normal minor 6.6 defect (bug) new has-patch 2019-03-18T05:18:36Z 2024-02-17T13:42:20Z "https://github.com/WordPress/WordPress/blob/5e62e6b2034516c0bb366f808673752030d2d2b7/wp-includes/default-constants.php#L303 {{{#!php generate_cache_key( $q, $new_request );] doesn't consider the possibility for changes to the request via [https://github.com/WordPress/wordpress-develop/blob/6.3/src/wp-includes/class-wp-query.php#L3310 posts_request_ids] filter. This can result in cache collision. For example we have one page doing `get_posts` with this filter, and we have a different page that doesn't use the filter but does the same `get_posts` with exactly same args. This will result in two different request to have same result. To give overview, `posts_request_ids`filter is used to modify final `post_ids` in a split operation. Solution is to have check for `has_filter( 'posts_request_ids' )`, serialize outcome from global `$wp_filter[ 'posts_request_ids' ]` and set to to `args` before cache_key is generated. Seralization we also allow for the cases where just one of he array of filters set in `posts_request_ids` is modified. " thekt12 Needs Docs or Unit Tests 21627 Filter for custom-background CSS selector peterwilsoncc Customize 3.4.1 low minor Future Release enhancement assigned needs-unit-tests 2012-08-18T11:46:55Z 2021-05-22T17:41:50Z "There should be an easier way for changing the css selector from body to html or any other then making your own callback. " Horttcore Needs Docs or Unit Tests 53236 Nonce lifespans are inaccurate and unintuitively affected by timezones Date/Time 2.5 normal minor Awaiting Review defect (bug) new needs-unit-tests 2021-05-20T09:51:46Z 2021-06-02T04:37:01Z "The docs on [[https://developer.wordpress.org/reference/functions/wp_verify_nonce/|wp_verify_nonce()]] specify that nonces are either 0-12 or 12-24 hours old by default, but this isn't true. In reality, the value `1` means < 12 hours old, but `2` means anywhere from 1 second to < 24 hours old. Observe what happens to the nonce tick value over a day: ||=local time=||=seconds since epoch=||=tick=|| ||2021-05-20T00:00:00+03:00||1621458000||37534|| ||2021-05-20T01:00:00+03:00||1621461600||37534|| ||2021-05-20T02:00:00+03:00||1621465200||37534|| ||2021-05-20T03:00:00+03:00||1621468800||37534|| ||2021-05-20T04:00:00+03:00||1621472400||37535|| ||2021-05-20T05:00:00+03:00||1621476000||37535|| ||2021-05-20T06:00:00+03:00||1621479600||37535|| ||2021-05-20T07:00:00+03:00||1621483200||37535|| ||2021-05-20T08:00:00+03:00||1621486800||37535|| ||2021-05-20T09:00:00+03:00||1621490400||37535|| ||2021-05-20T10:00:00+03:00||1621494000||37535|| ||2021-05-20T11:00:00+03:00||1621497600||37535|| ||2021-05-20T12:00:00+03:00||1621501200||37535|| ||2021-05-20T13:00:00+03:00||1621504800||37535|| ||2021-05-20T14:00:00+03:00||1621508400||37535|| ||2021-05-20T15:00:00+03:00||1621512000||37535|| ||2021-05-20T16:00:00+03:00||1621515600||37536|| ||2021-05-20T17:00:00+03:00||1621519200||37536|| ||2021-05-20T18:00:00+03:00||1621522800||37536|| ||2021-05-20T19:00:00+03:00||1621526400||37536|| ||2021-05-20T20:00:00+03:00||1621530000||37536|| ||2021-05-20T21:00:00+03:00||1621533600||37536|| ||2021-05-20T22:00:00+03:00||1621537200||37536|| ||2021-05-20T23:00:00+03:00||1621540800||37536|| …and over the boundary of a tick: ||=local time=||=seconds since epoch=||=tick=|| ||2021-05-20T14:59:58+03:00||1621511998||7535|| ||2021-05-20T14:59:59+03:00||1621511999||7535|| ||2021-05-20T15:00:00+03:00||1621512000||7535|| ||2021-05-20T15:00:01+03:00||1621512001||7536|| ||2021-05-20T15:00:02+03:00||1621512002||7536|| In this example, you can see that a nonce generated at 3pm and verified one second later will return 2 because of the tick change. The ticks do not align with timezones due to their basis in universal time, so nonces will always appear “old” to your code at certain times of the day, as touched on in ticket:33635#comment:2. I haven't thought of a way to reduce the huge variance in ages that have equal nonce values, but I did think of a way to make them more predictable. I've attached a patch that would align ticks to WP's timezone so there would be a predictable two ticks per calendar day, a.m. and p.m., starting at 00:00." lev0 Needs Docs or Unit Tests 10033 wpautop problems with html comments and object tags Formatting 2.8 normal minor defect (bug) new needs-unit-tests 2009-06-04T12:06:35Z 2019-06-04T19:42:36Z "Bumped into this one when upgrading my mediacaster plugin to use swfobject 2.1 (which is not 1.5 compatible), as documented here: http://code.google.com/p/swfobject/wiki/documentation I take it I'm not the only one who is going to need to upgrade a plugin. It's minor, since I'll just move the filter further down in the queue, but it's still worth reporting: {{{

Get Flash 9.0 to see this player.

}}} Gets turned into the following mess: {{{

Get Flash 9.0 to see this player.



}}} So, two/three issues: - wpautop should also ignore double object tags, and html comments - wptexturize should ignore html comments" Denis-de-Bernardy Needs Docs or Unit Tests 29913 wptexturize should handle broken HTML consistently Formatting 1.5 normal minor defect (bug) new needs-unit-tests 2014-10-10T00:38:40Z 2019-06-04T19:46:35Z "Spunoff from ticket:29557#comment:93 because it's not that important. When encountering broken HTML, `wptexturize()` should match web browser behavior, without getting too complicated. This bug is for: 1. unclosed comments: `


Lorem Ipsum quam quasi mollitia

}}} " Giorgio25b Needs Patch 50110 Incorrect property docblocks in WP_Block_Type peterwilsoncc Editor 5.0 normal minor Awaiting Review defect (bug) assigned 2020-05-07T10:08:41Z 2021-02-09T05:33:50Z "In the class WP_Block_Type the docblocks declare `@var #TYPE#` for several properties of the class. Below I will use `attributes` as an example, but this counts for all the following properties: - render_callback - attributes - editor_script - script - editor_style - style The docblock defines that the property must be a certain value ('array' in the case of attributes), but it is not set in the constructor and is optionally set in the `set_props()` method, if `args` has been supplied with the correct property. {{{#!php /** * Block type attributes property schemas. * * @since 5.0.0 * @var array */ public $attributes; }}} This allows the property to be null, which conflicts with de docblock. == Proposed solution(s) === 1. Declare default value: This might change behavior, where null is expected (see `get_attributes()` for example) {{{#!php /** * Block type attributes property schemas. * * @since 5.0.0 * @var array */ public $attributes = array(); }}} === 2. Add possible null to docblock This would lead might lead to other conflicts, such as using the the null value as an array without a type check. {{{#!php /** * Block type attributes property schemas. * * @since 5.0.0 * @var array|null */ public $attributes; }}} === 3. Do not declare @var The `set_props()` method currently does not do any type checking, so in theory all the properties listed above are `mixed`. ''(intentionally borked example)'' {{{#!php new \WP_Block_Type( 'name', array( 'attributes' => 'This is not an array.' ) ); }}} This places responsibility of type checking on implementing code, which would be most 'correct' with the current `set_props()` method." nielsdeblaauw Needs Patch 53134 Keep current URL domain for View Post on View Post link Editor 5.7.1 normal minor Awaiting Review defect (bug) new 2021-05-02T19:53:25Z 2021-07-24T17:43:12Z "Hello, I am using BrowserSync to proxy my remote site to https://localhost:3000 on my local machine through ssh forwarding. I have noticed that the localhost domain name is reverted to my site real domain on the backend for the 'View Post' link, when updating a post using Gutenberg. This behavior does not happen with the classic editor. It would be great if the 'View Post' link could retain the localhost domain on post update. Steps to reproduce: 1) Run BrowserSync or equivalent as proxy 2) Open post for edit on backend on localhost domain 3) Check 'View Post' link, it should have localhost as domain 4) Click 'Update' or 'Publish' 5) Check 'View Post' link again and it will now have the site domain instead Classifying as bug as the behavior deviates from what the classic editor does." chamois_blanc Needs Patch 59535 Page/Post scrolls up while converting quotes to paragraph Editor 6.3.1 normal minor Awaiting Review defect (bug) new 2023-10-04T11:37:35Z 2023-10-05T04:40:02Z "I found this while testing the capture toolbar for the quote block for WordPress 6.4 beta2, but was able to reproduce it in 6.3.1. == Issue In the block editor, Page/Post scrolls up while converting a quote to a paragraph. == Steps to Reproduce 1. Open a post or page. 2. Insert Title and long text so that scroll bar appears. 3. At the end insert quote block 4. Write a quote and citation 5. Click on the block so that quote block toolbar appears 6. Click on quote icon (first icon in the quote toolbar) 7. Click on transform to ""Paragraph"" == Actual Result: Page/Post scrolls up while converting a quote to a paragraph. == Expected Result: Page/Post should not scroll up while converting a quote to a paragraph. " hardikgohil Needs Patch 53046 Scrollbars Broken in latest visual editor Editor 5.7.1 normal minor Awaiting Review defect (bug) new 2021-04-15T23:34:48Z 2021-05-18T06:14:18Z "Not only is the mouse disabled from scrolling using its scroll wheels, but the scroll bars on the side of the screen also are disabled except for the thumbs. You can drag the thumbs to scroll the content, but you can't click the arrows or scroll with the mouse. Rather clicking the arrows shows the clicked state of the arrow icons, but nothing scrolls. Also, from within a block, a new set of full-screen scrollbars appears inside the outermost scrollbars (which make no sense and do nothing--mostly because the box is 1 unit high and doesn't need to stroll)" WhirledPress Needs Patch 57962 The active state is not being displayed in the Justify content of the quick edit. Editor normal minor Awaiting Review defect (bug) new close 2023-03-21T07:54:30Z 2023-03-21T21:11:05Z While going through the blog I wan to make the title justified I found that the justify-content tab is not assigned the active state. I am also attaching the video for the same below. hilayt24 Needs Patch 49293 When trying to add an existing post category to a post - simply check the box of this category Editor 4.8 low minor Future Release defect (bug) new 2020-01-26T12:24:41Z 2020-01-28T16:50:55Z "What happens now: When writing a new post and trying to add a new category for this post, if this category already exists - nothing really happens. What should happen: If this category already exists - simply check the box of this category. " shayatik Needs Patch 48539 WordPress Editor sometimes chops off titles in Chrome Editor 5.2.4 normal minor Awaiting Review defect (bug) new 2019-11-08T15:16:20Z 2019-11-08T22:38:19Z "Somtimes the WordPress Editor chops titles at the top of a page when editing. Unlike the ""missing images"" problem I reported, this one does NOT show up in Firefox. Example Attached" cube1us Needs Patch 51644 allowed_block_types breaks if array keys become non-sequential Editor 5.5.1 normal minor Awaiting Review defect (bug) new 2020-10-27T12:40:21Z 2021-02-23T20:38:16Z "When the blocks array is filtered using `allowed_block_types`, I want to remove some blocks. Using a loop and a combination of `array_search()` and `unset()`, I remove the blocks I need to remove. However, it seems that this results in all blocks being available (the same as returning true for `allowed_block_types`). This can be easily averted in your own hooked function by using `$blocks = array_values( $blocks )` to reset the array keys so they're sequential again. However, this seems like a minor bug worth fixing at root for anyone else removing blocks this way (apply `array_values()` to the array if an array is returned by the `allowed_block_types` filter). Not sure if this might be affected by decisions made for https://core.trac.wordpress.org/ticket/50706" gyrus Needs Patch 57823 buttons don't align center Editor 6.1.1 normal minor Awaiting Review defect (bug) new close 2023-02-28T15:44:54Z 2023-03-06T07:19:44Z "Buttons aren't aligning center. Container not set to `display: flex;` or `display: grid;` https://store.irishtradmusic.org/ The big button in the center centers when I add CSS: {{{ .wp-block-buttons { display: flex; } }}}" stinkykong Needs Patch 55844 color picker has scroll in styles menu Editor 6.0 normal minor Awaiting Review defect (bug) new 2022-05-26T12:29:42Z 2022-05-28T00:32:18Z in the color picker inside the styles menu moving your color picker circle to the right makes the color picker have a scrollbar in the bottom. tomkolron Needs Patch 11465 custom field duplicated westi* Editor 2.8.4 normal minor Future Release defect (bug) accepted 2009-12-16T21:09:23Z 2022-06-08T22:40:11Z "When I enter the information for a custom field and click on Preview without first clicking Add Custom Field, the custom field is saved. But then when I click Publish, it is saved again, appearing in the post twice. If I click Add Custom Field before Preview, subsequent Publish does not duplicate the custom field. But it is very convenient and efficient to be able to avoid a separate save of the custom field. " ericr23 Needs Patch 53682 tags (keywords) with umlauts don't get saved in german locale Editor 5.7.2 normal minor Future Release defect (bug) new 2021-07-17T15:41:20Z 2023-07-09T16:44:05Z " == This report is about assigning keywords to an article. **First keyword:** ""Gärten"" with slug ""gaerten"" (exists already) **Second keyword:** ""Garten"" with slug ""garten"" (was not created yet) I tried to apply the new keyword ""Garten"", but once I saved the article, the keyword ""Gärten"" was assigned in the preview. I removed it and tried to assign ""Garten"" once again, but WordPress keeps applying ""Gärten"" to the article, even though **the editor showed ""Garten"" in the sidebar** (as expected). I then created the keyword ""Garten"" with slug ""garten"" manually in the keyword management interface. Now I have both keywords in my database. But still, when I try to assign ""Gärten"" in the editor, WordPress keeps changing it to ""Garten"", once the article is saved and I view the preview. The slugs are different (gaerten vs. garten), but it seems like the editor confuses the German umlauts in Gärten with Garten. I am using the latest WordPress 5.7.2 and the Classic Editor." spielautomat4 Needs Patch 53790 Do not close block inserter when selecting blocks Editor normal minor Awaiting Review enhancement new 2021-07-27T01:45:40Z 2021-07-27T03:44:12Z "I suggest changing the behavior of the list of all blocks in the block editor to NOT automatically close the list as soon as the user has clicked elsewhere on the page. The automatic closing of the list feels jarring and unexpected, and it increases the number of clicks required to build a post with many blocks. See my short video (1:27) for specifics: https://www.youtube.com/watch?v=SfZqZxzKUuk" curtiskessler Needs Patch 60729 YouTube embed start= Embeds 6.4.3 normal minor Awaiting Review defect (bug) new 2024-03-08T07:24:54Z 2024-03-08T07:24:54Z "Hi. I am experiencing an issue where I am seeing the video start time being either randomized or shifted for each load. Expected behavior: YouTube video embedded with a timestamp like {youtube_url}start=5064, video starts at 1:24:24 each time video is loaded on a blog post. Issue 1: if ""resize for smaller devices"" is active the start point is randomized before posting. E.g. at 5064 it start approximately 30 seconds before it should (say 5034). I shift the start time to 5094 to try and compensate, resulting in it starting earlier than previously (say 5004). I leave it at 5064 and publish the blog post, with the result of it starting at 0 seconds (incognito mode, fresh browser, logged in). Issue 2: Resize for smaller devices is turned off. Now the first time the video is loaded it starts where it is supposed to start at 5064 seconds (steps: start video -> refresh page -> start video -> refresh -> ...). But, for each time the blog post is loaded and the viewers presses play, the start time shifts back approximately 30 seconds. This does not happen in incognito mode, here it loads at the correct timestamp each time the page is reloaded and video started." chrdre Needs Patch 44074 oEmbed with many
 tags do not work		Embeds		normal	minor	Awaiting Review	defect (bug)	new		2018-05-14T14:31:21Z	2019-01-17T00:56:14Z	"If an oEmbed has more than ten {{{
}}} tags {{{WP_oEmbed::_strip_newlines}}} (called by {{{oembed_dataparse}}}} filter) returns a wrong result for it.

All {{{
}}} tags get temporarily replaced by a token, the newline stripping gets done and then the tokens {{{
}}} get replaced back to their HTML. The tokens unfortunately are just {{{__PRE__}}} plus a counter (e.g. {{{__PRE__0}}}, {{{__PRE__1}}}) Thus if there are more than ten {{{
}}} tags there will be tokens like {{{__PRE__10}}}. These obviously clash with previous tokens.

Granted, this is ''quite'' uncommon but nonetheless it should be fixed in my opinion."	jagszent
Needs Patch	57451	Cross Site Request Forgery on Admin of any wordpress site to export files		Export		normal	minor	Awaiting Review	defect (bug)	new		2023-01-12T13:13:23Z	2023-03-20T04:34:24Z	"[Marked as No Impact By WordPress Hackerone Team]

Cross-Site Request Forgery (CSRF) is an attack that forces an end user to execute unwanted actions on a web application in which they’re currently authenticated. With a little help of social engineering (such as sending a link via email or chat), an attacker may trick the users of a web application into executing actions of the attacker’s choosing

Steps To Reproduce:

1. Login to WordPress Backend as an Admin
2. Go-to Tools > Export > Select what to export
3. Select the Data you want to export. Capture this request using a web-proxy like BurpSuite
4. Since this is a GET request, Copy the URL to which request is made.
5. Send this URL to another admin or user with equal rights.
6. When he clicks on the URL, he shall download the file automatically.

The endpoint vulnerable:
`http:///wp-admin/export.php?download=true&content=all&cat=0&post_author=2&post_start_date=0&post_end_date=0&post_status=0&page_author=0&page_start_date=0&page_end_date=0&page_status=0&attachment_start_date=0&attachment_end_date=0&submit=Download+Export+File`

Recommendations
Enforce CSRF protection like wpNonce Token for file export endpoint.

Impact
Unauthorised File Download on an administrator's PC
An attacker can write a script which sends 100s of GET requests at once to the endpoint, and share the script to another user, and when he downloads 100 files at once, it shall also consume his disk space"	f41z4n
Needs Patch	58939	Option to bypass fetch_feed cache on call.		Feeds		normal	minor	Awaiting Review	feature request	new		2023-07-30T20:47:35Z	2023-07-30T20:47:35Z	"I have a use case where users are limited to the normal 12 hour cache restrictions, but I would like to enable admins to be able to bypass the cache and pull the feed. 

Maybe a filter or optional parameter that would allow this? "	picard102
Needs Patch	32774	Improve WP_Filesystem::dirlist() format consistency		Filesystem API		normal	minor		defect (bug)	new		2015-06-24T07:05:58Z	2019-06-04T19:49:36Z	"At present the return values of dirlist() between the various methods are scattered between several different formats

||Field||Direct||FTP Ext||FTP Sockets||SSH2||
||name||Yes||Yes||Yes||Yes||
||perms||Yes||Yes||Yes||Yes||
||permsn||Yes||Yes||Yes||Yes||
||number||`false`||Yes||Yes||`false`||
||owner||Yes||Yes||Yes||Yes||
||group||Yes||Yes||Yes||Yes||
||size||Yes||Yes||Yes or ``||Yes||
||lastmodunix||Unix Timestamp||No||No||Unix Timestamp||
||lastmod||`Nov 15`||No||No||`Nov 15`||
||time||`02:12:48`||Unix Timestamp||Unix Timestamp||`02:12:48`||
||year||No||Maybe||Maybe||No||
||month||No||`Nov`||`Nov`||No||
||day||No||`15`||`15`||No||
||hour||No||`02`||`02`||No||
||minute||No||`12`||`12`||No||
||type||`d` or `f`||`d`, `f`, or `l`||`d`, `f`, or `l`||`d` or `f`||
||isdir||No||Yes||Yes||No||
||islink||No||Yes||Yes||No||

If the FTP Server was Windows, it'd complicate it further by not returning certain fields, using different data in them, or getting confused and not returning any data.

The attached patch boils it down to a consistent result of `[ 'filename.ext' => [...], ...]` with the nested arrays of:
||Field||Value||
||name||Filename||
||time||Unix Timestamp of last modified||
||size||File size or false for Directories||
||type||`d`, `f`, or `l` for Directory, File, or Link respectively||
||perms||A formatted human-readable `drwxr-xr-x`||
||permsn||A octal as string `'0755'` for Back-compat purposes||
||owner||Owner ID or name||
||group||Group ID or name||
||files||If it's a recursive directory lookup, a nested array of files||

A number of these are only got back-compat or to match the FTP output - most of these fields are not used by WordPress at all - Specifically `group`, `owner`, `perms`, `permsn`, and `time` are ignored 100% by WordPress (along with a lot of the methods)
Changing this has some back-compat issues for any plugins doing anything special with the fields - however they've had to work around the fields returning random content already, so this shouldn't be a huge issue (or they were already broken)"	dd32
Needs Patch	15006	Closing tag for empty 

tag is removed Formatting 3.0 normal minor defect (bug) reopened 2010-10-01T13:48:12Z 2019-06-04T19:43:16Z "I have a page post that starts like this: {{{

Text Here

More Text Here }}} The HTML source saves correctly, but the page output omits the closing tag for the second P element, causing the rest of the page to be invalid. If you have any trouble reproducing this I will be happy to debug it on my server." miqrogroove Needs Patch 60124 Grouping a Quote Block turns the Quote to a Paragraph Formatting 6.4.2 normal minor Awaiting Review defect (bug) new 2023-12-21T03:10:24Z 2023-12-21T03:10:24Z "When using the Block Editor and attempting to 'group' an existing Quote block, the 'Quote' block gets converted to a 'Paragraph' block. My expectation is that the Quote block would be grouped inside of a Group block, but instead it seems to convert the Quote block into a Group block and then has the quote content as a paragraph block within." hanttula Needs Patch 58872 wpautop not disabled when blocks are inserted dynamically Formatting 6.1.1 normal minor Awaiting Review defect (bug) new 2023-07-21T18:17:09Z 2023-07-21T18:17:09Z "**WP Version** Tested on 6.1.1, but seems to still be present on the trunk. **Context** Our theme has multiple page-header styles. Users can insert any one of those as the first block of a page, or leave it out. If it's left out, we inject a default header block as the first block of the page using a customer WP_Block_Parser. We've also imported a large number of pages from a previous pre-Gutenberg WP system, so not all posts have block content. **The Problem** On legacy posts that do not have block content, wpautop is enabled, ''even for the injected header block'', resulting in extraneous
and

tags. If there's even a single block in the post content, the block renders normally. The source of the issue is that do_blocks (https://core.trac.wordpress.org/browser/trunk/src/wp-includes/blocks.php#L1166) renders the blocks based on the results of the parser, but disables `wpautop` based on a call to has_blocks(), which uses the unparsed content to determine if there are any blocks in the post. I recognize this is an edge case, as we're dealing with both legacy content and an (ab?)use of a custom block parser to inject blocks into blockless content, so it's not likely to be a high priority. But if the ""block_parser_class"" hook is going to allow us to override the parser, do_blocks should respect the blocks that are returned regardless of the original content string, and override wpautop accordingly. **Test Cases** Attached are: * A single.php page template file that succinctly captures the problem * The contents of two pages. One has no blocks and shows the wpautop problem. The other contains a single block and shows wpautop being disabled correctly. Use the Code Editor to enter this content into a page or post." jbeninger Needs Patch 51482 wp_kses_post should filter javascript content as well as the tags, but not the actual javascript itself. If you sanitize some content using wp_kses_post that contains world!""; wp_kses_post($str); Outputs: hello myvar = 'foobar'; world! Expected output: hello world!" janmiddelkoop Needs Patch 54136 Slideshow gallery shown as a tiled gallery when using shortcode with Classic Editor Gallery 5.8.1 normal minor Awaiting Review defect (bug) new close 2021-09-16T19:18:33Z 2021-12-15T03:15:56Z "The issue is happening with the Gallery Block, [https://wordpress.com/support/wordpress-editor/blocks/gallery-block/2/ when added through the Classic Editor as explained here.] Adding it with the shortcode {{{[gallery]}}} and the variable {{{type: slideshow}}} outputs it as a tiled gallery instead of showing a slideshow. [https://wordpress.org/support/topic/what-options-are-currently-available-in-the-wordpress-gallery-shortcode-2 This was initially reported here as a Jetpack issue], but I was able to reproduce it without Jetpack installed, and with a default theme (Twenty Seventeen). " muffinpeace Needs Patch 47744 WordPress default galleries do not display properly on Safari 10.1 and possibly other older browsers Gallery 5.2.2 normal minor Awaiting Review defect (bug) new 2019-07-20T20:48:07Z 2019-07-25T21:38:27Z "The following thread details the problem: [https://stackoverflow.com/questions/33636796/chrome-safari-not-filling-100-height-of-flex-parent] Images are nested inside a flex container. The child elements have a height of 100% which does not work on these older browsers such as Safari 10.1. This is because the parent element does not have a set height. So the child element doesn't know what 100% height is. The correct way to do it is to remove the 100% height from everything and use flex throughout the elements. {{{ .wp-block-gallery .blocks-gallery-image, .wp-block-gallery .blocks-gallery-item { flex-direction: row; } .wp-block-gallery .blocks-gallery-image figure, .wp-block-gallery .blocks-gallery-item figure { height: auto; align-items: stretch; } .wp-block-gallery.is-cropped .blocks-gallery-image a, .wp-block-gallery.is-cropped .blocks-gallery-image img, .wp-block-gallery.is-cropped .blocks-gallery-item a, .wp-block-gallery.is-cropped .blocks-gallery-item img { height: auto; display: flex; } .wp-block-gallery .blocks-gallery-image figcaption, .wp-block-gallery .blocks-gallery-item figcaption { left: 0; } }}} The above CSS fixes the issue and should replace the current CSS. " billybidley Needs Patch 59843 Headers of the table on make.wordpress blog breaks after a few second of load ( check the url in description) General normal minor Awaiting Review defect (bug) new 2023-11-08T18:56:49Z 2023-11-08T19:25:19Z "The header of the first table in the following link breaks after a moment. https://make.wordpress.org/core/2023/11/08/merging-performant-translations-into-core/ " thekt12 Needs Patch 52359 Links in Gutenberg Continue to be Built When Typing General normal minor Awaiting Review defect (bug) new 2021-01-25T12:35:42Z 2021-01-25T15:39:39Z "If adding a link to the trailing word or phrase in Gutenberg, the link continues to be built when you continue typing. Basically, the anchor tag keeps getting pushed to the right as you type. To reproduce...type a word or phrase and end in a linking word or phrase. For this example, we will link to the word WordPress. Highlight WordPress, click the link icon in the toolbar and add the URL https://www.wordpress.org. Then continue typing. The new text will continue as part of the link. Expected behavior would be that the link does not continue to be built after the target word or phrase." dlfulle Needs Patch 59273 Plugin: Create Block Theme Bug General 6.3 normal minor Awaiting Review defect (bug) assigned 2023-09-03T18:40:57Z 2023-09-04T11:40:34Z "I'm not sure where to file this bug. So please put it whereever it's relevant. When I use the Create Block Theme plugin with WP 6.3 and try to install a Google Font this error comes up: ""Error: `DISALLOW_FILE_EDIT` cannot be enabled in wp-config.php to make modifications to the theme using this plugin."" I have tried to enable this in the wp_config.php, but this does not work. Adding fonts should be more easy in the theme. " perthykjaerjensen Needs Patch 54851 Prevent unnecessary code comments from being output to the front end General normal minor Awaiting Review defect (bug) new 2022-01-18T13:01:39Z 2022-01-19T13:44:18Z "Gutenberg's ""Post Comments"" block appears to pull its code from the WordPress' theme compat `comments.php` file here: https://github.com/WordPress/wordpress-develop/blob/a0b1f27de6c928fde51bbc7078b32ca9c9d6ed8d/src/wp-includes/theme-compat/comments.php#L30-L75 This includes some code comments that may be useful for developers, but don't actually need to be send to the front end: [[Image(http://cldup.com/ebPNDuXdBe.png)]] I'd suggest we change these from HTML comments to PHP comments, so they aren't visible in the outputted markup. --- Related: https://github.com/WordPress/gutenberg/issues/37989 Tested with Gutenberg 12.4 WordPress 5.8.3" kjellr Needs Patch 55930 Provide comment syntax for templates and template parts General 6.0 normal minor Awaiting Review defect (bug) new 2022-06-06T05:59:02Z 2023-01-17T21:16:31Z "''Thanks to all of you for working on this great Free Software project! '' I'm trying to add copyright and license information to my theme. I do so using SPDX headers using REUSE tool [https://reuse.software]. This adds information to the `.html` files using HTML comments (``). The **Site Editor** in **WordPress 6.0** doesn't seem able to handle with regular HTML comments in templates and template parts. On a new theme created using `new-empty-theme.php` this results in the following `index.html` page for example: {{{ }}} It renders just fine, but in the Site Editor these comments of templates and template parts get treated as blocks. This results in an error for each template and page template that has the HTML annotations: ""**This block has encountered an error and cannot be previewed.**''''"" [[Image(https://user-images.githubusercontent.com/7458098/172100897-8fdc7d30-13c1-443d-b951-d9d004c73118.png)]] Copying the block contents (source code) the resulting output is as follows: {{{

}}} So it seems that the comment is treated as a paragraph. Besides this being valid HTML, I couldn't find anything about a separate comment syntax in the [https://developer.wordpress.org/themes/block-themes/templates-and-template-parts/] documentation. **I expect the Site Editor to ignore non-wp comments rather than trying to parse them as blocks.** ''I documented some other experiences with using REUSE on WordPress themes in an issue at the REUSE project: [https://github.com/fsfe/reuse-tool/issues/537]'' " wprediscovered Needs Patch 60572 block_core_navigation_render_inner_blocks loses caret for parent items General 6.4.3 normal minor Awaiting Review defect (bug) new 2024-02-19T12:18:58Z 2024-02-25T10:35:35Z "When we build a menu via the blocks editor the regular way, and create a parent menu items with a submenu, the parent menu item is (somehow) marked as a parent. It receives a caret automatically in Twenty Twenty Four theme. When programmatically creating a menu via `block_core_navigation_render_inner_blocks`, the parent-child relationship is not marked automatically. There is no dropdown caret in the parent menu item. Reproduction scenario: - Twenty Twenty Four theme - Go to Editor and manually create Navigation - Parent item ""Post A"" - Add a submenu - Child item ""Post B"" - View the website. Post A is parent, has a dropdown caret and Post B is below it Now, do it programmatically via block_core_navigation_render_inner_blocks: {{{ function block_core_navigation_render_inner_blocks($items) { return new WP_Block_List(array( new WP_Block([ 'blockName' => 'core/navigation-link', 'attrs' => [""label"" => ""Post A""], 'innerBlocks' => array(new WP_Block([ 'blockName' => 'core/navigation-link', 'attrs' => [""label"" => ""Post B""], 'innerBlocks' => [], 'innerHTML' => '', 'innerContent' => [], ])), 'innerHTML' => '', 'innerContent' => [], ]) )); } }}} View the website. There is no dropdown caret applied to the parent post (Post A)" anaid Patch Needs Refresh 55486 register_block_type_from_metadata does NOT work within a theme but as a plugin General 5.9.2 normal minor Awaiting Review defect (bug) new 2022-03-30T01:02:26Z 2023-05-30T12:34:44Z "I created a wordpress block and it guides me to the official documentation and it came to work as an external plugin, taking into account the architecture of block.json for its use, however it has not worked for me when the block is required to be integrated into a theme, delivery wrong path request looking in plugin folder plus adding another path. example error peticion https://domain.local/wp-content/plugins/D:/xampp/htdocs/wp-content/themes/NewsPaper/inc/gutenberg/myblock/index.js?ver=d395fe5d9d90bd6565685c91d8d38888" andre3600 Needs Patch 59916 API Docs: update comment endpoint does't have example request gavande1 General normal minor Awaiting Review enhancement assigned 2023-11-16T11:02:29Z 2023-11-27T18:39:26Z "**Details** I noticed that the comment update API endpoint doesn't have an example request, even though the API document has a title for it. **Link to doc** https://developer.wordpress.org/rest-api/reference/comments/#example-request-2" gavande1 Needs Patch 59432 Compliant with W3C coding standards General 6.3.1 normal minor Awaiting Review enhancement new 2023-09-23T08:04:02Z 2023-11-10T22:15:06Z "When validating any WordPress site, warnings appear: 1. Trailing slash on void elements has no effect and interacts badly with unquoted attribute values. Example: `` `` Also in tags img, button etc 2. The type attribute for the style element is not needed and should be omitted. Example: ` }}} Becomes: {{{
}}} And: {{{ }}} Becomes {{{
}}} This happens because wpautop adds those BR tags to the post. (As it should, just not within STYLE or SCRIPT tags.) I've made a (temporary?) workaround for this by creating a pre and post event for wpautop, which substitute the necessary newlines by a temporary value in the pre event and placing them back in the post event. Although I think this should be incorporated in wpautop itself. See also: http://wordpress.org/support/topic/76433 and http://wordpress.org/support/topic/76297 While searching trac I also found ticket #2346, which is about the same problem, but which was for 2.0 and self-closed by the submitter? P.S. I have TinyMCE turned of." Nazgul Needs Dev / Bug Wrangler Feedback 11678 wpautop() fails on uppercase closing tags Formatting 2.9 normal normal defect (bug) new dev-feedback 2009-12-31T11:26:11Z 2019-06-04T19:42:47Z "To reproduce, in a post enter: {{{

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

}}} View the post (source) and you get: {{{

Welcome to WordPress. This is your first post. Edit or delete it, then start blogging!

}}} Because I (incorrectly) entered an uppercase closing

tag, wpautop() thinks there is no closing tag so adds a

, which then often renders as a double

tag. Close if this is not a bug, though I thought it may be good to do some sanitizing or something on uppercase tags. " joehoyle Needs Dev / Bug Wrangler Feedback 30644 """wpautop"" Enhancements" Formatting normal normal enhancement new dev-feedback 2014-12-09T18:35:14Z 2020-08-11T00:30:02Z "Since there are several problems (e.g. invalid markup) with the current ""wpautop"" function I tried to come up with a new approach. The text gets parsed and a little analyzed in order to generate valid and comprehensible markup. The script is not really compatible with the current implementation since whitespaces and line breaks are added differently. Performance is slightly worse, depending on the input (normal text vs. heavy html) of course. Comments in the code are still missing. I think Shortcodes should also be considered in this markup generation process so the additional use of ""shortcode_unautop"" could be avoided. Please let me know what you think and test it if you like. == Sample === Input {{{ paragraph


paragraph test italic normal
paragraph
paragraph
paragraph
  • line
  • paragraph paragraph
paragraph
  
  Honor
    this whitespace

paragraph paragraph

paragraph

text
}}} === Output {{{

paragraph


paragraph test

italic
normal

paragraph

paragraph

paragraph

  • line
  • paragraph

    paragraph

paragraph

  
  Honor
    this whitespace

paragraph

paragraph

paragraph

text
}}}" stefanrz Needs Dev / Bug Wrangler Feedback 54322 Add Logical Properties to safecss_filter_attr Formatting 5.8.1 normal normal Awaiting Review enhancement new dev-feedback 2021-10-26T07:59:07Z 2021-11-19T18:16:32Z "== Background CSS Logical Properties and Values give easier control over automating different writing mode formats by using logical, rather than physical directions. In other words, it means that the intended spacing, sizing, etc for each appropriate side of a box element translate seamlessly. Mozilla Reference: https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Logical_Properties With the increase in inline styling from blocks, it's important to add more flexibility to how a theme or plugin developer might want to style their spacing components or future proof them as accessibility and internationalization become increasingly important and stop of mind. Global usage is at a decent enough support level where it makes sense: https://caniuse.com/?search=logical%20properties. == Proposed Enhancement The proposed addition would just be to add to the properties to the default array in safecss_filter_attr(). File: wp-includes/kses.php: https://github.com/WordPress/wordpress-develop/blob/98bf67e02b0a4b4aa3848f4e8266c4fd66cdaad0/src/wp-includes/kses.php#L2170 The complete list of Logical Properties: {{{ // Properties for sizing 'block-size', 'inline-size', 'max-block-size', 'max-inline-size', 'min-block-size', 'min-inline-size', // Properties for borders 'border-block', 'border-block-color', 'border-block-end', 'border-block-end-color', 'border-block-end-style', 'border-block-end-width', 'border-block-start', 'border-block-start-color', 'border-block-start-style', 'border-block-start-width', 'border-block-style', 'border-block-width', 'border-inline', 'border-inline-color', 'border-inline-end', 'border-inline-end-color', 'border-inline-end-style', 'border-inline-end-width', 'border-inline-start', 'border-inline-start-color', 'border-inline-start-style', 'border-inline-start-width', 'border-inline-style', 'border-inline-width', 'border-start-start-radius', 'border-start-end-radius', // Properties for margin & padding 'margin-block', 'margin-block-end', 'margin-block-start', 'margin-inline', 'margin-inline-end', 'margin-inline-start', 'padding-block', 'padding-block-end', 'padding-block-start', 'padding-inline-end', 'padding-inline-start', // Properties for float & positioning 'inset', 'inset-block', 'inset-block-end', 'inset-block-start', 'inset-inline', 'inset-inline-end', 'inset-inline-start', // Other Misc Props 'caption-side', 'overflow-block', 'overflow-inline', 'overscroll-behavior-block', 'overscroll-behavior-inline', 'resize', 'text-align' }}} " wazeter Needs Dev / Bug Wrangler Feedback 52444 Add support for Telegram Messenger Protocol Formatting 3.3 normal normal Awaiting Review enhancement new close 2021-02-04T10:56:32Z 2021-02-05T06:39:35Z "I found an issue with a link to Telegram messenger. The simple link works correct {{{}}} If I add “target”, it works correct on pages. {{{}}} But if I use it in «Custom HTML» widget, I see a wrong result code: {{{}}} I asked The7 theme support and they have said “it works the same with the standard WP theme”. Screenshot from support:[https://www.evernote.com/l/AnTcHk6kxa5Ltb_UT4cgDp7V-ofL4md-1fQ]" customer8765 Needs Dev / Bug Wrangler Feedback 26868 Function 'make_clickable()' doesn't make hyperlinks from explicit URLs using the `mailto:`, `tel:` and other schemes that do not start with `//` Formatting 3.8 normal normal enhancement new needs-unit-tests 2014-01-18T16:00:14Z 2019-06-04T19:45:21Z "Function `make_clickable()` tries to recognise URLs and convert these into clickable hyperlinks. The function is by default configured as a filter for comment text. Unfortunately, the function assumes that all explicitly declared URLs begin with the string `//` after the scheme and colon parts which is not the case for the `mailto:`, `tel:` and many other schemes. Such URLs could usefully be made clickable, especially for use on smartphones and tablets. This also leads to inconsistencies between explicitly and implicitly declared URLs. For example, the string `myemail@mydomain.com` is converted into a clickable hyperlink whilst the string `mailto:myemail@mydomain.com` is not. By contrast, the TinyMCE post editor correctly and automatically makes both implicit and explicit `mailto:` links clickable but does nothing with `tel:`. For reference, the syntax of URLs is defined by http://tools.ietf.org/html/std66, the `mailto:` scheme by http://tools.ietf.org/html/rfc6068 and that for `tel:` by http://tools.ietf.org/html/rfc3966. As #16892 has illustrated, parsing URLs can be hard. The use of `wp_allowed_protocols()` may help in detecting which strings we wish to make clickable. Found whilst testing #22946." mdgl Needs Dev / Bug Wrangler Feedback 43147 Introduce `esc_html_comment` and translation related functions Formatting normal normal Awaiting Review enhancement new dev-feedback 2018-01-23T15:27:17Z 2019-01-16T06:50:09Z "Triggered by the following PR on Yoast SEO [https://github.com/Yoast/wordpress-seo/pull/8687 #8687] I saw the need for `esc_html_comment` functionality in WordPress. This patch is based on the current API for formatting and escaping functions. The implementation is based on the specifications found on the [https://www.w3.org/TR/html51/syntax.html#sec-comments HTML specifications page]. I've added unit tests to cover the situations that I could come up with." jipmoors Needs Dev / Bug Wrangler Feedback 19100 Introduce esc_color() Formatting normal normal Future Release enhancement new dev-feedback 2011-11-01T12:16:14Z 2020-03-04T06:27:35Z Currently there is no way to escape a color in hexadecimal notation before printing it to a block of css or saving to the database. Many themes like to introduce functionality, whether it be core-supported or completely custom, to change the color of various parts of the templates. I believe that a function such as `esc_color()` would promote best practices while ensuring that unintended values do not get stored as colors and thus echoed in css blocks potentially breaking display. mfields Needs Dev / Bug Wrangler Feedback 26759 New Generic Sanitize Functions for Core Formatting 3.8 normal normal enhancement new dev-feedback 2014-01-02T17:54:48Z 2019-06-04T19:45:16Z "Core currently supplies a number of sanitize functions: {{{ sanitize_email() sanitize_file_name() sanitize_html_class() sanitize_key() sanitize_meta() sanitize_mime_type() sanitize_option() sanitize_sql_orderby() sanitize_post_field() sanitize_text_field() sanitize_title() sanitize_title_for_query() sanitize_title_with_dashes() sanitize_user() }}} They all sanitize by usage, not by data type. As such, I (and I suspect others) wind up using these to escape things they weren't initially meant for -- for the sake of brevity, and it's just quicker and leads to tidier code. I believe it could result in better and simpler sanitizing if we were to include sanitize-by-format functions in core. For example, {{{ wp_sanitize_numeric( $raw ); // [\d] wp_sanitize_numeric_float( $raw ); // [\d\.,] allowing both commas and periods as decimal indicator and thousands seperator wp_sanitize_hex( $raw ); // [\da-f] case-insensitive wp_sanitize_alphanumeric( $raw ); // [\da-z] case-insensitive wp_sanitize_letters( $raw ); // [a-z] case-insensitive wp_sanitize( $raw, $regex ); // uses passed in regex to determine what to strip. }}} The specific functions to use are up for discussion. I'm just hoping to make it simpler for users to sanitize data by expected type. As a side note, this will let folks use `wp_sanitize_numeric()` to sanitize integers larger than `PHP_INT_MAX` -- which tumblr and twitter IDs often happen to be for imports and feeds and the like (as casting to `(int)` isn't a good idea)." georgestephanis Needs Dev / Bug Wrangler Feedback 57021 Sanitize should accept broader types Formatting 6.2 normal normal Awaiting Review enhancement new close 2022-11-07T14:39:00Z 2024-02-07T20:21:43Z "by default $_GET/$_POST can be string|array type. All sanitize functions accept only string, which makes it necessary to validate $_GET/$_POST for `is_string` all the time before calling sanitize function to avoid PHP notices. Instead sanitize function should accept mixed param and validate string internally." kkmuffme Needs Dev / Bug Wrangler Feedback 39636 Smilies not converted when directly followed by punctuation marks Formatting 4.7.1 normal normal Future Release enhancement new dev-feedback 2017-01-19T10:29:30Z 2022-04-11T03:02:17Z "Steps to recreate: - Create a new post or comment - Insert a smilie directly followed by a period or other punctuation mark such as :). - View the post or comment Expected: Ideally the smilie would show followed by the punctuation mark. I've attached a screenshot showing how a post with the following text appears. Smiles with a space between them and the punctuation mark show, but the others do not. {{{ This is a test :). It uses smilies :) If a smilie has punctuation directly after, it is not converted :(! :( The expected behavior would be to look like this: :) ! :) , However instead they appear as this :)! :), }}} " ourvalley Needs Dev / Bug Wrangler Feedback 22402 Stripping non-alphanumeric multi-byte characters from slugs Formatting normal normal enhancement new dev-feedback 2012-11-10T05:07:10Z 2019-06-04T19:44:12Z "`sanitize_title_with_dashes()` strips non-alphanumeric characters from a title to create a slug. Unfortunately it only strips ASCII non-alphanumeric characters. Apart from a few exceptions, all multi-byte characters are preserved. This means all non-Western (and plenty of Western) non-alphanumeric characters end up in the slug as they're treated just like any other multi-byte character. As an example, here are some common non-alphanumeric Chinese characters which would ideally be stripped from slugs, but are not: * 。 (U+3002, Ideographic Full Stop, %E3%80%82) * , (U+FF0C, Fullwidth Comma, %EF%BC%8C) * ! (U+FF01, Fullwidth Exclamation Mark, %EF%BC%81) * : (U+FF1A, Fullwidth Colon, %EF%BC%9A) * 《 (U+300A, Left Double Angle Bracket, %E3%80%8A) * 》 (U+300B, Right Double Angle Bracket, %E3%80%8B) Obviously it would be impractical to make a list of ''all'' the non-ASCII characters we want to strip from slugs. The list would be gigantic. So the question is, would it be possible to use Unicode ranges to blacklist (or whitelist) whole ranges of characters to be stripped from (or preserved in) slugs? Is this practical or even desirable? Or would it make more sense to continue using a list of just the most common multi-byte characters to be stripped? The latter makes a whole lot more sense, but the former is a more complete solution. Thoughts?" johnbillion Needs Dev / Bug Wrangler Feedback 55962 Upgrade `sanitize_hex_color()` to CSS Color Level 4 pbearne Formatting normal normal Future Release enhancement assigned dev-feedback 2022-06-11T04:57:08Z 2024-01-17T00:09:09Z "I’ve noticed that the `sanitize_hex_color()` function unsupports the CSS Color Level 4 with the alpha channel and can therefore not be used. As users are given the ability to provide settings by configuration filters in a mini-plugin or in their theme’s `functions.php`, they may wish to configure opacity alongside. The fix is to extend the validation condition of `sanitize_hex_color()` from: `if ( preg_match( '|^#([A-Fa-f0-9]{3}){1,2}$|', $color ) )` to `if ( preg_match( '|^#([A-Fa-f0-9]{3,4}){1,2}$|', $color ) )`" anrghg Needs Dev / Bug Wrangler Feedback 56120 "WordPress should add a space character on every possible ""wrap point"" in a post title when building ""html title"", ""og:title"" and so on" Formatting normal normal Awaiting Review enhancement new dev-feedback 2022-07-01T05:13:27Z 2022-07-05T05:23:50Z "In WordPress it is possible to use html tags inside posts title. This is very nice: for example, it allows to use italics, and to make posts titles wrap where one wants. When the latter is the case, though, the titles get displayed good in the post, but not in the browser's window title (that usually the browser builds after the `Foobar` html entity), and not in the link previews that one can get by linking a post into a social network post (that usually have their title based on the `` entity). For example, a post title like `First line
second line
third line` will result in a `First linesecond linethird line` entity and in a `` entity, that will result in ugly and difficult to read browser window and link previews titles. This could be avoided by changing WordPress code so that it added a space character on every possible ""wrap point"" (`
`, `

`, `` and so on) in a post title when building ""html titles"", ""og:title""s and the likes." pezcurrel Needs Dev / Bug Wrangler Feedback 12056 "target=""_blank"" being stripped from Profile Bio and Category Description" Formatting 2.9.2 normal normal Future Release enhancement new dev-feedback 2010-01-27T16:50:00Z 2019-10-29T11:02:01Z "Many apologies if this is a duplicate. I have searched but did not find it yet posted. I noticed that target=""_blank"" is being stripped from my ""a href"" tags my profile ""Biographical Info"" field even though the ""a href"" with the URL and closing tag still remain. It happens every time I save my profile. This was independently verified. It is a regular wordpress install running 2.9.1 (not wordpressmu, etc.). My original thread can be found here: http://wordpress.org/support/topic/355388?replies=1" lovewpmu Needs Dev / Bug Wrangler Feedback 29717 wp_check_invalid_utf8 - pcre tricks and failsafes, +mb_convert_encoding, iconv fix, performance Formatting normal normal Awaiting Review enhancement new needs-unit-tests 2014-09-20T17:18:13Z 2019-05-18T07:49:17Z "Used in core in these 4 functions. * esc_attr() * esc_js() * esc_html() * sanitize_text_field() It's the first function to execute for all 4, and especially for sanitize_text_field it gets called quite a bit and is pretty important. It's purpose is to check a string for invalid utf. It utilizes preg_match with the '/u' modifier to parse both the pattern and subject for utf. PCRE automatically checks both the pattern and subject for invalid utf, upon which it will exit with an error code/constant. The changes here: Normally pcre is compiled with utf support. It can also be compiled to disallow utf support, and it can be compiled without utf support. If utf is compiled and enabled the '/u' modifier for preg_match is available which turns on the automatic utf validation. For older dists or those with utf support turned off at compile, there is a trick to enable the same functionality as the '/u' provides. http://www.pcre.org/pcre.txt In order process UTF-8 strings, you must build PCRE to include UTF-8 support in the code, and, in addition, you must call pcre_compile() with the PCRE_UTF8 option flag, or the pattern must start with the sequence (*UTF8). When either of these is the case, both the pattern and any subject strings that are matched against it are treated as UTF-8 strings instead of strings of 1-byte characters. So the first change to this function was to allow a fallback to that pattern option trick in case '/u' wasnt supported. 1. `@preg_match( '//u', '' ) !== false` 2. `@preg_match( '/(*UTF8)/', '' ) !== false` 3. Fallback to a regex that doesn't require UTF support, instead of using pcre utf validation it searches for it I also wanted it to have better performance, especially due to its use in those 4 core functions I use often. I benchmarked it pretty thoroughly to try and gain more speed. This patch is about 10-20% faster. Many gains were from refactoring the logic and control structures, chaining within if statements using bools, and utilizing the static variables to the fullest. This is especially crucial since this function gets called repeatedly. I also gained some cycles by replacing an in_array() check with a `stripos`. One of the bigger gains came from replacing the `strlen( $string ) == 0` that ran on every run with. Since the $string variable was already casted to a string, that should always work and keep things a little cheaper. {{{ $string = (string) $string; // if string length is 0 (faster than strlen) return empty if ( ! isset( $string[0] ) ) return ''; }}} The final change was to the 2nd parameters $strip, which if true is supposed to strip the invalid utf out of the string and return the valid. In core nowhere is that parameter being used (yet), which explains the deprecated looking iconv. Also added a fallback to use mb_convert_encoding in case iconv is missing. {{{ // try to use iconv if exists if ( function_exists( 'iconv' ) ) return @iconv( 'utf-8', 'utf-8//ignore', $string ); // otherwise try to use mb_convert_encoding, setting the substitue_character to none to mimic strip if ( function_exists( 'mb_convert_encoding' ) ) { @ini_set( 'mbstring.substitute_character', 'none' ); return @mb_convert_encoding( $string, 'utf-8', 'utf-8' ); } }}} Here are some of the test strings I used, I also used the utf-8-test file at http://www.cl.cam.ac.uk/~mgk25/ucs/examples/UTF-8-test.txt. I did testing on 4.0 using php 5.6, 5.4, 5.3, and 5.4. I verified the output and the strip feature as well. For all tests I had php error_reporting set to the max: {{{ ini_set( 'error_reporting', 2147483647 ); }}} {{{ $valid_utf = array( ""\xc3\xb1"", // 'Valid 2 Octet Sequence' ""\xe2\x82\xa1"", // 'Valid 3 Octet Sequence' => ""\xf0\x90\x8c\xbc"", // 'Valid 4 Octet Sequence' => ""\xf8\xa1\xa1\xa1\xa1"", //'Valid 5 Octet Sequence (but not Unicode!)' => ""\xfc\xa1\xa1\xa1\xa1\xa1"", //'Valid 6 Octet Sequence (but not Unicode!)' => ""Iñtërnâtiônàlizætiøn\xf0\x90\x8c\xbcIñtërnâtiônàlizætiøn"", // valid four octet id 'Iñtërnâtiônàlizætiøn', // valid UTF-8 string ""\xc3\xb1"", // valid two octet id ""Iñtërnâtiônàlizætiøn\xe2\x82\xa1Iñtërnâtiônàlizætiøn"", // valid three octet id ); $invalid_utf = array( ""\xc3\x28"", //'Invalid 2 Octet Sequence' => ""\xa0\xa1"", //'Invalid Sequence Identifier' => ""\xe2\x28\xa1"", //'Invalid 3 Octet Sequence (in 2nd Octet)' => ""\xe2\x82\x28"", //'Invalid 3 Octet Sequence (in 3rd Octet)' => ""\xf0\x28\x8c\xbc"", //'Invalid 4 Octet Sequence (in 2nd Octet)' => ""\xf0\x90\x28\xbc"", // 'Invalid 4 Octet Sequence (in 3rd Octet)' => ""\xf0\x28\x8c\x28"", //'Invalid 4 Octet Sequence (in 4th Octet)' => chr(0xE3) . chr(0x80) . chr(0x22), // Invalid malformed because 0x22 is not a valid second trailing byte following the leading byte 0xE3. http://www.unicode.org/reports/tr36/ chr(0xF8) . chr(0x80) . chr(0x80) . chr(0x80) . chr(0x80), // Invalid UTF-8, overlong 5 byte encoding. chr(0xD0) . chr(0x01), // High code-point without trailing characters. chr(0xC0) . chr(0x80), // Overlong encoding of code point 0 chr(0xF8) . chr(0x80) . chr(0x80) . chr(0x80) . chr(0x80), // Overlong encoding of 5 byte encoding chr(0xFC) . chr(0x80) . chr(0x80) . chr(0x80) . chr(0x80) . chr(0x80), // Overlong encoding of 6 byte encoding chr(0xD0) . chr(0x01), // High code-point without trailing characters ""Iñtërnâtiôn\xe9àlizætiøn"", // invalid UTF-8 string ""Iñtërnâtiônàlizætiøn\xfc\xa1\xa1\xa1\xa1\xa1Iñtërnâtiônàlizætiøn"", // invalid six octet sequence ""Iñtërnâtiônàlizætiøn\xf0\x28\x8c\xbcIñtërnâtiônàlizætiøn"", // invalid four octet sequence ""Iñtërnâtiônàlizætiøn \xc3\x28 Iñtërnâtiônàlizætiøn"", // invalid two octet sequence ""this is an invalid char '\xe9' here"", // invalid ASCII string ""Iñtërnâtiônàlizætiøn\xa0\xa1Iñtërnâtiônàlizætiøn"", // invalid id between two and three ""Iñtërnâtiônàlizætiøn\xf8\xa1\xa1\xa1\xa1Iñtërnâtiônàlizætiøn"", // invalid five octet sequence ""Iñtërnâtiônàlizætiøn\xe2\x82\x28Iñtërnâtiônàlizætiøn"", // invalid three octet sequence third ""Iñtërnâtiônàlizætiøn\xe2\x28\xa1Iñtërnâtiônàlizætiøn"", // invalid three octet sequence second ); }}} ---- Notes and more info: {{{ In order process UTF-8 strings, you must build PCRE to include UTF-8 support in the code, and, in addition, you must call pcre_compile() with the PCRE_UTF8 option flag, or the pattern must start with the sequence (*UTF8). When either of these is the case, both the pattern and any subject strings that are matched against it are treated as UTF-8 strings instead of strings of 1-byte characters. UTF-8 was devised in September 1992 by Ken Thompson, guided by design criteria specified by Rob Pike, with the objective of defining a UCS transformation format usable in the Plan9 operating system in a non- disruptive manner. Char. number range | UTF-8 octet sequence (hexadecimal) | (binary) --------------------+--------------------------------------------- 0000 0000-0000 007F | 0xxxxxxx 0000 0080-0000 07FF | 110xxxxx 10xxxxxx 0000 0800-0000 FFFF | 1110xxxx 10xxxxxx 10xxxxxx 0001 0000-0010 FFFF | 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx A UTF-8 string is a sequence of octets representing a sequence of UCS characters. An octet sequence is valid UTF-8 only if it matches the following syntax, which is derived from the rules for encoding UTF-8 and is expressed in the ABNF of [RFC2234]. UTF8-octets = *( UTF8-char ) UTF8-char = UTF8-1 / UTF8-2 / UTF8-3 / UTF8-4 UTF8-1 = %x00-7F UTF8-2 = %xC2-DF UTF8-tail UTF8-3 = %xE0 %xA0-BF UTF8-tail / %xE1-EC 2( UTF8-tail ) / %xED %x80-9F UTF8-tail / %xEE-EF 2( UTF8-tail ) UTF8-4 = %xF0 %x90-BF 2( UTF8-tail ) / %xF1-F3 3( UTF8-tail ) / %xF4 %x80-8F 2( UTF8-tail ) UTF8-tail = %x80-BF }}} * http://www.pcre.org/pcre.txt * http://us1.php.net/manual/en/pcre.constants.php * http://www.cl.cam.ac.uk/~mgk25/unicode.html#utf-8 * http://en.wikipedia.org/wiki/Unicode * http://unicode.org/faq/utf_bom.html * http://www.unicode.org/versions/Unicode6.1.0/ch03.pdf * http://www.pcre.org/pcre.txt * http://tools.ietf.org/rfc/rfc3629.txt * http://www.unicode.org/faq/utf_bom.html * http://www.unicode.org/versions/Unicode5.2.0/ch03.pdf * http://www.unicode.org/reports/tr36/ * http://tools.ietf.org/rfc/rfc3629.txt Related Tickets: * https://core.trac.wordpress.org/ticket/11175 * https://core.trac.wordpress.org/ticket/28786 " askapache Needs Dev / Bug Wrangler Feedback 51040 How about having a native BR to Newline method, i.e. br2nl Formatting normal normal Awaiting Review feature request new dev-feedback 2020-08-17T09:54:59Z 2023-12-14T20:35:11Z "Is there a specific reason that WordPress does not have yet (?) a function to convert Line break (`
`) to Newline (`\n`)? This is useful for `textarea` fields. One of the use cases could be a multiline address used as metadata in the user profile. In the `textarea` user enters like: {{{ Building name Street address Postal code. Country name }}} When saved we usually convert all line breaks into HTML line breaks for easier rendering in the front-end. We do this using `nl2br` method. So in the database, the above becomes: {{{ Building name
Street address
Postal code. Country name }}} However, when the above information is populated in edit mode, it comes up like {{{ Building name
Street address
Postal code. Country name. }}} A `br2nl` method will make life much easier. {{{#!php ) into newline character (\n) * * @return null|string|string[] * Since 5.5 */ function br2nl( $input_string ) { return preg_replace('//ius', ""\n"", str_replace( ""\n"", """", str_replace( ""\r"", """", htmlspecialchars_decode( $input_string ) ) ) ); } }}} " subrataemfluence Needs Dev / Bug Wrangler Feedback 57909 "It's not logical that the ""Read more""-button disappears when you create a manual excerpt" Formatting 1.5 normal normal Awaiting Review feature request new close 2023-03-12T14:05:20Z 2023-03-14T10:35:34Z "When you create a manual excerpt on a Post, the ""Read more""-button disappears on the Blog-page. That is NOT logical, if you ask me! I was told by the Astra Pro Theme support that this is a default behaviour of WordPress. To me, this is a bug, but formally I guess it's a feature request, to let the user decide whether to have a ""Read more""-button or not, and how it should look! And NOT let it depend on whether you have created a manual excerpt for that post! I will try to add a screen shot which shows that the ""Read more""-button is only visible on Post-thumbnails where I have not manually created the excerpt." hero2 Needs Dev / Bug Wrangler Feedback 39824 Gallery doesn't show images being uploaded adamsilverstein Gallery 4.0 normal normal Future Release defect (bug) assigned dev-feedback 2017-02-09T16:18:43Z 2021-02-17T07:21:08Z "When you insert a gallery with images being uploaded in Edit Post page, the gallery doesn't show the images. '''How to Reproduce''' 1. Open Edit Post page. 2. Insert a gallery with one uploaded image. 3. Select the gallery in tinyMCE then click on Edit. 4. Upload a big image file and/or slow down the internet to buy time for the following actions. 5. Choose Edit Gallery tab then click on Update Gallery button while the big image is uploading. 6. The gallery shows an empty element instead of the image. 7. If you edit the gallery and open Edit Gallery tab after the image uploaded, you'll see it has gone." gonom9 Needs Dev / Bug Wrangler Feedback 13425 Image Gallery of Private Post is publicly displayed Gallery 3.0 normal normal defect (bug) reopened dev-feedback 2010-05-17T20:12:20Z 2019-06-04T19:42:59Z "Might have been forgotten only, I just ran over this inconsistency while beta-testing: '''Description:''' The Image Gallery of a Private Post is displayed (in another post via the Shorttag with id parameter) whereas, when clicking on the images to go to the attachment page, you get a 404 not found. '''Example:''' [http://hakre.wordpress.com/2010/05/17/cui-utils-rev2/#more-1184 Post with Gallery][[BR]] [http://hakre.wordpress.com/2010/05/17/cui-utils-gnu-tools-fur-windows-32-with-a-simple-setup/gnu-win-cui-util-00-setup/ Attachment of that Gallery] '''Steps to reproduce''' Create a new Post, set a title and the Status to private. Save as Draft. Preview it, to get the ID easily from URL. Upload a Bunch of Images. Insert the Gallery Shorttag inside that Post Body. Publish the Post. Create a second new Post Give it a Title and Insert the Gallery Shortcode with the ID from the last Post. Publish. View. Copy the URL. Open another Browser so to have a new User-Session. Visit that URL. '''Expected Behaviour''' You should not see a gallery. '''Behaviour''' You see a gallery. When clicking on a gallery link you get a 404 page. '''Feedback''' I see an inconsitency here but have no Idea how to deal with it. So either the gallery should not be found as well (not found as in 404 but in this case: not output) or the attachment pages should be able to call as well. Related: #11697" hakre Needs Dev / Bug Wrangler Feedback 13429 Updating Link URL on image within Admin with Gallery Gallery 2.9.2 normal normal Future Release defect (bug) new dev-feedback 2010-05-18T01:43:42Z 2023-08-24T19:53:27Z "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 Needs Dev / Bug Wrangler Feedback 38228 Add filter to default gallery shortcode output Gallery 4.7 normal normal Awaiting Review enhancement new dev-feedback 2016-10-04T18:27:54Z 2018-04-12T14:05:03Z "Right now the only way to alter the default gallery shortcode output is to use the ""post_gallery"" shortcode which effectively requires the developer to rewrite the entire shortcode. There is a lot of redundancy in here since in most cases, we do not want to alter the retrieval of gallery items. By adding a simple filter at the end of the gallery, we can save a lot of code as well as not effect anyone currently using the post_gallery filter. See my proposed patch." tristangemus Needs Dev / Bug Wrangler Feedback 60452 @category tag is considered deprecated by phpDocumentor General normal normal Awaiting Review defect (bug) new dev-feedback 2024-02-07T01:24:38Z 2024-02-23T23:27:59Z "The @category tag is used in wp-includes/class-json.php. According to phpdoc.org it is deprecated and isn't recommended. Ref https://docs.phpdoc.org/3.0/guide/references/phpdoc/tags/category.html > This tag is considered deprecated and support may be removed in a future version of phpDocumentor. It is recommended to use the @package tag's ability to provide multiple levels instead." henry.wright Needs Dev / Bug Wrangler Feedback 47420 Block markup containing HTML in block attributes is corrupted when using wp_insert_post General normal normal Awaiting Review defect (bug) new dev-feedback 2019-05-28T17:12:15Z 2023-08-30T18:26:32Z "**Issue** Some blocks allow HTML in their block attributes, which display correctly in the editor and the front end. An example is the Pricing block in Atomic Blocks: https://wordpress.org/plugins/atomic-blocks/ If block content copied from the block editor as raw code contains HTML in its block attributes, inserting that content with wp_insert_post() results in corrupt blocks. This appears to be due to the way block attributes like this: {{{ {""price"":""49"",""currency"":""$"",""term"":""/mo""} }}} Are encoded like this when saved: {{{ {""price"":""\u003cstrong\u003e49\u003c/strong\u003e"",""currency"":""$"",""term"":""/mo""} }}} **To reproduce** 1. Install Atomic Blocks and activate Twenty Nineteen. 2. Add this code to your theme's functions.php, refresh any page to trigger the code, then remove the code: {{{#!php
Price Title
Price Subtitle Description
$
49
/mo
  • Product Feature One
  • Product Feature Two
  • Product Feature Three
CONTENT; wp_insert_post([ 'post_title' => 'Test block import with HTML in attributes', 'post_content' => $post_content ]); }}} 3. View the newly imported post. You'll see “this block contains unexpected or invalid content” where you expect to see blocks. If you repeat the above steps but use unencoded attributes as follows (find and replace '\u003c' with '<' and '\u003e' with '>'), the blocks import as expected: {{{ {""price"":""49"",""currency"":""$"",""term"":""/mo""} }}} **Environment** WordPress 5.2.1, Twenty Nineteen, no plugins active except for Atomic Blocks. macOS/Chrome. **Further info** This isn't limited to Atomic Blocks, as other blocks use HTML in block attributes. This issue was originally reported against the Gutenberg repo by another user who encountered the same, but it was suggested the issue belongs in Trac. I couldn't find a corresponding ticket here. https://github.com/WordPress/gutenberg/issues/14068" modernnerd Needs Dev / Bug Wrangler Feedback 59992 Document global $locale in wp-admin/options.php General normal normal Awaiting Review defect (bug) new dev-feedback 2023-11-30T13:42:55Z 2023-11-30T16:19:32Z "I have review the below file code and found the we are used a global locale variable. but they do not mention in function comment. So I think we need improve function comment code. File Names: wp-admin/options.php " upadalavipul Needs Dev / Bug Wrangler Feedback 60052 Error when deleting media if default taxonomies have been removed General 6.4.2 normal normal Awaiting Review defect (bug) reopened dev-feedback 2023-12-12T07:44:20Z 2024-03-07T04:39:20Z "Hello, I recently had a problem with deleting media from the media library. I received the following error message: 2151#0: *203114 FastCGI sent in stderr: ""PHP message: UM_TEST_ERROR_LOG PHP message: 63870 PHP message: ""category"" PHP message: UM_TEST_ERROR_LOG PHP message: 63870 PHP message: ""post_tag"" PHP message: PHP Fatal error: Uncaught TypeError: array_map(): Argument #2 ($array) must be of type array, WP_Error given in /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/taxonomy.php:1964 Stack trace: #0 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/taxonomy.php(1964): array_map() #1 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/post.php(6304): wp_delete_object_term_relationships() #2 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/post.php(3416): wp_delete_attachment() #3 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-admin/includes/ajax-actions.php(886): wp_delete_post() #4 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/class-wp-hook.php(324): wp_ajax_delete_post() #5 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/class-wp-hook.php(348): WP_Hook->apply_filters() #6 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-includes/plugin.php(517): WP_Hook->do_action() #7 /var/www/vhosts/fis-gmbh.de/stage.fis-gmbh.de/wp-admin/admin-ajax.php(1"" while reading response header from upstream This happened because we had used the following code elsewhere: add_action( 'init', 'deregister_tag' ); function deregister_tag() { global $wp_taxonomies; $tax = 'post_tag'; if ( taxonomy_exists( $tax ) ) { unset( $wp_taxonomies[ $tax ] ); } } This code ensures that the standard WordPress taxonomy 'post_tag' is no longer present (this was not necessary for this project). In wp-includes/post.php there is the following call: wp_delete_object_term_relationships( $post_id, array( 'category', 'post_tag' ) ); This call causes an error to occur if the taxonomy 'post_tag' is not present. I am of the opinion that this error should be caught in the WordPress core. This issue is also being discussed here at WPML: https://wpml.org/forums/topic/fatal-error-when-deleting-a-media/ Thank you." imatoni Needs Dev / Bug Wrangler Feedback 47974 Fatal error without explanation General 5.2.2 normal normal Awaiting Review defect (bug) new close 2019-09-04T16:30:54Z 2024-02-26T22:27:31Z "Hello, Today, sudenly wp-admin return this error https://prnt.sc/p1sz3t I discoverd is from digitalaccespass plugin. if i disable it, wp admin works ok. Now, the strange thing is that dap dont work even if i disable all plugins/all themes So it something related to this site. What disturbs me and is not the first time is that i dont receive an email with the error. The message says it was send an email to administrator, but i dont receive any email. I also enabled debug but no info there . How can i help you to make send emails with fatal error every time? Also, is there anything i can do to find the error? Thank you" cristianciuberea Needs Dev / Bug Wrangler Feedback 49069 Multisite: 404 template isn't used in network installs when a file extension is used in the URL General normal normal Awaiting Review defect (bug) new dev-feedback 2019-12-23T15:31:00Z 2020-04-15T09:08:50Z "The WordPress 404 template isn't used when certain URLs are visited. For example: - https://commons.gc.cuny.edu/sites/file.php - https://blogs.harvard.edu/file.php Note this seems to happen in network installs only. I can't reproduce when using a single install." henry.wright Needs Dev / Bug Wrangler Feedback 38596 Preview Change button does not reflect Custom Page Template General 4.6.1 normal normal Awaiting Review defect (bug) new dev-feedback 2016-10-31T20:08:55Z 2017-09-08T14:17:51Z "When creating 2 or more custom page templates, the Preview Change button is failing to show the correct template after making a switch. Here are steps below. - Create 2 custom page templates in code. - Go to wp-admin and go to Pages - Either use the Sample that ships with WordPress or create a new page - Within page edit mode, under Page Attributes, select a different page template. - Click Preview Change. - You will notice that the preview does not reflect the correct template. You have to push Update in order to see it. " blackawxs Needs Dev / Bug Wrangler Feedback 13779 Preview doesn’t work - WP installed in its own directory SergeyBiryukov General 2.9.2 normal normal Future Release defect (bug) reviewing dev-feedback 2010-06-08T01:32:04Z 2022-07-13T17:21:56Z "1. Wordpress is installed on /wp/ subdirectory. 2. Then it was set up to be visible from the site root according to http://codex.wordpress.org/Giving_WordPress_Its_Own_Directory 3. Site works fine 4. [BUG] Preview for posts & pages isn’t working. When I press preview it goes to url like: http://example.com/?preview=true&preview_id=235&preview_nonce=aa28f04 and says ""You do not have permission to preview drafts."". 5. If I type subdirectory name “/wp/” in that url by hands, it shows correct preview: http://example.com/wp/?preview=true&preview_id=235&preview_nonce=aa28f04 6. The situation is getting worse if i'm using permalinks. In that case - there is nothing i can do to see preview. ps: I’ve tested that on clean install. " antares19 Needs Dev / Bug Wrangler Feedback 55336 Query strings with reserved characters get wrongly redirected to encoded variant at the root level. General normal normal Awaiting Review defect (bug) new dev-feedback 2022-03-08T09:18:23Z 2022-05-01T03:59:49Z "The asterisk (""*"", ASCII 2A hex) and exclamation mark (""!"" , ASCII 21 hex) are reserved for use as having special significance within specific schemes. Source: https://www.w3.org/Addressing/URL/4_URI_Recommentations.html More here: https://developers.google.com/maps/url-encoding WordPress however, redirects to a URI encoded variant when the query string at the root level contains these reserved characters. So, https://wordpress.org/plugins/?test=123*456 doesn't redirect. While https://wordpress.org/?test=123*456 redirects to https://wordpress.org/?test=123%2A456. This is quite problematic for all WordPress sites that use for example Google Analytics 4 (GA4) cross-domain tracking. GA4 relies on a query string containing asterisks. Source: https://support.google.com/analytics/answer/10071811?hl=en " madstegge Needs Dev / Bug Wrangler Feedback 42167 Reading -> Static Page - domain/page/1111 duplicates home page General 4.8.2 normal normal Awaiting Review defect (bug) new dev-feedback 2017-10-10T13:59:18Z 2017-10-10T19:06:09Z When I set a static page for Home, every url typing after domain with /page/ opens home page with http code 200. This is for all WP versions. dqnisoma Needs Dev / Bug Wrangler Feedback 60674 Reducing WordPress archive weight General normal normal Awaiting Review defect (bug) new dev-feedback 2024-03-02T10:36:48Z 2024-03-02T20:59:49Z "I've opened an issue on Github but, it's also surely easiest to duplicate it here to follow up it. The main idea f this ticket is to find a way to reduce the WordPress archive zip file. --- Github Description --- Over the year, WordPress archives weight have increased and... I think we can't change this but we can surely do something on old feature which are no more used. I know the backward compatibility is something really important to the WP leads eyes but we can't continue (IMO)to as 43% of the web to download files always heavier. Maybe we could work with Core team to determine which functions are no more used and deprecated from years. Removing them will make WordPress liter. I think to Classic editor, We could move all the classic editor features to the Classic Editor plugin. It would make the archive liter for the most part of the new users. Features would always be available thanks to the plugin. https://github.com/WordPress/sustainability/issues/30" sebastienserre Needs Dev / Bug Wrangler Feedback 57825 Something's wrong with the way the 'admin_init' hook and/or the wp_update_post function works General 6.1.1 normal normal Awaiting Review defect (bug) new dev-feedback 2023-02-28T19:54:51Z 2023-02-28T19:54:51Z "Hi, (I'm not sure what's happening here, so I left the Component dropdown with its default value.) The issue in a nutshell: when hooked to `admin_init`, the below function's wp_update_post() call is executed even when the wrapper if-else statement evaluates to false, and it updates all `mac-submenus` post type entries' status to 'draft' regardless of the fact that the `$post_id` variable doesn't even have a value in this case. I don't know how is this even possible, but it's happening - and if another admin hook is used ( for instance `in_admin_header` ), the function works perfectly, just as expected. {{{#!php -1, 'post_type' => 'mac-submenus', // We only check published submenu posts 'post_status' => array('publish'), 'fields' => 'ids', ); $submenu_post_ids_Arr = get_posts( $spq_Arr ); // Get the custom item array of the menu associated with the 'primary_menu' location global $new_menu_Arr; // Get all menu items that are top-level and parent $parent_menu_items_Arr = mac_helper_search( $new_menu_Arr, 'has_children', true ); $top_level_menu_items_Arr = mac_helper_search( $new_menu_Arr, 'is_top_level', true ); $tlp_items_Arr = array_uintersect( $parent_menu_items_Arr, $top_level_menu_items_Arr, function( $val1, $val2 ) { return strcmp($val1['has_children'], $val2['has_children']); } ); // Check if all 'mac-submenus' entries have their respective top-level & parent menu // item in the menu associated with the 'primary_menu' location. // // If a submenu entry DOESN'T have such corresponding menu item: // - check if it has a top-level BUT NOT PARENT corresponding menu item // - if it has, change the submenu post status to 'draft' // -------------------------------------------------------------------------------------------- // 1. Get submenu posts having a corresponding top-level parent menu item. $posts_with_tlp_Arr = array(); foreach ( $submenu_post_ids_Arr as $post_id ) : $post_has_tlp = false; foreach ( $tlp_items_Arr as $menu_item ) : $mi_title = html_entity_decode( $menu_item['title'] ); $p_title = html_entity_decode( get_the_title( $post_id ) ); if ( $mi_title == $p_title ) : $post_has_tlp = true; break; endif; endforeach; if ( $post_has_tlp ) $posts_with_tlp_Arr[] = $post_id; endforeach; // 2. Get posts that don't have a corresponding top-level parent menu item, and // change their status to 'draft'; $posts_with_no_tlp_Arr = array_diff( $submenu_post_ids_Arr, $posts_with_tlp_Arr ); if ( !empty($posts_with_no_tlp_Arr) ) : foreach( $posts_with_no_tlp_Arr as $post_id ) : $update_args_Arr = array( 'ID' => $post_id, 'post_type' => 'mac-submenus', 'post_status' => 'draft', ); wp_update_post( $update_args_Arr ); endforeach; endif; } add_action( 'admin_init', 'cpt_mac_submenus_create_delete_check_menu_items' ); }}} I spent an hour with testing code variations, but couldn't find a problem with the above code or a fix of the issue." lunule Needs Dev / Bug Wrangler Feedback 56172 Strict comparisons not used. General normal normal Awaiting Review defect (bug) new dev-feedback 2022-07-08T05:04:18Z 2023-10-26T00:02:19Z "On going through the core files, I observed that in many places strict comparison is not used. After that, I ran the code through the WPCS and also got the warnings for the same. Though it does not affect the flow of the site, it should be used. Few exampals are: 1 options-general.php {{{ 215 | WARNING | Found: ==. Use strict comparisons (=== or !==). 393 | WARNING | Found: ==. Use strict comparisons (=== or !==). }}} 2 sites.php {{{ 105 | WARNING | Found: ==. Use strict comparisons (=== or !==). 145 | WARNING | Found: !=. Use strict comparisons (=== or !==). 145 | WARNING | Found: !=. Use strict comparisons (=== or !==). 157 | WARNING | Found: ==. Use strict comparisons (=== or !==). 185 | WARNING | Found: !=. Use strict comparisons (=== or !==). 185 | WARNING | Found: !=. Use strict comparisons (=== or !==). }}} " hilayt24 Needs Dev / Bug Wrangler Feedback 49664 Uppercase Greek letters are getting accents on iPhone mobile devices General normal normal Awaiting Review defect (bug) reopened dev-feedback 2020-03-18T09:41:28Z 2020-03-18T11:01:33Z "Hi, On my client's under development e-shop made with WP & WooCommerce, all of the uppercase letters appeared at various purchase steps via ""text-transform: uppercase;"" are getting accents. The shop is in Greek language and uppercase letters shouldn't have accents because this is wrong in Greek grammar. Is there maybe a way to fix this? The issue appears only at iPhone mobile devices and not at the rest. Please check my screenshots below to better understand the issue: [https://imgur.com/JxwrGaF] [https://imgur.com/4FmMiur] [https://imgur.com/rTiyiz4] [https://imgur.com/T5KVrSb] [https://imgur.com/XLisjrg] I would like to inform you that I have found a relevant plugin on wordpress.org which seems to fix the issue with the uppercase accents on Greek letters: [https://wordpress.org/plugins/remove-uppercase-accents/#description] In addition, I have found a conversation on [https://stackoverflow.com/] regarding the issue: [https://stackoverflow.com/questions/28783259/how-do-i-make-text-transformuppercase-work-properly-with-greek] I would prefer to avoid adding an extra plugin for fixing the issue. WooCommerce official support also recommended me to report the issue here as the fix should be implemented in WordPress core itself (as it affects WordPress users as well). The problem here seems to be related with the text-transform: uppercase; CSS code. As you may read above, this is a limitation with CSS code that does not remove the accents when switched to uppercase on Greek Language (I am not sure if it happens to other languages as well). Waiting for your further advice on this. Kind Regards, Dimitris" d.chatzimanolis Needs Dev / Bug Wrangler Feedback 57797 WP_Block_Type_Registry::register issues incorrect error message when block.json folder doesn't exist General 6.1.1 normal normal Awaiting Review defect (bug) new dev-feedback 2023-02-23T16:19:42Z 2023-03-07T16:18:54Z "I called {{{#!php register( $block_type, $args ); } }}} I see ->register is still called even though the call to file_exists() fails " Tonygirling Needs Dev / Bug Wrangler Feedback 28801 Walker::walk makes an incorrect assumption if $top_level_elements is empty. General 3.8 normal normal defect (bug) new needs-unit-tests 2014-07-09T16:02:56Z 2019-06-04T19:46:05Z "A colleague of mine was generating a sidebar sub-navigation for one of his projects. The subnavigation contained second-level and third-level navigation elements. The problem my colleague was having was that occasionally third-level elements would not be nested underneath their parent element (also in the list of elements) on some pages. My colleague was calling wp_list_pages with an array of page IDs that he wanted to render in the sub-navigation, wp_list_pages then turned the list of page IDs into a list of Page objects, and it sorted the page objects by their 'menu_order' attribute; the third-level navigational elements all had their 'menu_order' set to 0, whereas the second-level navigational elements all had 'menu_order' set to something more than 0 - causing the third-level elements to be the first elements in the list. wp_list_pages later made a call to Walker::walk, passing along that list of pages. Here is a relevant code snippet from Walker::walk: {{{ /* * When none of the elements is top level. * Assume the first one must be root of the sub elements. */ if ( empty($top_level_elements) ) { $first = array_slice( $elements, 0, 1 ); $root = $first[0]; $top_level_elements = array(); $children_elements = array(); foreach ( $elements as $e) { if ( $root->$parent_field == $e->$parent_field ) $top_level_elements[] = $e; else $children_elements[ $e->$parent_field ][] = $e; } } }}} '''The bug is this code's assumption that the first item in $elements is a suitable root-element for the entire list''' (sentence emboldened for anybody not wanting to read the wall of text). wp_list_pages ordered our list by 'menu_order' which put our 3rd-level elements at the top of the list - causing a 3rd-level element to be treated as the navigation's root. I wrote up a quick fix for this (I'm not sure if it's the best fix, I'm not overly experienced in Wordpress), and for our project we'll use wp_list_pages with a custom walker class that implements my fix. Here is the patch of my fix: {{{ Index: public_html/wp-includes/class-wp-walker.php IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== --- public_html/wp-includes/class-wp-walker.php (date 1404915904000) +++ public_html/wp-includes/class-wp-walker.php (revision ) @@ -217,12 +217,34 @@ /* * When none of the elements is top level. - * Assume the first one must be root of the sub elements. + * ~~Assume the first one must be root of the sub elements.~~ Disregard - RJ CGIT 2014-07-09 + * + * ---------- + * + * Modified by Rob Jackson, Castlegate IT; 2014-07-09: + * Do not assume the first element is root, instead loop through the elements + * until we find one whose parent is _not_ in the list of elements. If that fails, + * just fall back to the default behaviour of using the first element. */ if ( empty($top_level_elements) ) { + $root = false; + $element_ids = array_map(function($element){ return $element->ID; }, $elements); + foreach($elements as $element) + { + if (!in_array($element->post_parent, $element_ids)) + { + $root = $element; + break; + } + } + unset($element); + + if ($root === false) + { - $first = array_slice( $elements, 0, 1 ); - $root = $first[0]; + $first = array_slice( $elements, 0, 1 ); + $root = $first[0]; + } $top_level_elements = array(); $children_elements = array(); }}} Kind regards, Rob " rob-castlegate Needs Dev / Bug Wrangler Feedback 57262 force_ssl_admin can be set to return a string General normal normal Awaiting Review defect (bug) new dev-feedback 2022-12-02T20:57:03Z 2022-12-14T23:15:55Z "See these tests $this->assertTrue( force_ssl_admin( 'a string' ), 'set true' ); $this->assertSame( 'a string', force_ssl_admin(), 'check is still true' ); I will add a check that Bool is passed in not string" pbearne Needs Dev / Bug Wrangler Feedback 57476 hash characters at start of wp post titles are stripped upon pasting General 6.1.1 normal normal Awaiting Review defect (bug) new dev-feedback 2023-01-16T22:28:24Z 2023-02-02T13:14:54Z "There is a bug in the latest version of WP 6.1.1. When I paste a wordpress post title that has a # pound hash character as the first character, that character is stripped from the title upon pasting." robinbrinkler Needs Dev / Bug Wrangler Feedback 44595 wp_insert_post() inserts wrong GUID (adds http:// prefix) General normal normal Awaiting Review defect (bug) new dev-feedback 2018-07-17T14:07:48Z 2018-07-17T19:36:41Z "I manually set a GUID to e.g. `abc123` before calling `wp_insert_post()` and it was inserted as `http://abc123` to the database. Expected: `abc123`" Looimaster Needs Dev / Bug Wrangler Feedback 56025 wp_validate_boolean() not doing what it describes, causes issues with [video] shortcode General 6.0 normal normal Awaiting Review defect (bug) new dev-feedback 2022-06-21T08:51:00Z 2022-06-22T13:52:45Z " == The function in question: {{{ /** * Filter/validate a variable as a boolean. * * Alternative to `filter_var( $var, FILTER_VALIDATE_BOOLEAN )`. * * @since 4.0.0 * * @param mixed $var Boolean value to validate. * @return bool Whether the value is validated. */ function wp_validate_boolean( $var ) { if ( is_bool( $var ) ) { return $var; } if ( is_string( $var ) && 'false' === strtolower( $var ) ) { return false; } return (bool) $var; } }}} == Steps to recreate the issue: Add the following shortcodes to a page: {{{ [video src=""YOUR-SOURCE-HERE""] [video src=""YOUR-SOURCE-HERE"" loop=""off""] [video src=""YOUR-SOURCE-HERE"" loop=""0""] [video src=""YOUR-SOURCE-HERE"" loop=""false""] }}} - The first shortcode works as intended, rendering a video on the frontend without the loop attribute. - The second shortcode's