head	1.4;
access;
symbols;
locks; strict;
comment	@# @;


1.4
date	2000.08.28.02.28.23;	author chuck;	state dead;
branches;
next	1.3;

1.3
date	2000.01.17.22.11.06;	author chuck;	state Exp;
branches;
next	1.2;

1.2
date	2000.01.06.05.01.08;	author chuck;	state Exp;
branches;
next	1.1;

1.1
date	99.07.20.07.36.28;	author jon;	state Exp;
branches;
next	;


desc
@@


1.4
log
@starting to modernize babel - nothing autogenerated, standard
directory/library names, etc.
@
text
@function read_conf_file ($filename) {
  global $conf;
  
  if (!$filename)
    return error("filename undefined"); 
  
  if (!file_exists($filename))
    return error("could not open file '$filename' for reading");
  
  include $filename;
  
  return success();
}
@


1.3
log
@Another whomping commit that really doesn't do much tangible. The conf
system is now moved over to the $conf[section][value|subsection] mode that
the other cvs horde stuff is using.

Also, I'm compacting and tightening up the code wherever possible when I go.
Lots of major changes - moving the configuration of forums into the
database, changes in the database code for faster sql access, options to put
different forums in different tables/databases, and some nifty setup ideas -
to come.

Comments on what people would like to see in a forum system - I've already
thought of being able to attach files (where should they be stored?) - would
be welcome.
@
text
@@


1.2
log
@The Great ereg->preg change hits the cvs branch. I got a few things in
Babel, the DuctTape stuff, etc as well as horde and imp. Changelogs updated
as well. If you find any errors that seem to be related, let me know, but it
was actually pretty straightforward.
@
text
@d1 3
a3 1
function read_conf_file ($filename, &$hash_ref) {
d7 1
a7 1
  if (!($file = file($filename)))
d10 1
a10 15
  while (list($junk, $line) = each($file)) {
    $key = ''; $val = '';
    if (!($line[0] == '#')) {
      preg_match("/([-\\w_.]+):\\s*(.*)\\s*/", $line, $regs);
      if (isset($regs[1]) && $regs[1] && isset($regs[2]) && $regs[2]) {
	$key = chop($regs[1]);
	$val = chop($regs[2]);
	reset($hash_ref);
	while (list($hkey, $hval) = each($hash_ref)) {
	  $val = str_replace("\$$hkey", $hval, $val);
	}
	$hash_ref[$key] = $val;
      }
    }
  }
@


1.1
log
@
jon: alrighty, babel.php3.in is now broken down into seperate
     function files.  they're jusy dying to be combined into
     objects and seperate source files.
@
text
@d11 1
a11 1
      ereg("([-[:alpha:]_.]+):[[:space:]]*(.*)[[:space:]]*", $line, $regs);
@

