Page 1 of 1
[solved] Install on Lan
Posted: Tue Dec 02, 2008 12:08 pm
by _Tim_
my first post...
I have CMSMS installed on line and I thougth I would get a copy running locally to experiment before I break the on line version due to amature misbehavior.
I Loaded wampserver and got the CMSMS going just fine But! When I go to another machine on my lan and type in the addy for the CMSMS home page.
http://192.168.1.211/CMSMS/ I get the page but its not formated right. Everything is Left Justified and non of the links work. They take me to an error eg:
http://localhost/CMSMS/index.php?page=h ... works "The page cannot be found"
it seems to be looking for localhost... I am a bit puzzled. any help would be appriciated.
Thanks
Tim
Re: Install on Lan
Posted: Tue Dec 02, 2008 12:13 pm
by Dee
It looks like in your config.php every instance of
http://localhost should be replaced with
http://192.168.1.211
Regards,
D
Re: Install on Lan
Posted: Tue Dec 02, 2008 1:02 pm
by _Tim_
Thanks for the reply Dee
I found config.php here: C:\wamp\www\CMSMS
I found two instances of localhost and changed it to 192.168.1.211
here: $config['db_hostname'] = '192.168.1.211';
and here: $config['root_url'] = '
http://192.168.1.211/CMSMS';
(note: I used wordpad because in notpad it was not formated)
Result is now the local copy of cmsms behaves as it did from across the lan. ie: Everything is Left Justified and the links go to "The page cannot be found"
Do you think maybe the httpd.conf file needs some work too, or is there a problem with what I did?
thanks for your help...
Tim
Re: Install on Lan
Posted: Tue Dec 02, 2008 1:36 pm
by _Tim_
Interesting update.. I found that now the CMSMS works from across the lan but not on the local machine. again: it is formated wrong on the local machine its on, yet it seems perfect from across the lan!
I did try to edit httpd.conf and change the localhost entries to 192.168.1.211 but it seemed to make no difference. I switched those back to localhost.
this remains a mystery to me...
Tim
Re: Install on Lan
Posted: Tue Dec 02, 2008 1:51 pm
by Dee
$config['db_hostname'] can remain "localhost". (the database connection is only made to (and from) the server/local machine)
Changing $config['root_url'] should be enough, your server/local machine should be accessible as 192.168.1.211 both from the machine itself as from the LAN.
_Tim_ wrote:
it is formated wrong on the local machine its on, yet it seems perfect from across the lan!
Strange, check the source from your browser when viewing the site from your local machine.
There are one or more stylesheet included in the head, the link(s) should look something like this now:
Code: Select all
<link rel="stylesheet" type="text/css" media="screen" href="http://192.168.1.211/CMSMS/stylesheet.php?cssid=32&mediatype=screen" />
Maybe clearing the site cache (Site Admin » Global Settings » Clear Cache) will help.
Regards,
D
Re: Install on Lan
Posted: Tue Dec 02, 2008 2:06 pm
by _Tim_
Thanks Dee, the penny dropped.
I realized that the server had to 'allow from' the local machines IP (allow itself onto the cmsms)
when I added that blurb 'allow from 192.168.1.211' everything works again, local and lan.
This is great!
Thanks for your help...
Tim
PS: one small mystery is whats with the Code: slider bar in your post. Just not sure whatup with that?
Re: Install on Lan
Posted: Tue Dec 02, 2008 2:09 pm
by Dee
_Tim_ wrote:
one small mystery is whats with the Code: slider bar in your post. Just not sure whatup with that?
It's the inclusion of the CMSMS stylesheet in the page source. I suggested to look at the page source from the browser to check if the URL's to stylesheet.php in the head section of the page were correct. (href starting with
http://192.168.1.211/CMSMS/stylesheet.php - no longer needed now it should be fine).
Regards,
D
Re: [solved] Install on Lan
Posted: Tue Dec 02, 2008 3:21 pm
by _Tim_
If your trying to get cmsms running on your local lan on windows XP try this:
1. Get yourself a windows apache mysql php bundle. Look for WAMP and get whatever one has the most active web boards at the moment. Install.
2. Find the httpd.conf file and edit the section about half way down the file, edit in the IP's for your Lan. You should be using static IP's, check the properties of your lan cards.
Order Deny,Allow
Deny from all
Allow from 192.168.1.126
Make sure you include the IP of the machine you are on.
3. Create your database, I used phpMyAdmin for the job.
4. Place your new download of CMSMS into a folder in the www directory. You should be able to get to the install page from your browser at
http://localhost/CMSMS/ I had to make a new .txt file and rename it to config.php and place it in the CMSMS folder.
5. Once your install is finished find that config.php file you made before and edit it. Near the top in Path Settings look for and edit:
$config['root_url'] = '
http://localhost/CMSMS'; add your host machine's IP like so:
$config['root_url'] = '
http://192.168.1.211/CMSMS'; <<<This is the address you will use from other computers in the Lan to get to your cmsms.
Save and restart the server.
Hope this helps. If it doesn't work you may have firewall or sharing issues. You don't have to open ports in your router unless you want to access your computer from the internet.
