Domain transfer leads to broken links

I just spent the past two hours talking to my website host, trying to figure out why after transferring the domain and running the necessary software to change over all of the links from the temporary domain to the new one, half of my links don’t work.

I don’t understand this stuff enough to explain it, so I’ll just attach a screenshot of what their support sent me. I’m incredibly frustrated right now as I have a live website full of broken links, and according to my host, it’s a result of my theme.

I’m not sure who’s at fault here, but I need this resolved as soon as possible.

This is one of the pages, just as an example: http://theseforeignroads.com/central-america/

Hi There,

Thanks for writing in!

I checked the pages and I can confirm the issue in my side. Just to clarify there is no had coded URL in the theme.
The URL are in the database. You need to properly search and replace the URL through PHPMyadmin or any plugin.
Its clear that the migration is not properly done. We are not saying there is some server issue, this is clearly a migration problem from old domain to new one.

You can use this plugin https://wordpress.org/plugins/search-and-replace/ to search and replace the URL in your site.

Hope this helps.

Thanks

Thanks for the quick response.

A Search and Replace was done on the website, that’s why I was directed to the developer of the theme. Most of the links did change from using the Search and Replace function, unfortunately some of them refuse to change. That’s the problem.

Hi there,

Please also try searching for:

http:\/\/37.60.244.156/~thesefor/
http:\/\/37.60.244.156\/~thesefor\/

And replace it with the new domain.

Hope this helps.

I apologize for all the questions…

It was my host that ran the Search and Replace, not me. How exactly do I do what you’re suggesting? Simply put those in the “search” bar and “http://www.mydomain.com” in the replace bar? I just don’t want this to make things worse than they are…

Thanks again

I just ran it again myself and tried these suggestions. Still no fix. It didn’t find anything that needed to be changed.

However, there are still well over 100 links that are still the old address. There has to be a way to fix this, I’m not about to go through my website and manually re-code over 100 links.

What would cause these plugins to not recognize simple links? Isn’t that the entire point of the plugin?

Hey there,

Would you mind providing us with login credentials so we can take a closer look? Please provide following information:

Set it as Secure Note

  • Link to your site
  • WordPress Admin username / password
    All the best!

I set the note.

A lot of the links have been changed since my last post. I’ve been manually changing them all morning. Not the most convenient way to fix the problem.

Hello There,

I have inspected your site pages and there is indeed some left overs. The easiest way you can do this is to do a search and replace process. I would really love to help and be able to resolve this. Regretfully I cannot because the given credentials is not working for us. It seems that the password is invalid. Please double check it again so that we can logged and resolve this issue as soon as possible.

Please let us know how it goes.

I updated the note.

I used several Search and Replace plugins, and none of them fixed the issue. I’ve changed most of the links manually, but there are a few that are still remaining. I’m just curious at this point at why they didn’t change. Today was an incredibly frustrating day for me, so I’d like to avoid this in the future.

Hi there,

I am not sure what you searched for from the suggestion here but I tried it and I am getting 311 results that needs to be updated for http:\/\/37.60.244.156\/~thesefor\/

Also, there are 20 links that need to be update for http://37.60.244.156/~thesefor/.

Please note that you will have to select all of the tables so that the search text will be search in the entire database.

Kindly try to follow these suggestions correctly as we are not allowed to make direct changes to the client sites.

Hope this helps.

Thank you! It worked this time. My mistake was only selecting “wp_links” from the tables list because I don’t know anything about this stuff and didn’t want to mess anything up.

Now just out of curiosity, what’s the deal with the forward and back slashes? I don’t quite understand why that made a difference?

Hi there,

When URLs are added as serialized data or any other means, the scripts usually add backslashes to special characters to prevent issues. Example, in regex, ////, this is wrong if you wish to select the middle // as content, it should be like this /\/\// since the first and last / are the wrapper, and the middle // is the content. And you need to tell the code which is the content by escaping it (adding backslash). There are many uses, but it’s the simplest that I can think of :slight_smile:

Thanks!

As confusing as that is, I think I understand what you mean…

Thanks for the help!

You’re welcome, @kerridawn.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.