adsense

How to Move the WordPress Index.php From a Subdirectory





1. Open your File Transfer Protocol program and connect to the server that hosts your website by typing your username, password and server address. You can contact your host if you do not know this information. Alternatively, you can log into your browser-based file manager to access your files.
2. Navigate to the folder that contains your WordPress installation and the 'index.php.' Right click and select the option to download the file to your computer (via FTP). Make note of the file's location.

3. Open the file in a code editor, such as Notepad and locate the following line of code:require('./wp-blog-header.php');Change the location of the WP blog header to indicate which directory contains the file. For example, if your installation is in a 'wordpress' folder, this line would become:require('./wordpress/wp-blog-header.php');
4. Save your index file and upload it to the new location, outside of the directory. For example, you may upload it to the root of your website instead of the 'wordpress' folder. You can double click it from the 'Local' pane in your FTP program or click and drag it from an open folder on your computer into the server pane of your FTP client.
5. Log into your WordPress dashboard in your Web browser and click 'General' from the settings section in the navigation to open your settings. Change the 'WordPress address (URL)' entry to the location of your WordPress installation. For instance, it may be 'http://yourwebsite.com/wordpress' where 'http://yourwebsite.com' is your actual website address. Change the 'Site Address' to the location of your index file/website. This is now your website's address. Click 'Save Changes' on the bottom of the page.

Comments

0 Responses to "How to Move the WordPress Index.php From a Subdirectory"

Post a Comment

Popular Posts

About