Welcome to Geeklog, Anonymous Wednesday, November 27 2024 @ 05:47 am EST

Geeklog Forums

How to configure config.php the right way


Status: offline

thedude

Forum User
Regular Poster
Registered: 12/28/02
Posts: 90
I noticed that there's a lot of questions in regard to what's the right way to configure the config.php. Some of the information that's included in the config.php file seems to be confusing. So, is there someone out there who would volunteer to post the correct config.php, tag it somehow so that people know what's being changed and why it's being changed. Of course some of security info needs to be removed and I can understand that. Or FAQ or gotcha that you the expert can share with some of us the Beginer who really would like to have their geeklog server up but having serious problem making it work. Any volunteer? Thanks...
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
It's impossible to do that since there is no one "right" way to set up a config.php - otherwise we would ship the config.php that way, don't you think? It all depends on how your server is set up, where and how the paths are set up, etc. If you're lucky, you only need to set up the database information (database name, database user, password) and the $_CONF['path'] and $_CONF['site_url'] settings (plus the path to config.php in lib-common.php) and everything else would just fall into place. A fair amount of confusion comes into play when people have to change $_CONF['path_html'] as well, i.e. when your web root (document root) is not called "public_html". The default setting for this is $_CONF['path_html'] = $_CONF['path'] . 'public_html/'; Which translates to "Take the path from $_CONF['path'] and append public_html to it". So if your web root is called, for example "htdocs", you would just need to replace "public_html" with "htdocs". However, if your web root is somewhere else entirely, most people fail to take out the "$_CONF['path']" bit or even try to replace the 'path' within "$_CONF['path']" with the actual path, not realizing that "$_CONF['path']" is just the name of a variable ... Instead, the correct syntax would be something like $_CONF['path_html'] = '/var/users/someone/www/'; What else? Some hosts have a pre-configured directory called "admin" where you can configure your domain (e.g. set up email accounts etc.). This, of course, then collides with Geeklog's "admin" directory, so you have to rename the Geeklog admin directory to something like "myadmin" and set $_CONF['site_admin_url'] accordingly, e.g. $_CONF['site_admin_url'] = $_CONF['site_url'] . '/myadmin'; But that's about it. In 99% of all cases, this is all you need to do in config.php to get your site up and running. The rest are just configuration options ... Hope that helps. bye, Dirk
 Quote

Anonymous

Anonymous
Thanks Dirk.. This is great... Now it's just a matter of spending sometime making sure that the mistake that's commonly happen won't happen again... Cheers... The Dude
 Quote

All times are EST. The time is now 05:47 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content