diff options
| author | Nathan Kinkade <nath@nkinka.de> | 2008-03-23 02:50:00 +0000 |
|---|---|---|
| committer | Nathan Kinkade <nath@nkinka.de> | 2008-03-23 02:50:00 +0000 |
| commit | 19412e5b812d9cb791ab97d41f4bac2d28b456b1 (patch) | |
| tree | 9565e7337404fd88fadce3fd57cd6f801e3b6352 /db_update_scripts/config.php | |
| parent | f68e230521138a8ba491c51a893312e411f57fb7 (diff) | |
Added scripts for updating database with USDA Standard Reference update files
Diffstat (limited to 'db_update_scripts/config.php')
| -rwxr-xr-x | db_update_scripts/config.php | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/db_update_scripts/config.php b/db_update_scripts/config.php new file mode 100755 index 0000000..da259ce --- /dev/null +++ b/db_update_scripts/config.php @@ -0,0 +1,37 @@ +<?php + +/** + * Copyright (c) 2007 Nathan Kinkade + * + * This code is offered under an MIT (X11) license. For more information + * about the terms of this license see the file LICENSE included with this + * software or visit: http://www.opensource.org/licenses/mit-license.php + */ + +# Directory where USDA update files are located +$updatesDir = "./sr20_updates"; + +# Where to log errors and stats +$fh_log = fopen("./sr20_updates.log", "a"); + +# Fields are delimited with this character +$delimiter = "^"; + +# Fields are optionally enclosed between this character +$enclosure = "~"; + +# site constants that don't need to be interpolated in strings and/or +# are more sensitive will be setup as constants +define("DBHOST", "localhost"); # database host +define("DBNAME", "nutridb_sr20"); # database name +define("DBUSER", "root"); # database user +define("DBPASS", ""); # database password + +define("ADODBDIR", "../lib/adodb"); # adodb db abastractions libs - adodb.sourceforge.net + +require("../lib/database.class.php"); # database class + +# instantiate the database object +$db = new Database(); + +?> |
