Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Wordpress site links not working for any page after moving it from one server to another.

Posted on 2011-09-12
14
580 Views
Last Modified: 2012-06-27
Hello Experts,

I have been given mysql backup and a wordpress site from another place to host somewhere else. I am new to wordpress, I am trying to host it on a local win 2003 machine, IIS 6.0 to check if everything works fine before we can move it to a hosting provider.
After fighting with PHP and mysql installation and making them work. I finally was able to import the database in sql and put the files given to me in a directory on IIS to be hosted. I changed the wp-config.php to include new username and password for Mysql database. the site also has Theme test drive plugin so that nobody can view the site without logging into wp-admin.php.
Now problem is that i can login into the dashboard of the wordpress (wp-admin.php). then i can view the main page of the site but none of the links are working. I can login into the dashboard and then i can see the pages there i can click to edit them but when i press view from dashboard, IE 404 error , page cannot be found shows up. I cant figure out what would be the reason for this and is driving me crazy. Please help me with this as i need to sort this ut asap.
Many thanks.
0
Comment
Question by:Rafi001
  • 5
  • 5
14 Comments
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 36523885
Assuming you have the same domain name as before, you should disable your permalinks (set to default), save, then recreate them.

If you changed the domain name or path, you probably need to download the WordPress Find and Replace plugin (http://wordpress.org/extend/plugins/search-and-replace/) and use it to change the URLs in your database.
0
 

Author Comment

by:Rafi001
ID: 36524471
Jason118, thanks for your response. The domain name is same. The permalinks were set as custom: /%postname%, which i didnt change.
which path you are talking about and how can i check if that has been changed?

thanks Rafi
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 36524502
So do as I suggest above.  Set permalinks back to default and then regenerate the custom ones.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 4

Expert Comment

by:vaibhavjaiman
ID: 36527634
It can also arises if you are using any URL rewrite ,which is not present in new server.
0
 

Author Comment

by:Rafi001
ID: 36528272
Jason118,  i hve tried changing the permalinks to default and then back to custom /%postname%, mas it was but this doesnt work. Not sure this is what you meant? any suggestions
vaibhavjaiman, How can i check the URL rewrite and how can i install this in new server, it is running on IIS 6.0?

Thanks
Rafi
0
 

Author Comment

by:Rafi001
ID: 36529839
I have found out that when i changed the permalinks to default then it is working on view within dashboard of the site. However, on the main page the links are still the same. see examples below,

After changing the permalinks to default, the link to about us page is http://mydomain.com/?page_id=2 
which is working fine.

However, on the main page the link to about us is still http://mydomain.com/about, which is not working. This link was showing up for about us page from within the dashboard before changing the permalinks.

Please note that there is custom made theme being used on this website.
Can this help experts narrowiing down the problem. Please comment..

Regards,
Rafi
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 36530479
Okay, if it works with default links then you need to enable URL Rewrites on IIS

http://learn.iis.net/page.aspx/466/enabling-pretty-permalinks-in-wordpress/
0
 

Author Comment

by:Rafi001
ID: 36539147
Hi Jason1178, This is for IIS7. Do you know any resource for URL Rewrites for IIS6 Please.

Thanks
0
 
LVL 70

Accepted Solution

by:
Jason C. Levine earned 500 total points
ID: 36539176
http://codex.wordpress.org/Using_Permalinks#Permalinks_without_mod_rewrite

You might have to update all links to use /index.php/%permalinkcodes%/ structure on IIS 6

0
 

Author Comment

by:Rafi001
ID: 37054191
I've requested that this question be deleted for the following reason:

This is irelevant for me as i have not doing this job anymore.<br /><br />Thanks for all comments
0
 
LVL 70

Expert Comment

by:Jason C. Levine
ID: 37054192
While it may not be personally relevant, the instructions to enable rewrites on IIS are accurate and points should be awarded
0

Featured Post

PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

So you have coded your own WordPress plugin and now you want to allow users to upload images to a folder in the plugin folder rather than the default media location? Follow along and this article will show you how to do just that!
A phishing scam that claims a recipient’s credit card details have been “suspended” is the latest trend in spoof emails.
The purpose of this video is to demonstrate how to automatically show related posts at the bottom of a blog post in WordPress. This will be demonstrated using a Windows 8 PC. Plugin “Yet Another Related Posts Plugin” will be used. Go to your…
The purpose of this video is to demonstrate how to make a WordPress Site faster and smaller in size by cleaning up the database. This will be demonstrated using a Windows 8 PC. Plugin WP Optimize will be used. Go to your WordPress login page. T…

856 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question