[wp-trac] [WordPress Trac] #46037: Fix URL creating in class-wp-list-table in wp-admin
WordPress Trac
noreply at wordpress.org
Fri Jan 18 14:42:35 UTC 2019
#46037: Fix URL creating in class-wp-list-table in wp-admin
--------------------------+-----------------------------
Reporter: tinodjwp | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version: 5.0.3
Severity: normal | Keywords: needs-patch
Focuses: |
--------------------------+-----------------------------
At line 1009 and 1010 in wp-admin/includes/class-wp-list-table.php URL is
created in the following way:
{{{#!php
<?php
$current_url = set_url_scheme( 'http://' .
$_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'] );
$current_url = remove_query_arg( 'paged', $current_url);
}}}
This makes troubles in some scenarios. Recommended way is to replace these
two lines, by one line :
{{{#!php
<?php
$current_url = site_url(remove_query_arg( 'paged'));
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/46037>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list