-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathConfig.php
More file actions
76 lines (65 loc) · 2.55 KB
/
Copy pathConfig.php
File metadata and controls
76 lines (65 loc) · 2.55 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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
<?php
/*
* Configuration settings
*/
// directories
$root_path = dirname(dirname(__FILE__)) . '/';
$web_path = dirname($_SERVER['PHP_SELF']);
$relative_path = $_SERVER['SERVER_NAME'] . dirname($web_path) . '/';
$path_parts = explode('/', $web_path);
$app_path = end($path_parts) . '/';
if (isset($_SERVER['HTTPS'])) {
$server_name = "https://" . $relative_path;
} else {
$server_name = "http://" . $relative_path;
}
/***********************************************************
* Don't forget to insert the web root directory
* for example: "C:/wamp/www/" is the default root web dir in a standard wampServer setup)
* On most Linux servers, it should be: /var/www/
***********************************************************
*/
//define("HTDOCS_ROOT", "/code/");
// Following should work in all situations (with trailing slash)
define("HTDOCS_ROOT", $root_path);
/***********************************************************
* Replace 'localhost' with your IP address,
* if you want to access the template with a mobile device
* connected to the same network
***********************************************************
*/
//define("SERVERNAME", "http://localhost/");
// Automatically set server name - should work in most cases, use above setting if not
define("SERVERNAME", $server_name);
/***********************************************************
* Leave all the settings below unchanged if you only want
* to run the template with the default dataset and parameters.
***********************************************************
*/
// Base dir should be changed if you renamed the folder containing the app
//define("BASE_DIR", 'treefinder/');
define("BASE_DIR", $app_path);
define("CLASSES_DIR", "php/");
define("CLASSES", HTDOCS_ROOT . BASE_DIR . CLASSES_DIR);
define("DEBUG", true);
// dataset - see data folder for various example data files
//define("DATASET_FILE", HTDOCS_ROOT . BASE_DIR ."data/POI_trees_gent.json");
define("DATASET_FILE", HTDOCS_ROOT . BASE_DIR ."data/POI_trees_issy.json");
define("DATASET_ID", 36);
define("DATASET_URL", SERVERNAME . BASE_DIR . "dataset.php");
define("USE_DATABASE", false);
// Map Options (coords point to center of Gent)
/* Alternate coords :
* Gent : 51.033261,3.726488
* Issy les Moulineaux : 48.824023,2.263932
* Athens : 37.976409,23.731327
*/
define("MAP_CENTER_LATITUDE", 48.824023);
define("MAP_CENTER_LONGITUDE", 2.263932);
define("MAP_ZOOM", 16);
// database
define("DB_USERNAME", "root");
define("DB_PASSWORD", "");
define("DB_HOSTNAME", "127.0.0.1");
define("DB_PORT", "3306");
define("DB_NAME", "citadel");