Added CORS(Cross-Origin Resource Sharing) support for the VICIdial agent PHP scripts. see the CORS_SUPPORT.txt doc for more information.

git-svn-id: svn://192.168.202.10@3459 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2021-06-18 03:24:05 +00:00
parent 062d318dc0
commit e2e0505570
35 changed files with 491 additions and 72 deletions
+11 -2
View File
@@ -26,11 +26,11 @@
# 171127-1736 - First Build
# 201117-2217 - Changes for better compatibility with non-latin data input
# 210615-1035 - Default security fixes, CVE-2021-28854
# 210616-2047 - Added optional CORS support, see options.php for details
#
$api_script = 'dispo_change_status';
header ("Content-type: text/html; charset=utf-8");
$php_script = 'dispo_change_status.php';
require_once("dbconnect_mysqli.php");
require_once("functions.php");
@@ -90,6 +90,15 @@ if ( ($archive_search != 'Y') and ($archive_search != 'N') )
if ( ($in_out_search != 'IN') and ($in_out_search != 'OUT') and ($in_out_search != 'BOTH') )
{$in_out_search = 'BOTH';}
# if options file exists, use the override values for the above variables
# see the options-example.php file for more information
if (file_exists('options.php'))
{
require_once('options.php');
}
header ("Content-type: text/html; charset=utf-8");
#############################################
##### START SYSTEM_SETTINGS AND USER LANGUAGE LOOKUP #####
$VUselected_language = '';