I have found out of a way on how to make the forum for Association of Keyboard Ninjas to work without someone having to act as a server. Were going to make use of Dropbox, an application used for syncing the files on multiple computers.
You have to make a few changes on the default wampserver installation so that it would be compatible with my configuration.
First, you need to launch wampserver. Left click on its icon on the system tray and select the php>php settings. And ensure that ‘allow url include’ is checked. If its not checked then check it. Then restart wampserver.
The second thing that you need to do requires you to have a knowledge on how to set environment variables. If you don’t know how then better check out the tutorial before proceeding. And set the mysql path to the environment variables. In my case the mysql folder is located at:
Yours might be different. So add the path which is applicable to you in the environment variables.
If you have 2 or more versions of mysql installed on your computer then select the mysql folder which you are currently using.
To determine what mysql version you are running then follow this screenshot:
Whatever is checked then it’s the one who is running.
So what I did was to open up the 5.1.36 folder.
After ou need to change the mysql database password. To do that just execute cmd from the start menu. Then type in:
mysqladmin –u root –p password 1234
This will change the blank password into 1234. If you currently have a password then change it to 1234 as well so that we’ll have the same configuration.
mysqladmin –u root –pMyCurrentPassword password 1234
Note that there are no spaces between the –p and your current password.
Last thing, make sure that we both have the same versions of php, mysql, and apache installed:
- php- 5.3.0
- mysql –5.1.36
If you don’t know how to install different versions of php, mysql and apache then read this tutorial.
Change preferences and set your dropbox folder to be a folder in your www directory.
Click on Advanced Tab
Click on Change and select your www directory.
You can now see the dropbox folder inside the www directory
When you open up your browser and access:
You can now see my preliminary output. The login doesn’t work yet since I’m still working on my school project.
Windows Task Scheduler
Last thing that you have to do is to configure windows to have the latest database.
If you don’t know how to backup mysql database using mysqldump then check this tutorial out.
What you need to do now is to create a new folder inside the dropbox folder and name it ‘database’. That is where the latest database will reside.
All we have to do now is to restore the database for our forum from that backup file.(If something is not clear to you, just read the story at the bottom of this post).
Use what you have learned from this tutorial. And just create a batch file for database restore. Put this on your batch file:
mysqldump -u root -p aoknforum < C:wampwwwDropboxdatabaseaoknforum.sql
Then just select that batch file from the windows task scheduler to run on system startup or every logon.
Here’s the whole story
Dropbox would be use to sync the folder where our forum resides. When I say sync. Every update that is made on the forum. For example, when a post is made or a photo is uploaded. The file on each of our computers will be updated as long as were connected to the internet. But the good thing is that you can still post on the forum while not connected to the internet. And everybody would still see it once you already have a connection.