From 32f4b5dc6d085951f859b8957cc175df64dc3097 Mon Sep 17 00:00:00 2001 From: mattf Date: Tue, 4 Sep 2018 16:09:13 +0000 Subject: [PATCH] rollback of vdc_script_display.php per issue #1126 git-svn-id: svn://192.168.202.10@3024 3d104415-ff17-0410-8863-d5cf3c621b8a --- agc_2-X/trunk/www/agc/vdc_script_display.php | 395 +++++++++---------- 1 file changed, 180 insertions(+), 215 deletions(-) diff --git a/agc_2-X/trunk/www/agc/vdc_script_display.php b/agc_2-X/trunk/www/agc/vdc_script_display.php index ac4bf4e5..3480ba98 100644 --- a/agc_2-X/trunk/www/agc/vdc_script_display.php +++ b/agc_2-X/trunk/www/agc/vdc_script_display.php @@ -39,11 +39,10 @@ # 171126-1124 - Added email message display from inbound emails only # 180224-1406 - Added LOGINvar variables, and options.php $INSERT_ variables # 180327-1356 - Added code for LOCALFQDN conversion to browser-used server URL for script iframes -# 180628-2200 - Patch for proper url encoding of variables replaced when within href and src attributes # -$version = '2.14-34'; -$build = '180628-2200'; +$version = '2.14-33'; +$build = '180224-1406'; require_once("dbconnect_mysqli.php"); require_once("functions.php"); @@ -419,221 +418,187 @@ $script_name = $row[0]; $script_text = stripslashes($row[1]); $script_color = $row[2]; -# ADD NEW PATTERNS/ATTRIBUTES TO MATCH HERE AS NEEDED. -# PATTERN ENTRY MUST MATCH CORRESPONDING INDEX IN ATTRIBUTE ARRAY TO WORK PROPERLY. -# FOR EXAMPLE, an IFRAME SRC or A HREF tag -$pattern_array=array("/\]+)\>/i", "/\]+)\>/i"); -$attribute_array=array("/src=[\"|\']([^\"\']+)[\"|\']/i", "/href=[\"|\']([^\"\']+)[\"|\']/i"); - -for($x=0; $x0) + if ($IFRAMEencode=='1') { - $user = preg_replace('/\s/i','+',$user); - $pass = preg_replace('/\s/i','+',$orig_pass); - $lead_id_URL = urlencode(trim($lead_id)); - $vendor_id_URL = urlencode(trim($vendor_id)); - $vendor_lead_code_URL = urlencode(trim($vendor_lead_code)); - $list_id_URL = urlencode(trim($list_id)); - $list_name_URL = urlencode(trim($list_name)); - $list_description_URL = urlencode(trim($list_description)); - $gmt_offset_now_URL = urlencode(trim($gmt_offset_now)); - $phone_code_URL = urlencode(trim($phone_code)); - $phone_number_URL = urlencode(trim($phone_number)); - $title_URL = urlencode(trim($title)); - $first_name_URL = urlencode(trim($first_name)); - $middle_initial_URL = urlencode(trim($middle_initial)); - $last_name_URL = urlencode(trim($last_name)); - $address1_URL = urlencode(trim($address1)); - $address2_URL = urlencode(trim($address2)); - $address3_URL = urlencode(trim($address3)); - $city_URL = urlencode(trim($city)); - $state_URL = urlencode(trim($state)); - $province_URL = urlencode(trim($province)); - $postal_code_URL = urlencode(trim($postal_code)); - $country_code_URL = urlencode(trim($country_code)); - $gender_URL = urlencode(trim($gender)); - $date_of_birth_URL = urlencode(trim($date_of_birth)); - $alt_phone_URL = urlencode(trim($alt_phone)); - $email_URL = urlencode(trim($email)); - $security_phrase_URL = urlencode(trim($security_phrase)); - $comments_URL = urlencode(trim($comments)); - $campaign_URL = urlencode(trim($campaign)); - $phone_login_URL = urlencode(trim($phone_login)); - $original_phone_login_URL = urlencode(trim($original_phone_login)); - $phone_pass_URL = urlencode(trim($phone_pass)); - $fronter_URL = urlencode(trim($fronter)); - $closer_URL = urlencode(trim($closer)); - $group_URL = urlencode(trim($group)); - $channel_group_URL = urlencode(trim($channel_group)); - $SQLdate_URL = urlencode(trim($SQLdate)); - $epoch_URL = urlencode(trim($epoch)); - $uniqueid_URL = urlencode(trim($uniqueid)); - $customer_zap_channel_URL = urlencode(trim($customer_zap_channel)); - $customer_server_ip_URL = urlencode(trim($customer_server_ip)); - $server_ip_URL = urlencode(trim($server_ip)); - $SIPexten_URL = urlencode(trim($SIPexten)); - $session_id_URL = urlencode(trim($session_id)); - $phone_URL = urlencode(trim($phone)); - $parked_by_URL = urlencode(trim($parked_by)); - $dispo_URL = urlencode(trim($dispo)); - $dialed_number_URL = urlencode(trim($dialed_number)); - $dialed_label_URL = urlencode(trim($dialed_label)); - $source_id_URL = urlencode(trim($source_id)); - $rank_URL = urlencode(trim($rank)); - $owner_URL = urlencode(trim($owner)); - $camp_script_URL = urlencode(trim($camp_script)); - $in_script_URL = urlencode(trim($in_script)); - $script_width_URL = urlencode(trim($script_width)); - $script_height_URL = urlencode(trim($script_height)); - $fullname_URL = urlencode(trim($fullname)); - $agent_email_URL = urlencode(trim($agent_email)); - $recording_filename_URL = urlencode(trim($recording_filename)); - $recording_id_URL = urlencode(trim($recording_id)); - $user_custom_one_URL = urlencode(trim($user_custom_one)); - $user_custom_two_URL = urlencode(trim($user_custom_two)); - $user_custom_three_URL = urlencode(trim($user_custom_three)); - $user_custom_four_URL = urlencode(trim($user_custom_four)); - $user_custom_five_URL = urlencode(trim($user_custom_five)); - $preset_number_a_URL = urlencode(trim($preset_number_a)); - $preset_number_b_URL = urlencode(trim($preset_number_b)); - $preset_number_c_URL = urlencode(trim($preset_number_c)); - $preset_number_d_URL = urlencode(trim($preset_number_d)); - $preset_number_e_URL = urlencode(trim($preset_number_e)); - $preset_number_f_URL = urlencode(trim($preset_number_f)); - $preset_dtmf_a_URL = urlencode(trim($preset_dtmf_a)); - $preset_dtmf_b_URL = urlencode(trim($preset_dtmf_b)); - $did_id_URL = urlencode(trim($did_id)); - $did_extension_URL = urlencode(trim($did_extension)); - $did_pattern_URL = urlencode(trim($did_pattern)); - $did_description_URL = urlencode(trim($did_description)); - $called_count_URL = urlencode(trim($called_count)); - $session_name_URL = urlencode(trim($session_name)); - $entry_date_URL = urlencode(trim($entry_date)); - $did_custom_one_URL = urlencode(trim($did_custom_one)); - $did_custom_two_URL = urlencode(trim($did_custom_two)); - $did_custom_three_URL = urlencode(trim($did_custom_three)); - $did_custom_four_URL = urlencode(trim($did_custom_four)); - $did_custom_five_URL = urlencode(trim($did_custom_five)); - $web_vars_URL = urlencode(trim($web_vars)); - - $iframe_replace=$iframe_matches[1]; - - for ($q=0; $q