$shopid, 'language_translation_id' => $current_language_id); $content = assistant_api_call('/getShopData', $data, 'get'); if (isset($_POST['btnAdd'])) { if (!isset($_POST['accessibility_lang_nonce']) || !wp_verify_nonce(wp_unslash(sanitize_key($_POST['accessibility_lang_nonce'])), 'accessibility_lang_nonce')) { print 'Sorry, You can not update....'; exit; } else { $widget_enable = 0; $keyboard_nav = $cursor = $big_cursor = $reading_guide = $desaturate = $contrast = $invert_contrast = $dark_contrast = $light_contrast = $bigger_text = $highlight_links = $reset_all = $alignment = $invert_contrast = ""; $error = array(); if (isset($_POST['keyboard_nav'])) { $keyboard_nav = sanitize_text_field(wp_unslash($_POST['keyboard_nav'])); if (empty($keyboard_nav)) { $error[] = "Keybaord shoud not empty."; } } if (isset($_POST['big_cursor'])) { $big_cursor = sanitize_text_field(wp_unslash($_POST['big_cursor'])); if (empty($big_cursor)) { $error[] = "Big Cursor should not be empty."; } } if (isset($_POST['reading_guide'])) { $reading_guide = sanitize_text_field(wp_unslash($_POST['reading_guide'])); if (empty($reading_guide)) { $error[] = "Reading Guide Color should not be empty."; } } if (isset($_POST['high_saturation'])) { $high_saturation = sanitize_text_field(wp_unslash($_POST['high_saturation'])); if (empty($high_saturation)) { $error[] = "High saturation should not be empty."; } } if (isset($_POST['low_saturation'])) { $low_saturation = sanitize_text_field(wp_unslash($_POST['low_saturation'])); if (empty($low_saturation)) { $error[] = "Low saturation should not be empty."; } } if (isset($_POST['desaturate'])) { $desaturate = sanitize_text_field(wp_unslash($_POST['desaturate'])); if (empty($desaturate)) { $error[] = "Desaturate should not be empty."; } } if (isset($_POST['invert_colors'])) { $invert_contrast = sanitize_text_field(wp_unslash($_POST['invert_colors'])); if (empty($invert_contrast)) { $error[] = "Invert Colors should not be empty."; } } if (isset($_POST['dark_contrast'])) { $dark_contrast = sanitize_text_field(wp_unslash($_POST['dark_contrast'])); if (empty($dark_contrast)) { $error[] = "Dark Contrast should not be empty."; } } if (isset($_POST['light_contrast'])) { $light_contrast = sanitize_text_field(wp_unslash($_POST['light_contrast'])); if (empty($light_contrast)) { $error[] = "Light Contrast should not be empty."; } } if (isset($_POST['bigger_text'])) { $bigger_text = sanitize_text_field(wp_unslash($_POST['bigger_text'])); if (empty($bigger_text)) { $error[] = "Bigger Text should not be empty."; } } if (isset($_POST['highlight_links'])) { $highlight_links = sanitize_text_field(wp_unslash($_POST['highlight_links'])); if (empty($highlight_links)) { $error[] = "Highlight Links should not be empty."; } } if (isset($_POST['word_spacing'])) { $word_spacing = sanitize_text_field(wp_unslash($_POST['word_spacing'])); if (empty($word_spacing)) { $error[] = "Word Spacing should not be empty."; } } if (isset($_POST['letter_spacing'])) { $letter_spacing = sanitize_text_field(wp_unslash($_POST['letter_spacing'])); if (empty($letter_spacing)) { $error[] = "Letter Spacing should not be empty."; } } if (isset($_POST['line_height'])) { $line_height = sanitize_text_field(wp_unslash($_POST['line_height'])); if (empty($line_height)) { $error[] = "Line Height should not be empty."; } } if (isset($_POST['left_alignment'])) { $left_alignment = sanitize_text_field(wp_unslash($_POST['left_alignment'])); if (empty($left_alignment)) { $error[] = "Left Alignment should not be empty."; } } if (isset($_POST['right_alignment'])) { $right_alignment = sanitize_text_field(wp_unslash($_POST['right_alignment'])); if (empty($right_alignment)) { $error[] = "Alignment should not be empty."; } } if (isset($_POST['center'])) { $center = sanitize_text_field(wp_unslash($_POST['center'])); if (empty($center)) { $error[] = "Center should not be empty."; } } if (isset($_POST['readable_fonts'])) { $readable_fonts = sanitize_text_field(wp_unslash($_POST['readable_fonts'])); if (empty($readable_fonts)) { $error[] = "Readable Fonts should not be empty."; } } if (isset($_POST['reading_mask'])) { $reading_mask = sanitize_text_field(wp_unslash($_POST['reading_mask'])); if (empty($reading_mask)) { $error[] = "Reading Mask should not be empty."; } } if (isset($_POST['highlight_titles'])) { $highlight_titles = sanitize_text_field(wp_unslash($_POST['highlight_titles'])); if (empty($highlight_titles)) { $error[] = "Highlight Titles should not be empty."; } } if (isset($_POST['text_magnifier'])) { $text_enhancer = sanitize_text_field(wp_unslash($_POST['text_magnifier'])); if (empty($text_enhancer)) { $error[] = "Text Enhancer should not be empty."; } } if (isset($_POST['image_alt_tooltip'])) { $image_alt_tooltip = sanitize_text_field(wp_unslash($_POST['image_alt_tooltip'])); if (empty($image_alt_tooltip)) { $error[] = "Image Alt Tooltip should not be empty."; } } if (isset($_POST['image_hide'])) { $image_hide = sanitize_text_field(wp_unslash($_POST['image_hide'])); if (empty($image_hide)) { $error[] = "Image Hide should not be empty."; } } if (isset($_POST['video_hide'])) { $video_hide = sanitize_text_field(wp_unslash($_POST['video_hide'])); if (empty($video_hide)) { $error[] = "Video Hide should not be empty."; } } if (isset($_POST['stop_animation'])) { $stop_animation = sanitize_text_field(wp_unslash($_POST['stop_animation'])); if (empty($stop_animation)) { $error[] = "Stop Animation should not be empty."; } } if (isset($_POST['text_speech'])) { $text_speech = sanitize_text_field(wp_unslash($_POST['text_speech'])); if (empty($text_speech)) { $error[] = "Text Speech should not be empty."; } } if (isset($_POST['accessibility_assistant'])) { $accessibility_assistant = sanitize_text_field(wp_unslash($_POST['accessibility_assistant'])); if (empty($accessibility_assistant)) { $error[] = "Accessibility Assistant should not be empty."; } } if (isset($_POST['reset_all'])) { $reset_all = sanitize_text_field(wp_unslash($_POST['reset_all'])); if (empty($reset_all)) { $error[] = "Reset All should not be empty."; } } if (isset($_POST['statement'])) { $statement = sanitize_text_field(wp_unslash($_POST['statement'])); if (empty($statement)) { $error[] = "Statement should not be empty."; } } if (isset($_POST['hide_interface'])) { $hide_interface = sanitize_text_field(wp_unslash($_POST['hide_interface'])); if (empty($hide_interface)) { $error[] = "Hide Interface should not be empty."; } } $visible_lang_switcher = "off"; if (isset($_POST['visible_lang_switcher'])) { $widget_enable = sanitize_text_field(wp_unslash($_POST['visible_lang_switcher'])); if ($widget_enable == "on") { $visible_lang_switcher = "on"; } } $default_language_switcher = "off"; if (isset($_POST['default_language_switcher'])) { $widget_enable = sanitize_text_field(wp_unslash($_POST['default_language_switcher'])); if ($widget_enable == "on") { $default_language_switcher = "on"; } } if (empty($error)) { $send_data = array( 'language_id' => $current_language_id, 'shop_id' => $shop_id, 'is_default' => $default_language_switcher, 'is_visible' => $visible_lang_switcher, 'keyboard_nav' => $keyboard_nav, 'big_cursor' => $big_cursor, 'reading_guide' => $reading_guide, 'high_saturation' => $high_saturation, 'low_saturation' => $low_saturation, 'desaturate' => $desaturate, 'invert_colors' => $invert_contrast, 'dark_contrast' => $dark_contrast, 'light_contrast' => $light_contrast, 'bigger_text' => $bigger_text, 'highlight_links' => $highlight_links, 'word_spacing' => $word_spacing, 'letter_spacing' => $letter_spacing, 'line_height' => $line_height, //'alignment' => $_POST['alignment'], 'left_alignment' => $left_alignment, 'right_alignment' => $right_alignment, 'center' => $center, 'readable_fonts' => $readable_fonts, 'reading_mask' => $reading_mask, 'highlight_titles' => $highlight_titles, 'text_magnifier' => $text_enhancer, 'image_alt_tooltip' => $image_alt_tooltip, 'image_hide' => $image_hide, 'video_hide' => $video_hide, 'stop_animation' => $stop_animation, 'text_speech' => $text_speech, 'accessibility_assistant' => $accessibility_assistant, 'reset_all' => $reset_all, 'statement' => $statement, 'hide_interface' => $hide_interface, ); } else { echo '
Accessibility by CartCoders
pages / Settings
Settings