Added webform 3 feature for the agent interface

Added campaign variable to No Agent URL process

git-svn-id: svn://192.168.202.10@2313 3d104415-ff17-0410-8863-d5cf3c621b8a
This commit is contained in:
mattf
2015-04-29 13:40:24 +00:00
parent d30fc1f06f
commit 13a1620732
14 changed files with 664 additions and 76 deletions
+8 -1
View File
@@ -1,6 +1,6 @@
#!/usr/bin/perl
#
# AST_send_URL.pl version 2.10
# AST_send_URL.pl version 2.12
#
# DESCRIPTION:
# This script is spawned for remote agents when the Start Call URL is set in the
@@ -19,6 +19,7 @@
# 141211-1742 - Added list override for no-agent url
# 141219-1218 - url logging fix for some inputs
# 150114-2037 - Added list_name variable
# 150429-0910 - Added campaign variables
#
$|++;
@@ -521,6 +522,9 @@ if (length($lead_id) > 0)
$na_call_url =~ s/--A--uniqueid--B--/$VAR_uniqueid/gi;
$na_call_url =~ s/--A--call_id--B--/$VAR_call_id/gi;
$na_call_url =~ s/--A--user_group--B--/$VAR_user_group/gi;
$na_call_url =~ s/--A--campaign--B--/$VAR_campaign_id/gi;
$na_call_url =~ s/--A--campaign_id--B--/$VAR_campaign_id/gi;
$na_call_url =~ s/--A--group--B--/$VAR_campaign_id/gi;
$na_call_url =~ s/ /+/gi;
$na_call_url =~ s/&/\\&/gi;
$parse_url = $na_call_url;
@@ -695,6 +699,9 @@ if (length($lead_id) > 0)
$start_call_url =~ s/--A--uniqueid--B--/$VAR_uniqueid/gi;
$start_call_url =~ s/--A--call_id--B--/$VAR_call_id/gi;
$start_call_url =~ s/--A--user_group--B--/$VAR_user_group/gi;
$start_call_url =~ s/--A--campaign--B--/$VAR_campaign_id/gi;
$start_call_url =~ s/--A--campaign_id--B--/$VAR_campaign_id/gi;
$start_call_url =~ s/--A--group--B--/$VAR_campaign_id/gi;
$start_call_url =~ s/ /+/gi;
$start_call_url =~ s/&/\\&/gi;
$parse_url = $start_call_url;
+4 -1
View File
@@ -1,4 +1,4 @@
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2015-03-13
NON-AGENT API DOCUMENT Started: 2008-07-24 Updated: 2015-04-28
This document describes the functions of an API(Application Programming
Interface) for all functions NOT directly relating to the VICIDIAL Agent screen.
@@ -101,6 +101,7 @@ Changes:
150217-1404 - archive deleted callbacks to vicidial_callbacks_archive table
150309-0250 - Added ability to use urlencoded web form addresses
150313-0818 - Allow for single quotes in vicidial_list and custom data fields
150428-1720 - Added web_form_address_three to add_list/update_list functions
API Functions use the 'function' variable
@@ -1110,6 +1111,7 @@ am_message - 2-100 characters
drop_inbound_group - 1-10 characters, must be a valid in-group
web_form_address - 6-100 characters
web_form_address_two - 6-100 characters
web_form_address_three - 6-100 characters
reset_time - 4-100 characters, must be in valid 4-digit groups of 24-hour time (i.e. 0900-1700-2359)
expiration_date - 10 characters, must be in valid date format YYYY-MM-DD (i.e. 2012-11-25)
NOTES:
@@ -1161,6 +1163,7 @@ am_message - 2-100 characters
drop_inbound_group - 1-10 characters, must be a valid in-group
web_form_address - 6-100 characters
web_form_address_two - 6-100 characters
web_form_address_three - 6-100 characters
reset_time - 4-100 characters, must be in valid 4-digit groups of 24-hour time (i.e. 0900-1700-2359)
expiration_date - 10 characters, must be in valid date format YYYY-MM-DD (i.e. 2012-11-25)
NOTES:
@@ -710,7 +710,7 @@ campaign_rec_exten VARCHAR(20) default '8309',
campaign_recording ENUM('NEVER','ONDEMAND','ALLCALLS','ALLFORCE') default 'ONDEMAND',
campaign_rec_filename VARCHAR(50) default 'FULLDATE_CUSTPHONE',
campaign_script VARCHAR(10),
get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','FORM') default 'NONE',
get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','WEBFORMTHREE','FORM') default 'NONE',
am_message_exten VARCHAR(100) default 'vm-goodbye',
amd_send_to_vmx ENUM('Y','N') default 'N',
xferconf_a_dtmf VARCHAR(50),
@@ -922,7 +922,8 @@ qc_comment_history ENUM('CLICK','AUTO_OPEN','CLICK_ALLOW_MINIMIZE','AUTO_OPEN_AL
show_previous_callback ENUM('DISABLED','ENABLED') default 'ENABLED',
clear_script ENUM('DISABLED','ENABLED') default 'DISABLED',
cpd_unknown_action ENUM('DISABLED','DISPO','MESSAGE','CALLMENU','INGROUP') default 'DISABLED',
manual_dial_search_filter VARCHAR(50) default 'NONE'
manual_dial_search_filter VARCHAR(50) default 'NONE',
web_form_address_three TEXT
) ENGINE=MyISAM;
CREATE TABLE vicidial_lists (
@@ -949,7 +950,8 @@ time_zone_setting ENUM('COUNTRY_AND_AREA_CODE','POSTAL_CODE','NANPA_PREFIX','OWN
inventory_report ENUM('Y','N') default 'Y',
expiration_date DATE default '2099-12-31',
na_call_url TEXT,
local_call_time VARCHAR(10) NOT NULL DEFAULT 'campaign'
local_call_time VARCHAR(10) NOT NULL DEFAULT 'campaign',
web_form_address_three TEXT
) ENGINE=MyISAM;
CREATE TABLE vicidial_statuses (
@@ -1025,7 +1027,7 @@ voicemail_ext VARCHAR(10),
next_agent_call VARCHAR(30) default 'longest_wait_time',
fronter_display ENUM('Y','N') default 'Y',
ingroup_script VARCHAR(10),
get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','FORM','EMAIL') default 'NONE',
get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','WEBFORMTHREE','FORM','EMAIL') default 'NONE',
xferconf_a_dtmf VARCHAR(50),
xferconf_a_number VARCHAR(50),
xferconf_b_dtmf VARCHAR(50),
@@ -1129,7 +1131,8 @@ max_calls_method ENUM('TOTAL','IN_QUEUE','DISABLED') default 'DISABLED',
max_calls_count SMALLINT(5) default '0',
max_calls_action ENUM('DROP','AFTERHOURS','NO_AGENT_NO_QUEUE') default 'NO_AGENT_NO_QUEUE',
dial_ingroup_cid VARCHAR(20) default '',
group_handling ENUM('PHONE','EMAIL') default 'PHONE'
group_handling ENUM('PHONE','EMAIL') default 'PHONE',
web_form_address_three TEXT
) ENGINE=MyISAM;
CREATE TABLE vicidial_stations (
@@ -1585,7 +1588,8 @@ enable_languages ENUM('0','1') default '0',
language_method VARCHAR(20) default 'DISABLED',
meetme_enter_login_filename VARCHAR(255) default '',
meetme_enter_leave3way_filename VARCHAR(255) default '',
enable_did_entry_list_id ENUM('0','1') default '0'
enable_did_entry_list_id ENUM('0','1') default '0',
enable_third_webform ENUM('0','1') default '0'
) ENGINE=MyISAM;
CREATE TABLE vicidial_campaigns_list_mix (
@@ -3375,4 +3379,4 @@ UPDATE vicidial_configuration set value='1766' where name='qc_database_version';
UPDATE system_settings set vdc_agent_api_active='1';
UPDATE system_settings SET db_schema_version='1407',db_schema_update_date=NOW(),reload_timestamp=NOW();
UPDATE system_settings SET db_schema_version='1408',db_schema_update_date=NOW(),reload_timestamp=NOW();
+11
View File
@@ -13,3 +13,14 @@ ALTER TABLE vicidial_inbound_dids ADD entry_list_id BIGINT(14) UNSIGNED default
ALTER TABLE vicidial_inbound_dids ADD filter_entry_list_id BIGINT(14) UNSIGNED default '0';
UPDATE system_settings SET db_schema_version='1407',db_schema_update_date=NOW() where db_schema_version < 1407;
ALTER TABLE system_settings ADD enable_third_webform ENUM('0','1') default '0';
ALTER TABLE vicidial_campaigns ADD web_form_address_three TEXT;
ALTER TABLE vicidial_lists ADD web_form_address_three TEXT;
ALTER TABLE vicidial_inbound_groups ADD web_form_address_three TEXT;
ALTER TABLE vicidial_campaigns MODIFY get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','WEBFORMTHREE','FORM') default 'NONE';
ALTER TABLE vicidial_inbound_groups MODIFY get_call_launch ENUM('NONE','SCRIPT','WEBFORM','WEBFORMTWO','WEBFORMTHREE','FORM') default 'NONE';
UPDATE system_settings SET db_schema_version='1408',db_schema_update_date=NOW() where db_schema_version < 1408;
+267
View File
@@ -0,0 +1,267 @@
#!/usr/bin/perl
use strict;
# Copyright 2007 Jay Allen
# 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/>.
#
# Author: Jay D. Allen jay@f2it.com
# Version: 1.4 - July 2007
#
# 1. Delete any stale .lock* files. Stale is defined as ctime/atime more
# a few minutes old (maybe 30 minutes to be safe)? Look into the cause of
# these stake lock files? What versions of Asterisk are effected?
# Nasty bug! .locked mailboxes _silently_ drop voicemail recordings.
# 2. Remove voicemail files older than a policy date
# 3. Possibly a report mode that just shows the age of the mail/boxes but
# does nothing
# Report on number of messages per box, vs quota max
# Send whiny emails to users about voicemail quota.
# 4. Renumber boxes that are missing msg0001.X - since that will prevent
# playback.
=head1 vmspool_manager.pl
This is a utility which does some checks on existing asterisk voicemail files and deletes old lock files and mail messages. This is best run on a system that is not being used due the file renumbering and deleting of files which Asterisk could be accessing at the same time.
=head1 Options
--active: Run in active mode, deleting files. Default is to 'report'
--age=<#>: Time after which a message is considered old in days. Default is 14 days.
--bad: Remove message files that do not have the expected number of files.
--context=<name>: The context for Asterisk, set to 'default' by default.
--debug: Debug mode.
--group=<name>: Name of group, default is "asterisk"
--help: Help message.
--mailbox=<#>: Run for a particular mailbox.
--spool=<path>: Set to path to mail spool. Default is "/var/spool/asterisk/voicemail"
--user=<name>: Name of user, default is "asterisk"
=head1 USAGE: To delete files over 30 days old. Also remove bad lock files.
fixup-voicemail.perl --age=30 --active
=head1 FUNCTIONS
=cut
use Getopt::Long;
use Pod::Usage;
our $DEBUG=0;
our $REPORT=1;
# Voicemail User
our $VM_USER="asterisk";
# Voicemail Group
our $VM_GROUP="asterisk";
# Sane defaults for Trixbox
our $VM_CONTEXT="default";
our $VM_SPOOL="/var/spool/asterisk/voicemail";
# Developer's box
#our $VM_SPOOL="/home/judith/ast-runtime-1.2.14/var/spool/asterisk/voicemail";
our $MAX_AGE=14; # days
our $MAX_LOCK_AGE=30; # minutes
our $VMDIR; # This is the directory handle
our @SUFFIXES=("WAV", "gsm", "txt", "wav");
our @MAILBOX_TYPES=("Old", "INBOX");
our $ACTIVE = undef;
our $BAD = undef;
our $HELP = undef;
our $ONE_MAILBOX = undef;
my $result = GetOptions ("active" => \$ACTIVE,
"age=i" => \$MAX_AGE, # numeric
"bad" => \$BAD, # string
"context=s" => \$VM_CONTEXT, # string
"debug" => \$DEBUG, # flag
"group=s" => \$VM_GROUP, # string
"help" => \$HELP, # flag
"mailbox=i" => \$ONE_MAILBOX, # flag
"spool=s" => \$VM_SPOOL,
"user=s" => \$VM_USER) or pod2usage(2);
## Parse options and print usage if there is a syntax error,
## or if usage was explicitly requested.
pod2usage(1) if $HELP;
our $VM_SPOOL_PATH="$VM_SPOOL/$VM_CONTEXT";
if ($ACTIVE){
$REPORT = undef;
}
#
# Here is the main script.
# Get a list of all the voicemail directorys in this context
opendir(VMDIR,$VM_SPOOL_PATH) || die "Can't open $VM_SPOOL_PATH\n";
my @mailboxes = grep { /^\d./ && -d "$VM_SPOOL_PATH/$_" } readdir(VMDIR);
if ($ONE_MAILBOX){
if ( -d "$VM_SPOOL_PATH/$ONE_MAILBOX" ){
@mailboxes = ( $ONE_MAILBOX );
} else {
die "Mailbox $VM_SPOOL_PATH/$ONE_MAILBOX does not exist\n";
}
}
foreach my $vmbox (@mailboxes){
foreach my $mailbox_type (@MAILBOX_TYPES){
print "MAILBOX $vmbox/$mailbox_type\n";
my $MAILBOX;
my $path = "$VM_SPOOL_PATH/$vmbox/$mailbox_type";
if(opendir($MAILBOX, $path)){
delete_old_messages($MAILBOX, $path);
renumber($MAILBOX, $path);
} # end of if has a vmbox/old
}
}
closedir VMDIR;
=head2 delete_old_messages
Delete the Contents of the passed directory.
=cut
sub delete_old_messages{
my $MAILBOX=shift;
my $path=shift;
if (! delete_lock_file( $MAILBOX, $path)){
foreach my $filename (sort grep ( /^msg.*/, readdir($MAILBOX))){
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat("$path/$filename");
if ($DEBUG and !$REPORT){ print "\tFile $size: ".localtime($mtime).": $filename\n"; }
if( $mtime < (time()-(60*60*24*$MAX_AGE))){
print "\tDELETE: $size: ".localtime($mtime).": $filename\n";
if ($ACTIVE){ unlink "$path/$filename"; }
if ($DEBUG and !$REPORT){ "DELETE $filename\n"; }
} else { if ($REPORT){print "\tKEEP: $size: ".localtime($mtime).": $filename\n"} };
}
rewinddir($MAILBOX);
} else {
if ($REPORT){print "Mailbox $MAILBOX is LOCKED\n"};
}
}
=head2 delete_lock_file
Delete a lockfile older than 30 minutes in the passed mailbox.
=cut
sub delete_lock_file {
my $MAILBOX=shift;
my $path=shift;
my $retval=0;
foreach my $filename (sort grep ( /^\.lock*/, readdir($MAILBOX))){
my ($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blksize,$blocks) = stat("$path/$filename");
$retval=1;
if( $mtime < (time()-(60*$MAX_LOCK_AGE))){
$retval=0;
if ($REPORT){ print "\tDELETE LOCK: $size:".localtime($mtime).": $filename\n";}
else { unlink "$path/$filename";}
}
}
rewinddir($MAILBOX); # Make sure we rewind!
return $retval;
}
=head2 check_message_files
Check that there are the right number of messages using the array SUFFIXES. Delete 'bad' messages if in active mode.
=cut
sub check_message_files{
my $file_names=shift; # This is an array of the filenames.
my $path=shift;
my %mboxindx=();
foreach my $fixfile (@{$file_names}){
if($fixfile =~ /^msg/){
my ($prefix,$suffix)=split(/\./,$fixfile);
if ($DEBUG){print "\tCheck presence: $prefix\.$suffix\n";}
$mboxindx{$prefix}++;
}
} # End of foreach $fixfile
foreach my $index (keys %mboxindx){
if ($mboxindx{$index} != $#SUFFIXES + 1) {
print "Broken Mailbox: $index: $mboxindx{$index}\n" ;
# if ((! $REPORT) and $BAD){
# # Remove files where incomplete.
# print "Remove files $path/$index*\n";
# unlink <$path/$index.*>;
# }
}
}
}
=head2 renumber
Asterisk needs a message with 'msg0000.XXX' in each mailbox to function. This function will renumber the lowest number message to msg0000.XXX if one does not exist.
=cut
sub renumber {
my $MAILBOX=shift;
my $path = shift;
my @OLDMAILBOX=();
# Fixup/checkup of Old voicemail box
@OLDMAILBOX = sort grep (/^msg.*/ , readdir($MAILBOX));
if($#OLDMAILBOX > -1 ) {
if ($DEBUG){ print "\tHas mail messages: " . ($#OLDMAILBOX + 1)/($#SUFFIXES + 1) . "\n";}
if ($DEBUG){ print "\tFIRST FILE: $OLDMAILBOX[0]\n";}
if($OLDMAILBOX[0] !~ /msg0000.*/) {
print "Has renumber broken msglist\n";
rename_first_message($path, $OLDMAILBOX[0]);
}
}
check_message_files(\@OLDMAILBOX, $path);
rewinddir($MAILBOX); # Make sure we rewind!
}
=head2 rename_first_message
This function will renumber the passed message to msg0000.XXX.
=cut
sub rename_first_message {
my $path = shift;
my $filename = shift;
if ($filename =~ /^msg.*/){
my ($prefix,$suffix)=split(/\./,$filename);
foreach my $suff (@SUFFIXES){
print "\tRenaming files: $path/$prefix.$suff to $path/msg0000\.$suff\n";
if ($ACTIVE){
rename "$path/$prefix.$suff", "$path/msg0000\.$suff";
} else {
print "\tWould rename files: $path/$prefix.$suff to $path/msg0000\.$suff\n";
}
}
}
}
Binary file not shown.

After

Width:  |  Height:  |  Size: 708 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 702 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 518 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 518 B

+43 -24
View File
@@ -375,10 +375,11 @@
# 150114-2051 - Added list_name web url variable
# 150117-1412 - Added list local call time validation
# 150312-1501 - Allow for single quotes in vicidial_list data fields
# 150428-1722 - Added web form three
#
$version = '2.12-270';
$build = '150312-1501';
$version = '2.12-271';
$build = '150428-1722';
$mel=1; # Mysql Error Log enabled = 1
$mysql_log_count=616;
$one_mysql_log=0;
@@ -3512,10 +3513,11 @@ if ($ACTION == 'manDiaLnextCaLL')
$campaign_cid_override='';
$LISTweb_form_address='';
$LISTweb_form_address_two='';
$LISTweb_form_address_three='';
### check if there is a list_id override
if (strlen($list_id) > 1)
{
$stmt = "SELECT campaign_cid_override,web_form_address,web_form_address_two FROM vicidial_lists where list_id='$list_id';";
$stmt = "SELECT campaign_cid_override,web_form_address,web_form_address_two,web_form_address_three FROM vicidial_lists where list_id='$list_id';";
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00245',$user,$server_ip,$session_name,$one_mysql_log);}
if ($DB) {echo "$stmt\n";}
@@ -3523,9 +3525,10 @@ if ($ACTION == 'manDiaLnextCaLL')
if ($lio_ct > 0)
{
$row=mysqli_fetch_row($rslt);
$campaign_cid_override = $row[0];
$LISTweb_form_address = $row[1];
$LISTweb_form_address_two = $row[2];
$campaign_cid_override = $row[0];
$LISTweb_form_address = $row[1];
$LISTweb_form_address_two = $row[2];
$LISTweb_form_address_three = $row[3];
}
}
@@ -4040,6 +4043,7 @@ if ($ACTION == 'manDiaLnextCaLL')
$LeaD_InfO .= $ACcount . "\n";
$LeaD_InfO .= $ACcomments . "\n";
$LeaD_InfO .= $list_name . "\n";
$LeaD_InfO .= $LISTweb_form_address_three . "\n";
echo $LeaD_InfO;
}
@@ -4325,6 +4329,7 @@ if ($ACTION == 'manDiaLonly')
$CCID_on=0; $CCID='';
$LISTweb_form_address='';
$LISTweb_form_address_two='';
$LISTweb_form_address_three='';
$local_DEF = 'Local/';
$local_AMP = '@';
$Local_out_prefix = '9';
@@ -4353,7 +4358,7 @@ if ($ACTION == 'manDiaLonly')
if (strlen($list_id) > 1)
{
$stmt = "SELECT campaign_cid_override,web_form_address,web_form_address_two FROM vicidial_lists where list_id='$list_id';";
$stmt = "SELECT campaign_cid_override,web_form_address,web_form_address_two,web_form_address_three FROM vicidial_lists where list_id='$list_id';";
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00247',$user,$server_ip,$session_name,$one_mysql_log);}
if ($DB) {echo "$stmt\n";}
@@ -4361,9 +4366,10 @@ if ($ACTION == 'manDiaLonly')
if ($lio_ct > 0)
{
$row=mysqli_fetch_row($rslt);
$campaign_cid_override = $row[0];
$LISTweb_form_address = $row[1];
$LISTweb_form_address_two = $row[2];
$campaign_cid_override = $row[0];
$LISTweb_form_address = $row[1];
$LISTweb_form_address_two = $row[2];
$LISTweb_form_address_three = $row[3];
}
}
}
@@ -6638,7 +6644,7 @@ if ($ACTION == 'VDADcheckINCOMING')
### Check for List ID override settings
if (strlen($list_id)>0)
{
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name from vicidial_lists where list_id='$list_id';";
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name,web_form_address_three from vicidial_lists where list_id='$list_id';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00281',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -6662,10 +6668,12 @@ if ($ACTION == 'VDADcheckINCOMING')
{$VDCL_group_web_two = $row[6];}
if (strlen($row[7]) > 0)
{$list_name = $row[7];}
if (strlen($row[8]) > 5)
{$VDCL_group_web_three = $row[8];}
}
}
echo "$VDCL_group_web|$VDCL_group_name||||$VDCL_campaign_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|X|X||||$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number||||$VDCL_timer_action_destination||||||\n|\n";
echo "$VDCL_group_web|$VDCL_group_name||||$VDCL_campaign_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|X|X||||$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number||||$VDCL_timer_action_destination||||||$VDCL_group_web_three|\n|\n";
if (preg_match('/X/',$dialed_label))
{
@@ -6741,7 +6749,7 @@ if ($ACTION == 'VDADcheckINCOMING')
$script_recording_delay = $row[0];
}
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination from vicidial_inbound_groups where group_id='$VDADchannel_group';";
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination,web_form_address_three from vicidial_inbound_groups where group_id='$VDADchannel_group';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00119',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -6775,6 +6783,7 @@ if ($ACTION == 'VDADcheckINCOMING')
$VDCL_uniqueid_status_display = $row[23];
$VDCL_uniqueid_status_prefix = $row[24];
$VDCL_timer_action_destination = $row[25];
$VDCL_group_web_three = stripslashes($row[26]);
$stmt = "SELECT campaign_script,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_group_alias,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,timer_action_destination from vicidial_campaigns where campaign_id='$campaign';";
if ($DB) {echo "$stmt\n";}
@@ -6935,7 +6944,7 @@ if ($ACTION == 'VDADcheckINCOMING')
### Check for List ID override settings
if (strlen($list_id)>0)
{
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name from vicidial_lists where list_id='$list_id';";
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name,web_form_address_three from vicidial_lists where list_id='$list_id';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00282',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -6959,6 +6968,8 @@ if ($ACTION == 'VDADcheckINCOMING')
{$VDCL_group_web_two = $row[6];}
if (strlen($row[7]) > 0)
{$list_name = $row[7];}
if (strlen($row[8]) > 5)
{$VDCL_group_web_three = $row[8];}
}
}
@@ -6992,8 +7003,8 @@ if ($ACTION == 'VDADcheckINCOMING')
}
### if web form is set then send on to vicidial.php for override of WEB_FORM address
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
$stmt = "SELECT full_name from vicidial_users where user='$tsr';";
if ($DB) {echo "$stmt\n";}
@@ -7135,6 +7146,7 @@ if ($ACTION == 'VDADcheckINCOMING')
$LeaD_InfO .= $ACcount . "\n";
$LeaD_InfO .= $ACcomments . "\n";
$LeaD_InfO .= $list_name . "\n";
$LeaD_InfO .= $LISTweb_form_address_three . "\n";
echo $LeaD_InfO;
@@ -7760,7 +7772,7 @@ if ($ACTION == 'VDADcheckINCOMINGemail')
$row=mysqli_fetch_row($rslt);
$VDCL_front_VDlog =$row[0];
}
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination from vicidial_inbound_groups where group_id='$VDADchannel_group';";
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination,web_form_address_three from vicidial_inbound_groups where group_id='$VDADchannel_group';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00500',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -7794,6 +7806,7 @@ if ($ACTION == 'VDADcheckINCOMINGemail')
$VDCL_uniqueid_status_display = $row[23];
$VDCL_uniqueid_status_prefix = $row[24];
$VDCL_timer_action_destination = $row[25];
$VDCL_group_web_three = stripslashes($row[26]);
$stmt = "SELECT campaign_script,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_group_alias,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,timer_action_destination from vicidial_campaigns where campaign_id='$campaign';";
if ($DB) {echo "$stmt\n";}
@@ -7923,7 +7936,7 @@ if ($ACTION == 'VDADcheckINCOMINGemail')
### Check for List ID override settings
if (strlen($list_id)>0)
{
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name from vicidial_lists where list_id='$list_id';";
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name,web_form_address_three from vicidial_lists where list_id='$list_id';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00508',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -7947,6 +7960,8 @@ if ($ACTION == 'VDADcheckINCOMINGemail')
{$VDCL_group_web_two = $row[6];}
if (strlen($row[7]) > 0)
{$list_name = $row[7];}
if (strlen($row[8]) > 5)
{$VDCL_group_web_three = $row[8];}
}
}
@@ -7980,8 +7995,8 @@ if ($ACTION == 'VDADcheckINCOMINGemail')
}
### if web form is set then send on to vicidial.php for override of WEB_FORM address
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
$stmt = "SELECT full_name from vicidial_users where user='$tsr';";
if ($DB) {echo "$stmt\n";}
@@ -8757,7 +8772,7 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
$script_recording_delay = $row[0];
}
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination from vicidial_inbound_groups where group_id='$VDADchannel_group';";
$stmt = "SELECT group_name,group_color,web_form_address,fronter_display,ingroup_script,get_call_launch,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_xfer_group,ingroup_recording_override,ingroup_rec_filename,default_group_alias,web_form_address_two,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,uniqueid_status_display,uniqueid_status_prefix,timer_action_destination,web_form_address_three from vicidial_inbound_groups where group_id='$VDADchannel_group';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00468',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -8791,6 +8806,7 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
$VDCL_uniqueid_status_display = $row[23];
$VDCL_uniqueid_status_prefix = $row[24];
$VDCL_timer_action_destination = $row[25];
$VDCL_group_web_three = stripslashes($row[26]);
$stmt = "SELECT campaign_script,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,default_group_alias,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,timer_action_destination from vicidial_campaigns where campaign_id='$campaign';";
if ($DB) {echo "$stmt\n";}
@@ -8878,7 +8894,7 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
### Check for List ID override settings
if (strlen($list_id)>0)
{
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name from vicidial_lists where list_id='$list_id';";
$stmt = "SELECT xferconf_a_number,xferconf_b_number,xferconf_c_number,xferconf_d_number,xferconf_e_number,web_form_address,web_form_address_two,list_name,web_form_address_three from vicidial_lists where list_id='$list_id';";
if ($DB) {echo "$stmt\n";}
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'00473',$user,$server_ip,$session_name,$one_mysql_log);}
@@ -8902,6 +8918,8 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
{$VDCL_group_web_two = $row[6];}
if (strlen($row[7]) > 0)
{$list_name = $row[7];}
if (strlen($row[8]) > 5)
{$VDCL_group_web_three = $row[8];}
}
}
@@ -8935,8 +8953,8 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
}
### if web form is set then send on to vicidial.php for override of WEB_FORM address
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|\n";}
if ( (strlen($VDCL_group_web)>5) or (strlen($VDCL_group_name)>0) ) {echo "$VDCL_group_web|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
else {echo "X|$VDCL_group_name|$VDCL_group_color|$VDCL_fronter_display|$VDADchannel_group|$VDCL_ingroup_script|$VDCL_get_call_launch|$VDCL_xferconf_a_dtmf|$VDCL_xferconf_a_number|$VDCL_xferconf_b_dtmf|$VDCL_xferconf_b_number|$VDCL_default_xfer_group|$VDCL_ingroup_recording_override|$VDCL_ingroup_rec_filename|$VDCL_default_group_alias|$VDCL_caller_id_number|$VDCL_group_web_vars|$VDCL_group_web_two|$VDCL_timer_action|$VDCL_timer_action_message|$VDCL_timer_action_seconds|$VDCL_xferconf_c_number|$VDCL_xferconf_d_number|$VDCL_xferconf_e_number|$VDCL_uniqueid_status_display|$custom_call_id|$VDCL_uniqueid_status_prefix|$VDCL_timer_action_destination|$DID_id|$DID_extension|$DID_pattern|$DID_description|$INclosecallid|$INxfercallid|$VDCL_group_web_three|\n";}
$stmt = "SELECT full_name from vicidial_users where user='$tsr';";
if ($DB) {echo "$stmt\n";}
@@ -9089,6 +9107,7 @@ if ($ACTION == 'LeaDSearcHSelecTUpdatE')
$LeaD_InfO .= $ACcount . "\n";
$LeaD_InfO .= $ACcomments . "\n";
$LeaD_InfO .= $list_name . "\n";
$LeaD_InfO .= $LISTweb_form_address_three . "\n";
echo $LeaD_InfO;
+204 -12
View File
@@ -484,10 +484,11 @@
# 150309-0315 - Added custom agent login prompt option
# 150405-1410 - Fixed issue with API dialing and preview
# 150418-2206 - Fixed issue with manual dial with hotkeys in RATIO method, issue #836
# 150428-1735 - Added web form three
#
$version = '2.12-456c';
$build = '150418-2206';
$version = '2.12-457c';
$build = '150428-1735';
$mel=1; # Mysql Error Log enabled = 1
$mysql_log_count=85;
$one_mysql_log=0;
@@ -584,7 +585,7 @@ if ($sl_ct > 0)
#############################################
##### START SYSTEM_SETTINGS LOOKUP #####
$stmt = "SELECT use_non_latin,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,webroot_writable,timeclock_end_of_day,vtiger_url,enable_vtiger_integration,outbound_autodial_active,enable_second_webform,user_territories_active,static_agent_url,custom_fields_enabled,pllb_grouping_limit,qc_features_active,allow_emails,callback_time_24hour,enable_languages,language_method,meetme_enter_login_filename,meetme_enter_leave3way_filename FROM system_settings;";
$stmt = "SELECT use_non_latin,vdc_header_date_format,vdc_customer_date_format,vdc_header_phone_format,webroot_writable,timeclock_end_of_day,vtiger_url,enable_vtiger_integration,outbound_autodial_active,enable_second_webform,user_territories_active,static_agent_url,custom_fields_enabled,pllb_grouping_limit,qc_features_active,allow_emails,callback_time_24hour,enable_languages,language_method,meetme_enter_login_filename,meetme_enter_leave3way_filename,enable_third_webform FROM system_settings;";
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'01001',$VD_login,$server_ip,$session_name,$one_mysql_log);}
if ($DB) {echo "$stmt\n";}
@@ -613,6 +614,7 @@ if ($qm_conf_ct > 0)
$SSlanguage_method = $row[18];
$meetme_enter_login_filename = $row[19];
$meetme_enter_leave3way_filename = $row[20];
$enable_third_webform = $row[21];
}
else
{
@@ -1590,7 +1592,7 @@ else
$HKstatusnames = substr("$HKstatusnames", 0, -1);
##### grab the campaign settings
$stmt="SELECT park_ext,park_file_name,web_form_address,allow_closers,auto_dial_level,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,agent_pause_codes_active,no_hopper_leads_logins,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,use_campaign_dnc,three_way_call_cid,dial_method,three_way_dial_prefix,web_form_target,vtiger_screen_login,agent_allow_group_alias,default_group_alias,quick_transfer_button,prepopulate_transfer_preset,view_calls_in_queue,view_calls_in_queue_launch,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two,agent_select_territories,crm_popup_login,crm_login_address,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,use_custom_cid,scheduled_callbacks_alert,scheduled_callbacks_count,manual_dial_override,blind_monitor_warning,blind_monitor_message,blind_monitor_filename,timer_action_destination,enable_xfer_presets,hide_xfer_number_to_dial,manual_dial_prefix,customer_3way_hangup_logging,customer_3way_hangup_seconds,customer_3way_hangup_action,ivr_park_call,manual_preview_dial,api_manual_dial,manual_dial_call_time_check,my_callback_option,per_call_notes,agent_lead_search,agent_lead_search_method,queuemetrics_phone_environment,auto_pause_precall,auto_pause_precall_code,auto_resume_precall,manual_dial_cid,custom_3way_button_transfer,callback_days_limit,disable_dispo_screen,disable_dispo_status,screen_labels,status_display_fields,pllb_grouping,pllb_grouping_limit,in_group_dial,in_group_dial_select,pause_after_next_call,owner_populate,manual_dial_lead_id,dead_max,dispo_max,pause_max,dead_max_dispo,dispo_max_dispo,max_inbound_calls,manual_dial_search_checkbox,hide_call_log_info,timer_alt_seconds,wrapup_bypass,wrapup_after_hotkey,callback_active_limit,callback_active_limit_override,comments_all_tabs,comments_dispo_screen,comments_callback_screen,qc_comment_history,show_previous_callback,clear_script,manual_dial_search_filter FROM vicidial_campaigns where campaign_id = '$VD_campaign';";
$stmt="SELECT park_ext,park_file_name,web_form_address,allow_closers,auto_dial_level,dial_timeout,dial_prefix,campaign_cid,campaign_vdad_exten,campaign_rec_exten,campaign_recording,campaign_rec_filename,campaign_script,get_call_launch,am_message_exten,xferconf_a_dtmf,xferconf_a_number,xferconf_b_dtmf,xferconf_b_number,alt_number_dialing,scheduled_callbacks,wrapup_seconds,wrapup_message,closer_campaigns,use_internal_dnc,allcalls_delay,omit_phone_code,agent_pause_codes_active,no_hopper_leads_logins,campaign_allow_inbound,manual_dial_list_id,default_xfer_group,xfer_groups,disable_alter_custphone,display_queue_count,manual_dial_filter,agent_clipboard_copy,use_campaign_dnc,three_way_call_cid,dial_method,three_way_dial_prefix,web_form_target,vtiger_screen_login,agent_allow_group_alias,default_group_alias,quick_transfer_button,prepopulate_transfer_preset,view_calls_in_queue,view_calls_in_queue_launch,call_requeue_button,pause_after_each_call,no_hopper_dialing,agent_dial_owner_only,agent_display_dialable_leads,web_form_address_two,agent_select_territories,crm_popup_login,crm_login_address,timer_action,timer_action_message,timer_action_seconds,start_call_url,dispo_call_url,xferconf_c_number,xferconf_d_number,xferconf_e_number,use_custom_cid,scheduled_callbacks_alert,scheduled_callbacks_count,manual_dial_override,blind_monitor_warning,blind_monitor_message,blind_monitor_filename,timer_action_destination,enable_xfer_presets,hide_xfer_number_to_dial,manual_dial_prefix,customer_3way_hangup_logging,customer_3way_hangup_seconds,customer_3way_hangup_action,ivr_park_call,manual_preview_dial,api_manual_dial,manual_dial_call_time_check,my_callback_option,per_call_notes,agent_lead_search,agent_lead_search_method,queuemetrics_phone_environment,auto_pause_precall,auto_pause_precall_code,auto_resume_precall,manual_dial_cid,custom_3way_button_transfer,callback_days_limit,disable_dispo_screen,disable_dispo_status,screen_labels,status_display_fields,pllb_grouping,pllb_grouping_limit,in_group_dial,in_group_dial_select,pause_after_next_call,owner_populate,manual_dial_lead_id,dead_max,dispo_max,pause_max,dead_max_dispo,dispo_max_dispo,max_inbound_calls,manual_dial_search_checkbox,hide_call_log_info,timer_alt_seconds,wrapup_bypass,wrapup_after_hotkey,callback_active_limit,callback_active_limit_override,comments_all_tabs,comments_dispo_screen,comments_callback_screen,qc_comment_history,show_previous_callback,clear_script,manual_dial_search_filter,web_form_address_three FROM vicidial_campaigns where campaign_id = '$VD_campaign';";
$rslt=mysql_to_mysqli($stmt, $link);
if ($mel > 0) {mysql_error_logging($NOW_TIME,$link,$mel,$stmt,'01013',$VD_login,$server_ip,$session_name,$one_mysql_log);}
if ($DB) {echo "$stmt\n";}
@@ -1721,6 +1723,7 @@ else
$show_previous_callback = $row[123];
$clear_script = $row[124];
$manual_dial_search_filter =$row[125];
$web_form_address_three = $row[126];
if ( ($callback_active_limit_override == 'Y') and ($callback_active_limit > 0) )
{
@@ -2682,6 +2685,20 @@ else
}
$VICIDiaL_web_form_address_two_enc = rawurlencode($VICIDiaL_web_form_address_two);
# If a web form address three is not set, use the first one
if (strlen($web_form_address_three)>0)
{
$VICIDiaL_web_form_address_three = "$web_form_address_three";
echo "<!-- CAMPAIGN CUSTOM WEB FORM 3: |$VICIDiaL_web_form_address_three| -->\n";
}
else
{
$VICIDiaL_web_form_address_three = "$VICIDiaL_web_form_address";
echo "<!-- CAMPAIGN DEFAULT WEB FORM 3: |$VICIDiaL_web_form_address_three| -->\n";
$VICIDiaL_web_form_address_three_enc = rawurlencode($VICIDiaL_web_form_address_three);
}
$VICIDiaL_web_form_address_three_enc = rawurlencode($VICIDiaL_web_form_address_three);
# If closers are allowed on this campaign
if ($allow_closers=="Y")
{
@@ -3702,6 +3719,9 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";}
var VICIDiaL_web_form_address_two_enc = '<?php echo $VICIDiaL_web_form_address_two_enc ?>';
var VICIDiaL_web_form_address_two = '<?php echo $VICIDiaL_web_form_address_two ?>';
var VDIC_web_form_address_two = '<?php echo $VICIDiaL_web_form_address_two ?>';
var VICIDiaL_web_form_address_three_enc = '<?php echo $VICIDiaL_web_form_address_three_enc ?>';
var VICIDiaL_web_form_address_three = '<?php echo $VICIDiaL_web_form_address_three ?>';
var VDIC_web_form_address_three = '<?php echo $VICIDiaL_web_form_address_three ?>';
var CalL_ScripT_id = '';
var CalL_AutO_LauncH = '';
var panel_bgcolor = '<?php echo $MAIN_COLOR ?>';
@@ -3884,6 +3904,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";}
var web_form_target = '<?php echo $web_form_target ?>';
var TEMP_VDIC_web_form_address = '';
var TEMP_VDIC_web_form_address_two = '';
var TEMP_VDIC_web_form_address_three = '';
var APIPausE_ID = '99999';
var APIDiaL_ID = '99999';
var CheckDEADcall = 0;
@@ -3921,6 +3942,7 @@ if ($enable_fast_refresh < 1) {echo "\tvar refresh_interval = 1000;\n";}
var script_width = '<?php echo $SDwidth ?>';
var script_height = '<?php echo $SSheight ?>';
var enable_second_webform = '<?php echo $enable_second_webform ?>';
var enable_third_webform = '<?php echo $enable_third_webform ?>';
var no_delete_VDAC=0;
var manager_ingroups_set=0;
var external_igb_set_name='';
@@ -6732,8 +6754,9 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
if (change_array[0] == '1')
{
var VDIC_data_VDAC=change_array[1].split("|");
VDIC_web_form_address = VICIDiaL_web_form_address
VDIC_web_form_address_two = VICIDiaL_web_form_address_two
VDIC_web_form_address = VICIDiaL_web_form_address;
VDIC_web_form_address_two = VICIDiaL_web_form_address_two;
VDIC_web_form_address_three = VICIDiaL_web_form_address_three;
var VDIC_fronter='';
var change_data=change_array[2].split("|");
@@ -6794,6 +6817,8 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
did_description = change_data[31];
closecallid = change_data[32];
xfercallid = change_data[33];
if (change_data[34].length > 5)
{VDIC_web_form_address_three = change_data[34];}
document.vicidial_form.lead_id.value = VDIC_data_VDAC[0];
LeaDPreVDispO = change_array[6];
@@ -7002,6 +7027,16 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
TEMP_VDIC_web_form_address_two = URLDecode(VDIC_web_form_address_two,'YES','DEFAULT','2');
}
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
document.getElementById("WebFormSpan").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform.gif"); ?>\" border=\"0\" alt=\"Web Form\" /></a>\n";
if (enable_second_webform > 0)
@@ -7009,6 +7044,11 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_two + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormTwoRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" /></a>\n";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
if ( (view_scripts == 1) && (CalL_ScripT_id.length > 0) )
{
var SCRIPT_web_form = 'http://127.0.0.1/testing.php';
@@ -7050,6 +7090,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (CalL_AutO_LauncH == 'WEBFORMTHREE')
{
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (useIE > 0)
{
@@ -7700,11 +7744,25 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
TEMP_VDIC_web_form_address_two = URLDecode(VDIC_web_form_address_two,'YES','DEFAULT','2');
}
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
document.getElementById("WebFormSpan").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform.gif"); ?>\" border=\"0\" alt=\"Web Form\" /></a>\n";
if (enable_second_webform > 0)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_two + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormTwoRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" /></a>\n";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
}
else
{
@@ -8012,6 +8070,7 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
//END section Added By Poundteam for Audited Comments
document.vicidial_form.list_name.value = MDnextResponse_array[53];
var list_webform_three = MDnextResponse_array[54];
timer_action = campaign_timer_action;
timer_action_message = campaign_timer_action_message;
@@ -8047,10 +8106,12 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
LeaDDispO='';
VDIC_web_form_address = VICIDiaL_web_form_address
VDIC_web_form_address_two = VICIDiaL_web_form_address_two
VDIC_web_form_address = VICIDiaL_web_form_address;
VDIC_web_form_address_two = VICIDiaL_web_form_address_two;
VDIC_web_form_address_three = VICIDiaL_web_form_address_three;
if (list_webform.length > 5) {VDIC_web_form_address=list_webform;}
if (list_webform_two.length > 5) {VDIC_web_form_address_two=list_webform_two;}
if (list_webform_three.length > 5) {VDIC_web_form_address_three=list_webform_three;}
var regWFAcustom = new RegExp("^VAR","ig");
if (VDIC_web_form_address.match(regWFAcustom))
@@ -8073,11 +8134,25 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
TEMP_VDIC_web_form_address_two = URLDecode(VDIC_web_form_address_two,'YES','DEFAULT','2');
}
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
document.getElementById("WebFormSpan").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform.gif"); ?>\" border=\"0\" alt=\"Web Form\" /></a>\n";
if (enable_second_webform > 0)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_two + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormTwoRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" /></a>\n";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
if (CBentry_time.length > 2)
{
@@ -8161,6 +8236,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (get_call_launch == 'WEBFORMTHREE')
{
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
}
else
{
@@ -8367,6 +8446,7 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
dialed_label = 'ALT';
WebFormRefresH('');
WebFormTwoRefresH('');
WebFormThreeRefresH('');
}
else
{
@@ -8378,6 +8458,7 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
dialed_label = 'ADDR3';
WebFormRefresH('');
WebFormTwoRefresH('');
WebFormThreeRefresH('');
}
else
{
@@ -8387,6 +8468,7 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
dialed_label = 'MAIN';
WebFormRefresH('');
WebFormTwoRefresH('');
WebFormThreeRefresH('');
}
}
if (dialed_label == 'ALT')
@@ -8548,6 +8630,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (get_call_launch == 'WEBFORMTHREE')
{
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
}
}
}
@@ -8871,8 +8957,9 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
UpdatESettingSChecK = 1;
var VDIC_data_VDAC=check_VDIC_array[1].split("|");
VDIC_web_form_address = VICIDiaL_web_form_address
VDIC_web_form_address_two = VICIDiaL_web_form_address_two
VDIC_web_form_address = VICIDiaL_web_form_address;
VDIC_web_form_address_two = VICIDiaL_web_form_address_two;
VDIC_web_form_address_three = VICIDiaL_web_form_address_three;
var VDIC_fronter='';
var VDIC_data_VDIG=check_VDIC_array[2].split("|");
@@ -8953,6 +9040,8 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
did_description = VDIC_data_VDIG[31];
closecallid = VDIC_data_VDIG[32];
xfercallid = VDIC_data_VDIG[33];
if (VDIC_data_VDIG[34].length > 5)
{VDIC_web_form_address_three = VDIC_data_VDIG[34];}
var VDIC_data_VDFR=check_VDIC_array[3].split("|");
if ( (VDIC_data_VDFR[1].length > 1) && (VDCL_fronter_display == 'Y') )
@@ -9283,6 +9372,16 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
TEMP_VDIC_web_form_address_two = URLDecode(VDIC_web_form_address_two,'YES','DEFAULT','2');
}
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
document.getElementById("WebFormSpan").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform.gif"); ?>\" border=\"0\" alt=\"Web Form\" /></a>\n";
@@ -9291,6 +9390,11 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_two + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormTwoRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" /></a>\n";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
if ( (LIVE_campaign_recording == 'ALLCALLS') || (LIVE_campaign_recording == 'ALLFORCE') )
{all_record = 'YES';}
@@ -9344,6 +9448,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (CalL_AutO_LauncH == 'WEBFORMTHREE')
{
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (useIE > 0)
{
@@ -9430,8 +9538,9 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
UpdatESettingSChecK = 1;
var VDIC_data_VDAC=check_VDIC_array[1].split("|");
VDIC_web_form_address = VICIDiaL_web_form_address
VDIC_web_form_address_two = VICIDiaL_web_form_address_two
VDIC_web_form_address = VICIDiaL_web_form_address;
VDIC_web_form_address_two = VICIDiaL_web_form_address_two;
VDIC_web_form_address_three = VICIDiaL_web_form_address_three;
var VDIC_fronter='';
var VDIC_data_VDIG=check_VDIC_array[2].split("|");
@@ -9512,6 +9621,8 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
did_description = VDIC_data_VDIG[31];
closecallid = VDIC_data_VDIG[32];
xfercallid = VDIC_data_VDIG[33];
if (VDIC_data_VDIG[34].length > 5)
{VDIC_web_form_address_three = VDIC_data_VDIG[34];}
var VDIC_data_VDFR=check_VDIC_array[3].split("|");
if ( (VDIC_data_VDFR[1].length > 1) && (VDCL_fronter_display == 'Y') )
@@ -9825,6 +9936,16 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
TEMP_VDIC_web_form_address_two = URLDecode(VDIC_web_form_address_two,'YES','DEFAULT','2');
}
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
document.getElementById("WebFormSpan").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform.gif"); ?>\" border=\"0\" alt=\"Web Form\" /></a>\n";
@@ -9832,6 +9953,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_two + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormTwoRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" /></a>\n";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH();\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
if ( (LIVE_campaign_recording == 'ALLCALLS') || (LIVE_campaign_recording == 'ALLFORCE') )
{all_record = 'YES';}
@@ -9886,6 +10011,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (CalL_AutO_LauncH == 'WEBFORMTHREE')
{
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (useIE > 0)
{
@@ -9930,6 +10059,7 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
document.getElementById("ScriptContents").innerHTML = '';
WebFormRefresH('','','1');
WebFormTwoRefresH('','','1');
WebFormThreeRefresH('','','1');
load_script_contents('ScriptContents','');
}
}
@@ -10027,6 +10157,51 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
}
// ################################################################################
// refresh the content of the third web form URL
function WebFormThreeRefresH(taskrefresh,submittask)
{
if (VDCL_group_id.length > 1)
{var group = VDCL_group_id;}
else
{var group = campaign;}
if ( (dialed_label.length < 2) || (dialed_label=='NONE') ) {dialed_label='MAIN';}
if (submittask != 'YES')
{
if (hide_gender < 1)
{
var genderIndex = document.getElementById("gender_list").selectedIndex;
var genderValue = document.getElementById('gender_list').options[genderIndex].value;
document.vicidial_form.gender.value = genderValue;
}
}
var regWFAcustom = new RegExp("^VAR","ig");
if (VDIC_web_form_address_three.match(regWFAcustom))
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','CUSTOM');
TEMP_VDIC_web_form_address_three = TEMP_VDIC_web_form_address_three.replace(regWFAcustom, '');
}
else
{
TEMP_VDIC_web_form_address_three = URLDecode(VDIC_web_form_address_three,'YES','DEFAULT','3');
}
if (enable_third_webform > 0)
{
if (taskrefresh == 'OUT')
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOver=\"WebFormThreeRefresH('IN');\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
else
{
document.getElementById("WebFormSpanThree").innerHTML = "<a href=\"" + TEMP_VDIC_web_form_address_three + "\" target=\"" + web_form_target + "\" onMouseOut=\"WebFormThreeRefresH('OUT');\"><img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" /></a>\n";
}
}
}
// ################################################################################
// Send hangup a second time from the dispo screen
function DispoHanguPAgaiN()
@@ -10221,6 +10396,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two_OFF.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" />";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three_OFF.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" />";
}
document.getElementById("ParkControl").innerHTML = "<img src=\"./images/<?php echo _QXZ("vdc_LB_parkcall_OFF.gif"); ?>\" border=\"0\" alt=\"Park Call\" />";
if ( (ivr_park_call=='ENABLED') || (ivr_park_call=='ENABLED_PARK_ONLY') )
{
@@ -10963,6 +11142,10 @@ function set_length(SLnumber,SLlength_goal,SLdirection)
{
document.getElementById("WebFormSpanTwo").innerHTML = "<img src=\"./images/<?php echo _QXZ("vdc_LB_webform_two_OFF.gif"); ?>\" border=\"0\" alt=\"Web Form 2\" />";
}
if (enable_third_webform > 0)
{
document.getElementById("WebFormSpanThree").innerHTML = "<img src=\"./images/<?php echo _QXZ("vdc_LB_webform_three_OFF.gif"); ?>\" border=\"0\" alt=\"Web Form 3\" />";
}
window.open(TEMP_VDIC_web_form_address, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
DispoSelect_submit();
@@ -12706,6 +12889,8 @@ else
{web_form_vars = web_form_varsX;}
if (webformnumber == '2')
{web_form_vars_two = web_form_varsX;}
if (webformnumber == '3')
{web_form_vars_three = web_form_varsX;}
var SCvendor_lead_code = encodeURIComponent(document.vicidial_form.vendor_lead_code.value);
var SCsource_id = source_id;
@@ -14146,6 +14331,11 @@ function phone_number_format(formatphone) {
WebFormTwoRefresH('NO','YES');
window.open(TEMP_VDIC_web_form_address_two, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (timer_action == 'WEBFORM3')
{
WebFormThreeRefresH('NO','YES');
window.open(TEMP_VDIC_web_form_address_three, web_form_target, 'toolbar=1,scrollbars=1,location=1,statusbar=1,menubar=1,resizable=1,width=640,height=450');
}
if (timer_action == 'D1_DIAL')
{
DtMf_PreSet_a_DiaL();
@@ -15546,6 +15736,8 @@ $zi=2;
<?php
if ($enable_second_webform > 0)
{echo "<span style=\"background-color: #FFFFFF\" id=\"WebFormSpanTwo\"><img src=\"./images/"._QXZ("vdc_LB_webform_two_OFF.gif")."\" border=\"0\" alt=\"Web Form 2\" /></span><br />\n";}
if ($enable_third_webform > 0)
{echo "<span style=\"background-color: #FFFFFF\" id=\"WebFormSpanThree\"><img src=\"./images/"._QXZ("vdc_LB_webform_three_OFF.gif")."\" border=\"0\" alt=\"Web Form 3\" /></span><br />\n";}
?>
<font class="body_small_bold"><span id="ParkCounterSpan"> &nbsp; </span></font><br />
<span style="background-color: <?php echo $MAIN_COLOR ?>" id="ParkControl"><img src="./images/<?php echo _QXZ("vdc_LB_parkcall_OFF.gif"); ?>" border="0" alt="Park Call" /></span><br />
File diff suppressed because one or more lines are too long
+11 -4
View File
@@ -43,6 +43,7 @@
# 150223-1548 - Added DYN option to am_message_exten
# 150307-2317 - Added custom meetme enter options
# 150404-0934 - Added enable_did_entry_list_id and related DID options
# 150428-1704 - Added enable_third_webform
#
require("dbconnect_mysqli.php");
@@ -50,7 +51,7 @@ require("functions.php");
#############################################
##### START SYSTEM_SETTINGS LOOKUP #####
$stmt = "SELECT use_non_latin,enable_queuemetrics_logging,enable_vtiger_integration,qc_features_active,outbound_autodial_active,sounds_central_control_active,enable_second_webform,user_territories_active,custom_fields_enabled,admin_web_directory,webphone_url,first_login_trigger,hosted_settings,default_phone_registration_password,default_phone_login_password,default_server_password,test_campaign_calls,active_voicemail_server,voicemail_timezones,default_voicemail_timezone,default_local_gmt,campaign_cid_areacodes_enabled,pllb_grouping_limit,did_ra_extensions_enabled,expanded_list_stats,contacts_enabled,alt_log_server_ip,alt_log_dbname,alt_log_login,alt_log_pass,tables_use_alt_log_db,call_menu_qualify_enabled,admin_list_counts,allow_voicemail_greeting,svn_revision,allow_emails,level_8_disable_add,pass_key,pass_hash_enabled,disable_auto_dial,country_code_list_stats,enable_languages,language_method FROM system_settings;";
$stmt = "SELECT use_non_latin,enable_queuemetrics_logging,enable_vtiger_integration,qc_features_active,outbound_autodial_active,sounds_central_control_active,enable_second_webform,user_territories_active,custom_fields_enabled,admin_web_directory,webphone_url,first_login_trigger,hosted_settings,default_phone_registration_password,default_phone_login_password,default_server_password,test_campaign_calls,active_voicemail_server,voicemail_timezones,default_voicemail_timezone,default_local_gmt,campaign_cid_areacodes_enabled,pllb_grouping_limit,did_ra_extensions_enabled,expanded_list_stats,contacts_enabled,alt_log_server_ip,alt_log_dbname,alt_log_login,alt_log_pass,tables_use_alt_log_db,call_menu_qualify_enabled,admin_list_counts,allow_voicemail_greeting,svn_revision,allow_emails,level_8_disable_add,pass_key,pass_hash_enabled,disable_auto_dial,country_code_list_stats,enable_languages,language_method,enable_third_webform FROM system_settings;";
$rslt=mysql_to_mysqli($stmt, $link);
if ($DB) {echo "$stmt\n";}
$qm_conf_ct = mysqli_num_rows($rslt);
@@ -100,6 +101,7 @@ if ($qm_conf_ct > 0)
$SScountry_code_list_stats = $row[40];
$SSenable_languages = $row[41];
$SSlanguage_method = $row[42];
$SSenable_third_webform = $row[43];
}
##### END SETTINGS LOOKUP #####
###########################################
@@ -1756,7 +1758,7 @@ if ($SSqc_features_active > 0)
<BR>
<A NAME="campaigns-na_call_url">
<BR>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?> <?php echo _QXZ("Custom Fields are not available with this feature."); ?>
<BR>
<A NAME="campaigns-agent_allow_group_alias">
@@ -1912,7 +1914,7 @@ if ($SSqc_features_active > 0)
<BR>
<A NAME="lists-na_call_url">
<BR>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?> <?php echo _QXZ("Custom Fields are not available with this feature."); ?>
<BR>
<A NAME="lists-xferconf_a_dtmf">
@@ -2546,7 +2548,7 @@ if ($SSqc_features_active > 0)
<BR>
<A NAME="inbound_groups-na_call_url">
<BR>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?>
<B><?php echo _QXZ("No Agent Call URL"); ?> -</B><?php echo _QXZ("This web URL address is not seen by the agent, but if it is populated it is called every time a call that is not handled by an agent is hung up or transferred. Uses the same variables as the web form fields and scripts. dispo can be used to retrieve the system-defined disposition for the call. This URL can NOT be a relative path. Default is blank."); ?> <?php echo _QXZ("Custom Fields are not available with this feature."); ?>
<BR>
<A NAME="inbound_groups-default_group_alias">
@@ -4639,6 +4641,11 @@ FR_SPAC 00 00 00 00 00 - <?php echo _QXZ("France space separated phone number");
<BR>
<B><?php echo _QXZ("Enable Second Webform"); ?> -</B><?php echo _QXZ("This setting allows you to have a second web form for campaigns and in-groups in the agent interface. Default is 0 for disabled."); ?>
<BR>
<A NAME="settings-enable_third_webform">
<BR>
<B><?php echo _QXZ("Enable Third Webform"); ?> -</B><?php echo _QXZ("This setting allows you to have a third web form for campaigns and in-groups in the agent interface. Default is 0 for disabled."); ?>
<BR>
<A NAME="settings-enable_tts_integration">
<BR>
+33 -4
View File
@@ -95,10 +95,11 @@
# 150217-1404 - archive deleted callbacks to vicidial_callbacks_archive table
# 150309-0250 - Added ability to use urlencoded web form addresses
# 150313-0818 - Allow for single quotes in vicidial_list and custom data fields
# 150428-1720 - Added web_form_address_three to add_list/update_list functions
#
$version = '2.12-71';
$build = '150313-0818';
$version = '2.12-72';
$build = '150428-1720';
$api_url_log = 0;
$startMS = microtime();
@@ -283,6 +284,8 @@ if (isset($_GET["web_form_address"])) {$web_form_address=$_GET["web_form_addre
elseif (isset($_POST["web_form_address"])) {$web_form_address=$_POST["web_form_address"];}
if (isset($_GET["web_form_address_two"])) {$web_form_address_two=$_GET["web_form_address_two"];}
elseif (isset($_POST["web_form_address_two"])) {$web_form_address_two=$_POST["web_form_address_two"];}
if (isset($_GET["web_form_address_three"])) {$web_form_address_three=$_GET["web_form_address_three"];}
elseif (isset($_POST["web_form_address_three"])) {$web_form_address_three=$_POST["web_form_address_three"];}
if (isset($_GET["reset_list"])) {$reset_list=$_GET["reset_list"];}
elseif (isset($_POST["reset_list"])) {$reset_list=$_POST["reset_list"];}
if (isset($_GET["delete_list"])) {$delete_list=$_GET["delete_list"];}
@@ -3474,6 +3477,7 @@ if ($function == 'update_list')
$ammessageSQL='';
$webformSQL='';
$webformtwoSQL='';
$webformthreeSQL='';
$resettimeSQL='';
$expiration_dateSQL='';
if (strlen($campaign_id) > 0)
@@ -3668,8 +3672,20 @@ if ($function == 'update_list')
else
{$webformtwoSQL = " ,web_form_address_two='$web_form_address_two'";}
}
if (strlen($web_form_address_three) > 0)
{
if (preg_match("/%3A%2F%2F/",$web_form_address_three))
{
$web_form_address_three = urldecode($web_form_address_three);
$web_form_address_three = preg_replace("/ /",'+',$web_form_address_three);
}
if ($web_form_address_three == '--BLANK--')
{$webformthreeSQL = " ,web_form_address_three=''";}
else
{$webformthreeSQL = " ,web_form_address_three='$web_form_address_three'";}
}
$updateSQL = "$webformtwoSQL$webformSQL$ammessageSQL$outboundcidSQL$activeSQL$listnameSQL$campaignSQL$scriptSQL$dropingroupSQL$resettimeSQL$expiration_dateSQL";
$updateSQL = "$webformthreeSQL$webformtwoSQL$webformSQL$ammessageSQL$outboundcidSQL$activeSQL$listnameSQL$campaignSQL$scriptSQL$dropingroupSQL$resettimeSQL$expiration_dateSQL";
if (strlen($updateSQL)< 3)
{
@@ -3983,6 +3999,7 @@ if ($function == 'add_list')
}
$webformSQL='';
$webformtwoSQL='';
$webformthreeSQL='';
if (strlen($web_form_address) > 0)
{
if (preg_match("/%3A%2F%2F/",$web_form_address))
@@ -4007,10 +4024,22 @@ if ($function == 'add_list')
else
{$webformtwoSQL = " ,web_form_address_two='$web_form_address_two'";}
}
if (strlen($web_form_address_three) > 0)
{
if (preg_match("/%3A%2F%2F/",$web_form_address_three))
{
$web_form_address_three = urldecode($web_form_address_three);
$web_form_address_three = preg_replace("/ /",'+',$web_form_address_three);
}
if ($web_form_address_three == '--BLANK--')
{$webformthreeSQL = " ,web_form_address_three=''";}
else
{$webformthreeSQL = " ,web_form_address_three='$web_form_address_three'";}
}
if (strlen($active)<1) {$active='N';}
if (strlen($expiration_date)<10) {$expiration_date='2099-12-31';}
$stmt="INSERT INTO vicidial_lists SET list_id='$list_id', list_name='$list_name', campaign_id='$campaign_id', active='$active', campaign_cid_override='$outbound_cid', agent_script_override='$script', am_message_exten_override='$am_message', drop_inbound_group_override='$drop_inbound_group', reset_time='$reset_time', expiration_date='$expiration_date' $webformSQL $webformtwoSQL;";
$stmt="INSERT INTO vicidial_lists SET list_id='$list_id', list_name='$list_name', campaign_id='$campaign_id', active='$active', campaign_cid_override='$outbound_cid', agent_script_override='$script', am_message_exten_override='$am_message', drop_inbound_group_override='$drop_inbound_group', reset_time='$reset_time', expiration_date='$expiration_date' $webformSQL $webformtwoSQL $webformthreeSQL;";
$rslt=mysql_to_mysqli($stmt, $link);
if ($DB) {echo "|$stmt|\n";}