Links not working on migrated site I moved a site from a hosted server to my local machine and none of the links that point to internal pages work even though they look correct. I'm getting odd behaviour as described below. This is true even for the admin toolbar provided by the module (People, Modules, Configuration, etc.)

My process was as usual, I copied all the files down, exported/dumped the database, created a local db and then imported the dump.

(I'm putting in lh instead of localhost bec stackexchange won't allow links with localhost)
I was able to login via lh/myidols5/?q=user but not lh/myidols5/user which gives 'access denied'. From lh/myidols5/?q=user, if I click on any link say the home button in the admin toolbar I go to the right page but am logged out. The address bar says lh/myidols5/ which is correct so I'm at a loss as to why I'm logged out.

Anyone know what the issue is?

Thanks
I feel you're missing .htaccess file. Usually its a hidden file, so make sure to show all files (including hidden files) and copy it and paste it into your local drupal folder.

Also, make sure you local server has mod_rewrite enabled to support clean URLs, if its not enabled then check this answer: How to enable mod_rewrite in Apache?.

Another suggestion is; to turn off Clean URL from settings.php by adding the following code:

$conf['clean_url'] = 0;