I had a properly functioning Wordpress site on a local XAMPP server which I wanted to transfer to a live server, so I went to check the instructions on wordpress.org on how to perform that. I made backups of my local wordpress folder and SQL database, went to Settings - General in the Wordpress dashboard (on the local XAMPP server) to change the WordPress address and the site address to suit the address of the live server (rendering my local Wordpress site inaccessible, as expected), made an export of my SQL database and uploaded the wordpress folder and imported the newly exported SQL file to the live server. There were issues because Wordpress didn't start working on the live server. After that I attempted to get the local Wordpress site to work again (which was still unusable because of the mismatching URL settings intended for the live server), so I manually changed the address settings by adding these to the functions.php file:
as per instructed on wordpress.org on the subject of changing site URLs. After that I could see my Wordpress site's front-page (URL: localhost/wordpress, which is where all the Wordpress files are also located) and access dashboard, but trying to navigate to anywhere else on the site, e.g. opening another page than the front-page, redirects me to localhost/dashboard, which is the welcome page of XAMPP. Also, before the issues I used to access the dashboard via localhost/wordpress/admin, but this also gets redirected to localhost/dashboard. However, localhost/wordpress/wp-admin does work. Any clues why the redirection might be happening? Thanks for any help.