Location: PHPKode > projects > Katyshop > katyshop_ro_0.3.2.1/config/config.php
<?php

/**
 * Product: Katyshop
 * @version 0.3.2.1
 * @author Catalin Hulea - hide@address.com
 * @copyright Copyright (C) 2007 Catalin Hulea
 * @license GNU General Public License version 3
 * 			You can find a copy of GNU GPL v3 at this path: /docs/LICENSE
 * @link https://sourceforge.net/projects/katyshop
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <http://www.gnu.org/licenses/>.
 *
 */

// this file has no global variables because it is required()
// in Application::loadConfig()
// That means all variables in this file have local scope,
// restricted to Application::loadConfig()
if(empty($this) || !is_a($this, "Application"))
	die("config file may only be included from Application::loadConfig()"); // don't edit this

error_reporting(E_ALL);
set_magic_quotes_runtime(0);
@set_time_limit(600);
@ini_set('session.use_trans_sid', false);
@ini_set('php_value session.use_only_cookies',  1);
$this->cfg = array(); //main configuration
if(get_magic_quotes_runtime())
	die("This program can only run with Magic Quotes Runtime off"); // don't edit this
header("Cache-Control: no-cache, must-revalidate");
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");

//###############################################
//# CONSTANTS									#
//###############################################
define('APP_NAME', "Katyshop Romanian"); // how you want your site to be called?
define('APP_VERSION', "ro 0.3.2.1");
define('RELEASE_DATE', "2007-10-30");
define('BASE_HREF', "http://localhost/site/katyshop/work/web/"); // *important*

// * plan C) - breaking the directory structure if needed:
// You can place these directories somewhere else on the hard-disc:
// classes, config, data, docs, sql
// But if you do that and move them, you need to edit this section
// and manually define the constants below.
// Sample (linux): define('CLASSES_DIR', '/docs/secret/hidden/katyshop/classes');
// Sample (windows): define('CLASSES_DIR', 'C:\my_secret_foo_location\hidden\katyshop\classes');
define('CLASSES_DIR', dirname(dirname(__FILE__)) . "/classes");
define('CONFIG_DIR', dirname(__FILE__));
define('DATA_DIR', dirname(dirname(__FILE__)) . "/data");
define('DOCS_DIR', dirname(dirname(__FILE__)) . "/docs");
define('SQL_SCRIPTS_DIR', dirname(dirname(__FILE__)) . "/sql");
define('WEB_DIR', dirname(dirname(__FILE__)) . "/web");

// there is no need to manually edit these, they will rely on those from above.
define('COMMON_DIR', CLASSES_DIR . "/common");
define('DBLAYER_DIR', CLASSES_DIR . "/dblayer");
define('LOGIC_DIR', CLASSES_DIR . "/logic");
define('TOOLS_DIR', CLASSES_DIR . "/tools");
define('ADMIN_DIR', WEB_DIR . "/admin");

$arr = parse_url(BASE_HREF);
$temp = substr( $_SERVER['PHP_SELF'], strlen($arr["path"]) );
define('THIS_DIR', dirname($temp) . "/");
define('THIS_PAGE', basename($_SERVER['PHP_SELF']));

define('ABSOLUTE_PAST_DATE', "1970-01-01 00:00:00");

//###############################################
//# SHOP INFO, VAT...	 						#
//###############################################
$this->cfg["default_vat"] = 19.00; // percents
$this->cfg["default_currency"] = "RON";
$this->cfg["shop_invoice_info"] = "Romanian Katyshop-shop"; // this will appear in proforma

//###############################################
//# DATABASE CONNECTION 						#
//###############################################
 // *important*
$this->cfg["db"] = array(
	"host" => "localhost",
	"user" => "katyshop",
	"pass" => "",
	"name" => "katyshop"
);

// if you need to install multiple web applications on the same
// database and there are conflicts between table names,
// you can change them here. But make sure you also create them in database,
// from the creation script (/sql/create.sql), with the right name, of course.
$this->cfg["db"]["table_names"] = array(
	"user" => "ks_user",
	"user_person" => "ks_user_person",
	"user_company" => "ks_user_company",
	"admin" => "ks_admin",
	"address" => "ks_address",
	"category" => "ks_category",
	"product" => "ks_product",
	"order" => "ks_order",
	"order_product" => "ks_order_product",
	"manufacturer" => "ks_manufacturer",
	"contact_message" => "ks_contact_message"
);

//###############################################
//# SUPERADMIN									#
//###############################################
 // *important*
 // you can use these login info after you start the application,
 // in order to gain access to the administrative panel.
 // It is critical to change that password, LOL :)
 // And please also change the email address, you don't want your private
 // messages to arrive to my inbox, do you? :)
$this->cfg["superadmin"] = array(
	// User data:
	"username" => "superadmin",
	"password" => md5("appleseed"),
	"email" => "hide@address.com",
	"active" => "1"
);

//###############################################
//# MAIL AGENT									#
//###############################################
$this->cfg["mail_agent"] = array(
	"CharSet" => "iso-8859-1",
	"ContentType" => "text/plain",
	"From" => "hide@address.com", // *important*
	"FromName" => APP_NAME . " Support Team",

	// Method to send mail: ("mail", "sendmail", or "smtp").
	"Mailer" => "mail",
	"Sendmail" => "/usr/sbin/sendmail",

	// absolute path to dir where the class.smtp.php file is located
	"PluginDir" => COMMON_DIR . "/phpmailer",
	"Hostname" => "yourdomain.com", // *important*

	// for SMTP:
	"Host" => "localhost",
	"Port" => 25,
	"SMTPAuth" => false,
	"Username" => "",
	"Password" => "",

);

//###############################################
//# LOGGER										#
//###############################################
$this->cfg["logger"] = array(
	"active" => true,
	"errors_active" => true,
	"messages_active" => false,
	"vardump_active" => false,
	"request_active" => false,

	"filename" => "logger.log",
	"errors_filename" => "errors.log",
	"messages_filename" => "messages.log",
	"vardump_filename" => "vardump.log",
	"request_filename" => "request.log"
);

//###############################################
//# DATE FORMAT									#
//###############################################
// how should dates be displayed on website?
$this->cfg["date_format"] = array(
	"date" => "DD/MM/YYYY",
	"time" => "H:i:s",
	"date_time" => "DD/MM/YYYY H:i:s",
	"separator_date" => "/",
	"separator_time" => ":",
	"separator_date_time" => " "
);



?>
Return current item: Katyshop