The links you are using are generated by the class WP_List_Table
And it has nothing to do with the database. However, before we try any repair, it is good to clean the link in the database and restart the permalinks (just to be sure):
- Dump the database, open in a text editor and replace all references to the old address. Then reload the database.
- Changes the permalink structure to default.
- In the settings check if the site_url and home_url are right and saved again.
- Back the permalink structure pro that you used.
This certainly didn’t solve your problem in wp-admin, but at least now in BD and . htaccess is all right.
Your problem is in a server variable. O WP_List_Table
uses the variable $_SERVER['HTTP_HOST']
to get the address you were at. This error usually happens to servers that are behind a poorly configured proxy or firewall. To solve you can:
- Reconfiguring the server
- Fix by wp-config.php
Since we don’t always have control over the (bad) server configuration, let’s put a patch on wp-config.php
, before the line require_once(ABSPATH . 'wp-settings.php');
if ( ! empty( $_SERVER['HTTP_X_FORWARDED_HOST'] ) ) {
$_SERVER['HTTP_HOST'] = $_SERVER['HTTP_X_FORWARDED_HOST'];
}
This should solve the problem. If you encounter any more errors, you can try a more complete solution such as at this link
Caio does not hear folder changes, only the change of the Site URL, I have disabled and activated the permanent links but continues with the error
– Robison Luiz Fernandes
you tried to change the folders? I believe the problem is there
– Caio Felipe Pereira
The site is in the Root /var/www/html/ I didn’t change the folder The WP installation was on web.dominio.com.br, to run in parallel with the old site that was on another server. Next I made a change from web.dominio.com.br to www.dominio.com.br, the links are working only the pagination in the Admin that is calling the web.dominio.com.br
– Robison Luiz Fernandes