Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

I have just copied a WordPress site to a different domain, everything on the front-end and admin side displays and works smoothly except I found my category links are linking to the old site domain. ( when echoed from get_category_link($parent->cat_ID) )

The siteurl and home fields in the database are correct (http://subdomain.newdomain.com)

However when I echo any of home_url() site_url() or network_site_url() I get http://www.oldsite.com

I've tried setting it in both the functions.php file and wp-config.php files, and have checked and re-checked the database field, even switching it away, breaking the site, switching it back to have the same results.

What is going on?

share|improve this question
add comment

1 Answer

Looks like the previous developer had defined the site and home URLs in the main wp index.php file.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.