So, this is very new to me – I do not have a lot of coding experience! I have developed a WordPress site but want the ability to work on it offline as I make changes and try new things.
I have installed MAMP (Version 3.5) and copied my files over to the root directory via FTP. To test the transfer was successful, I tried to navigate to:
http://localhost:8888/PAS_wordpress (the folder name)
In response, Firefox (which is the most up-to-date version) responds with a dialogue box:
You have chosen to open:
{BLANK}
which is: application/x-httpd-php (418 bytes)
from http://localhost:8888What should firefox do with this file?
If I open the file I understand that it is php script (shown below), but I dont know why it isn’t being processed. I have spent some time now trying to find answers. Some other people seem to have had similar problems, but not quite the same, or the solutions provided just dont work.
<?php
/**
* Front to the WordPress application. This file doesn't do anything, but loads
* wp-blog-header.php which does and tells WordPress to load the theme.
*
* @package WordPress
*/
/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);
/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );
Can anyone help please? I am determined to get this to work!
Many Thanks in advance…
In the local database, import an SQL dump file and then go into the WP_options table and you will see the first two rows will be a URL
http://example.com
Change these to
http://localhost