0

I have noted that this question has been asked before, but none of the solutions offered have fixed my problem.

I have MAMP PRO. I sat down to work and when I typed my localhost URL into chrome, it just downloads the file rather than opens it in the browser. Others have suggested this is caching problem, but I have cleared the chrome cache. I have stopped and restarted apache and MySQL with no effect.

In addition to this (and possibly related), my databases have reverted to a version from a week ago.

Any advice on this problem, bearing in mind that clearing the cache had no effect, would be helpful...

EDIT:

So after playing around....a test.php file runs fine from 127.0.0.1/test.php but if I run.......127.0.0.1/breathe/index.php (which is my site) no joy, it just downloads it. If I shift all my directory straight into htdocs it works....

This is not ideal....but will do for now. But I want to know why this is happening. I need to understand this...so I can deal with further issues.

GhostRider
  • 2,109
  • 7
  • 35
  • 53
  • What do other browsers do when pointed to localhost? – Jake Lee Sep 22 '14 at 16:02
  • When I try Firefox it says 'unable to connect'.....weird because everything was working fine this morning. Safari also can't connect.....don't have Opera or parallel IE browser set up. – GhostRider Sep 22 '14 at 16:04
  • Opera? IE? Safari? The fact that it hasn't worked on either browser indicates Chrome isn't at fault, and something in the server config is. – Jake Lee Sep 22 '14 at 16:05
  • look at the last comment on the accepted answer, seems to be having the same issue as you: http://stackoverflow.com/questions/2316610/php-files-are-downloaded-by-browser-instead-of-processed-by-local-dev-server-ma?rq=1 Did you already try this? – LostBalloon Sep 22 '14 at 16:09
  • I tried this with no change. I am now removing MAMP from my system and redownloading it. My problem is that I lack the knowledge to 'understand' the issues here so its difficult to diagnose....I'm an amateur. – GhostRider Sep 22 '14 at 16:16

0 Answers0