Installing WordPress on 8-Coral: Difference between revisions

→‎Moving Servers: Updated to reflect more complex nature of DB change.
(Updated database changes.)
(→‎Moving Servers: Updated to reflect more complex nature of DB change.)
Line 70: Line 70:
== Moving Servers ==
== Moving Servers ==
One of The Uniform Server’s unique features is the capability to easily run more than one complete  
One of The Uniform Server’s unique features is the capability to easily run more than one complete  
server system on the same PC. When running a server from a USB memory stick, you can use this advantage to  
server system on the same PC. When running a server from a USB memory stick, you can use this advantage to prevent server collisions.  
prevent server collisions.  
 
You will have noticed that Unicontroller's icon displays a one (meaning standard ports).  
You will have noticed that Unicontroller's icon displays a one (meaning standard ports).  
Moving The Uniform Server increments this digit for each server move. In reality it’s not  
Moving The Uniform Server increments this digit for each server move. In reality it’s not  
Line 79: Line 79:
This works just fine for the servers, but WordPress is unaware of the change and will fail to run properly. Note that the port numbers you use must match the ones for this particular server stack.  For the examples below, the servers have been moved to ports 83 (Apache) and 3309 (MySQL).  
This works just fine for the servers, but WordPress is unaware of the change and will fail to run properly. Note that the port numbers you use must match the ones for this particular server stack.  For the examples below, the servers have been moved to ports 83 (Apache) and 3309 (MySQL).  


You must make two different changes.
The '''''best''''' option is to install WordPress '''after''' moving The Uniform Server.
 
If you installed WordPress and then moved the servers, the following changes will get you operational again.  If the WordPress content is extensive, meaning you have many posts or changes, we suggest that you export the data and edit the file with a text editor to do the changes of step 2.  Then reload the database from the edited file.


1. Edit the wp-config.php file and change the DB_HOST entry to have the following:
1. Edit the wp-config.php file and change the DB_HOST entry to have the following:
<pre>
&lt;pre&gt;
define('DB_HOST', ';localhost:3309');
define('DB_HOST', ';localhost:3309');
  or
  or
define('DB_HOST', '127.0.0.1:3309');
define('DB_HOST', '127.0.0.1:3309');
</pre>
&lt;/pre&gt;
2. Using phpMyAdmin, update the siteurl, home, theme_mods_twentyeleven and dashboard_widget_options entries in the wp_options table and the guids in the wp_posts table as follows.
2. This is the tricky part. Using phpMyAdmin, update the siteurl, home, theme_mods_twentyeleven and dashboard_widget_options entries in the wp_options table and the guids in the wp_posts table as follows.
#Select the WordPress database for this installation.
#Select the WordPress database for this installation.
#Select the '''wp_options''' table for browse.
#Select the '''wp_options''' table for browse.
#Edit the entry for '''siteurl''' (ID=1) and change "localhost" to "localhost:83"
#Edit the entry for '''siteurl''' and change &quot;localhost&quot; to &quot;localhost:83&quot;
#Edit the entry for '''home''' (ID=37) and change "localhost" to "localhost:83"
#Edit the entry for '''home''' and change &quot;localhost&quot; to &quot;localhost:83&quot;
#Edit the entry for '''dashboard_widget_options''' (ID=119) and change "localhost" to "localhost:83" in ''three places''.
#Edit the entry for '''dashboard_widget_options''' and change &quot;localhost&quot; to &quot;localhost:83&quot; in ''three places''.
#Edit the entry for '''theme_mods_twentyeleven''' (ID=234) and change "localhost" to "localhost:83"
#Edit the entry for '''theme_mods_twentyeleven''' and change &quot;localhost&quot; to &quot;localhost:83&quot;
#Select the '''wp_posts''' table for browse.
#Select the '''wp_posts''' table for browse.
#For each post entry, edit the '''guid''' and change "localhost" to "localhost:83"
#For each post entry, edit the '''guid''' and change &quot;localhost&quot; to &quot;localhost:83&quot;


Your WordPress should now work properly.  However, if you have many posts, we suggest that you export the data and edit the file with a text editor to do the bulk changes needed.  Then reload  the database from the edited file.
Your WordPress should now work properly.


== Security ==
== Security ==