-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathconfig.php.example
More file actions
50 lines (40 loc) · 1.7 KB
/
config.php.example
File metadata and controls
50 lines (40 loc) · 1.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?php
ini_set('display_startup_errors', 1);
ini_set('display_error', 1);
error_reporting(E_ALL);
date_default_timezone_set("UTC");
/* dark_sky_proxy.php settings START */
$debug = false; // If true the script prints additional debug lines to video
$private_key='a258a26fcc8493fc074ecd506b71e636';
$log_file = "/var/log/dark_sky_proxy/debug.log";
/* dark_sky_proxy.php settings END */
$email_addresses = "Andrea Cannuni <andreacannuni@gmail.com>";
$db_host = "localhost";
$db_user = "foouser";
$db_pass = "abc";
$db_name = "weather";
$charset = 'utf8';
$valid_result_ttl = 300; // Consider valid the results retrieved in the last 5 minutes
$internal_proxy_endpoint = "http://localhost/weather/dark_sky_proxy.php";
define("ROOT_DIR", "/var/www/weather/");
define("INCLUDES_DIR", ROOT_DIR ."includes/");
define("SMARTY_DIR", "vendor/smarty/smarty/libs/");
define("TEMPLATES_DIR", ROOT_DIR ."smarty/");
define("TEMPLATE_NAME", "dark_theme");
define("TEMPLATE_DIR", "smarty/templates/". TEMPLATE_NAME ."/");
define("TEMPLATE_EXT", ".tpl.html");
// put full path to Smarty.class.php
require(SMARTY_DIR.'Smarty.class.php');
$smarty = new Smarty();
$smarty->setTemplateDir(TEMPLATES_DIR .'templates/'. TEMPLATE_NAME);
$smarty->setCompileDir(TEMPLATES_DIR .'templates_c');
$smarty->setCacheDir(TEMPLATES_DIR .'cache');
$smarty->setConfigDir(TEMPLATES_DIR .'configs');
//$smarty->force_compile = true;
$smarty->debugging = false;
$smarty->caching = false;
$smarty->assign('TEMPLATE_CSS_DIR', TEMPLATE_DIR .'css');
$smarty->assign('TEMPLATE_JS_DIR', TEMPLATE_DIR .'js');
$smarty->assign('TEMPLATE_IMAGES_DIR', TEMPLATE_DIR .'images');
$smarty->assign('TEMPLATE_FONTS_DIR', TEMPLATE_DIR .'fonts');
$smarty->assign('TEMPLATE_EXT', TEMPLATE_EXT);