-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathconfig_sample.php
More file actions
125 lines (96 loc) · 4.37 KB
/
config_sample.php
File metadata and controls
125 lines (96 loc) · 4.37 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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
<?php
/**
* @file
* Base configuration file
*
* This file must be included first.
*
*/
// *** DEFINE GLOBALS ***
// The name of the website
$WEBSITE_NAME = 'Hotline admin';
// Filesystem path to the document root
$HTML_BASE = '/home/hotline/html/';
// Filesystem path to the 'lib' directory
$LIB_BASE = $HTML_BASE . 'lib/';
// Web path to the Twilio interface directory
$TWILIO_INTERFACE_WEBROOT = 'https://username:password@hotline.hotline.org/twin/';
// Twilio account ID
$TWILIO_ACCOUNT_SID = '';
// Twilio authorization token
$TWILIO_AUTH_TOKEN = '';
// Twilio cost per text
$TWILIO_COST_PER_TEXT = 0.0075;
// Optional twilio TwiML app for placing in-browser calls
$TWILIO_TWIML_APP_SID = '';
// **** BROADCAST ****
// Broadcast number
$BROADCAST_CALLER_IDS = array('+1NXXNXXXXXX');
// Optional Twilio Notify Service SID
$BROADCAST_TWILIO_NOTIFY_SERVICE = '';
// Broadcast prompts
$BROADCAST_WELCOME = "Welcome to the alert list. ".
"To remove yourself from the list, text OFF.";
$BROADCAST_GOODBYE = "You will no longer receive alerts. To put yourself back on, ".
"text ON.";
// If set, callers will hear this message in each language and then it will hang up. The format is an array,
// with each key the language code, and the value the text to read in that language. "es-MX" is Spanish,
// "en-US" is English. Don't set this and $BROADCAST_SEND_TO_HOTLINE.
// Example: 'en-US' => "Goodbye"
$BROADCAST_VOICE_MESSAGES = array(
);
// Descriptions of the different types of incoming communications for which staff
// members may be scheduled.
$RECEIVE_TEXTS_DESCRIPTION = "texts";
$RECEIVE_CALLS_DESCRIPTION = "calls";
$RECEIVE_CALL_ANSWERED_ALERTS_DESCRIPTION = "call-answered alerts";
// Substrings used to compose messages to be sent via text to staff members who are
// about to start or end their shifts. To $STAFF_REMINDER_SHIFT_CHANGE_MESSAGE_PREFIX
// is appended the type(s) of incoming communications ($RECEIVE_TEXTS_DECRIPTION,
// $RECEIVE_CALLS_DECRIPTION, and/or $RECEIVE_CALL_ANSWERED_ALERTS_DECRIPTION) as a
// comma-separated list for which the staff member is scheduled, then the
// $STAFF_REMINDER_SHIFT_START_DESCRIPTION or $STAFF_REMINDER_SHIFT_END_DESCRIPTION as
// appropriate, then the time at which the shift change is to occur, and finally the
// $STAFF_REMINDER_SHIFT_CHANGE_MESSAGE_SUFFIX.
$STAFF_REMINDER_SHIFT_CHANGE_MESSAGE_PREFIX = "Reminder: Your hotline staffing shift (";
$STAFF_REMINDER_SHIFT_START_DESCRIPTION = ") begins at ";
$STAFF_REMINDER_SHIFT_END_DESCRIPTION = ") ends at ";
$STAFF_REMINDER_SHIFT_CHANGE_MESSAGE_SUFFIX = ".";
// If set, callers to the broadcast numbers will be redirected to this hotline.
// Don't set this and $BROADCAST_VOICE_MESSAGES
$BROADCAST_SEND_TO_HOTLINE = '';
// When a broadcast text is sent that is limited to certain tags, this text will be added to the database
// records of the text.
$BROADCAST_LIMITED_TO_TAGS_TEXT = "LIMITED TO TAGS";
// List users authorized to send broadcast texts here. Leave blank to allow all users.
$BROADCAST_AUTHORIZED_USERS = array();
// If nonzero, outputs a progress mark every X texts sent
$BROADCAST_PROGRESS_MARK_EVERY = 3;
// **** HOTLINE ****
// Each hotline is an element of this array. The array key is the hotline number, and the values are prompts.
$HOTLINES = array(
'+1NXXNXXXXXX' =>
array('name' => 'Just another hotline',
'intro' => 'Just another hotline',
'voicemail' => 'or press 0 for voicemail',
'staff_prompt_1' => 'Just another hotline call in ', // language will be added here
'staff_prompt_2' => '. Press 1 to accept.',
'text_error' => 'Unable to forward your text. Please call in.',
'text_response' => 'Your message has been received. Someone will respond shortly.'),
);
// Hotline prompts
$HOTLINE_GOODBYE = 'Goodbye.';
$HOTLINE_CONNECTING_TO_CALLER = 'Connecting you to the caller.';
$HOTLINE_CALLER_HUNG_UP = 'The caller hung up or someone else took the call. Goodbye.';
// List users authorized to update the staff data here. Leave blank to allow all users.
$HOTLINE_AUTHORIZED_USERS = array();
// **** DATABASE ****
// Database setup
$HOTLINE_DB_DATABASE = '';
$HOTLINE_DB_USERNAME = '';
$HOTLINE_DB_PASSWORD = '';
$HOTLINE_DB_HOSTNAME = 'localhost';
// Time zone
date_default_timezone_set('America/New_York');
// include the database and other common functions
require_once 'lib/lib_db.php';