<?php

session_start();
include 'assets/includes/db.php';
include 'assets/includes/config.php';

if ($_ERRORS) {
	error_reporting(E_ALL);
	ini_set('display_errors', 1);
}
if (!isset($_SESSION['loggedin']) && !$_SESSION['loggedin']) {
	header('location: logout.php');
}

if (isset($_POST['submit_settings'])) {
	$sql = 'UPDATE xc_xciptv_app SET ';
	$sql .= 'login_type = "' . $_POST['switch-login-type-misc'] . '", ';
	$sql .= 'portal = "' . $_POST['portal-one-dns'] . '",';
	$sql .= 'portal2 = "' . $_POST['portal-two-dns'] . '", ';
	$sql .= 'portal3 = "' . $_POST['portal-three-dns'] . '", ';
	$sql .= 'portal4 = "' . $_POST['portal-four-dns'] . '", ';
	$sql .= 'portal5 = "' . $_POST['portal-five-dns'] . '", ';
	$sql .= 'portal_name = "' . $_POST['portal-one-name'] . '", ';
	$sql .= 'portal2_name = "' . $_POST['portal-two-name'] . '", ';
	$sql .= 'portal3_name = "' . $_POST['portal-three-name'] . '", ';
	$sql .= 'portal4_name = "' . $_POST['portal-four-name'] . '", ';
	$sql .= 'portal5_name = "' . $_POST['portal-five-name'] . '", ';
	$sql .= 'portal_vod = "' . $_POST['switch-extra-vod-misc'] . '", ';
	$sql .= 'portal_series = "' . $_POST['switch-extra-series-misc'] . '", ';
	$sql .= 'support_email = "' . $_POST['switch-support-1-misc'] . '", ';
	$sql .= 'support_phone = "' . $_POST['switch-support-2-misc'] . '", ';
	$sql .= 'btn_live = "' . (isset($_POST['switch-livetv-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_live2 = "' . (isset($_POST['switch-livetv-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_live3 = "' . (isset($_POST['switch-livetv-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_live4 = "' . (isset($_POST['switch-livetv-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_live5 = "' . (isset($_POST['switch-livetv-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_vod = "' . (isset($_POST['switch-vod-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_vod2 = "' . (isset($_POST['switch-vod-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_vod3 = "' . (isset($_POST['switch-vod-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_vod4 = "' . (isset($_POST['switch-vod-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_vod5 = "' . (isset($_POST['switch-vod-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_epg = "' . (isset($_POST['switch-tvguide-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_epg2 = "' . (isset($_POST['switch-tvguide-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_epg3 = "' . (isset($_POST['switch-tvguide-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_epg4 = "' . (isset($_POST['switch-tvguide-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_epg5 = "' . (isset($_POST['switch-tvguide-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_series = "' . (isset($_POST['switch-series-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_series2 = "' . (isset($_POST['switch-series-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_series3 = "' . (isset($_POST['switch-series-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_series4 = "' . (isset($_POST['switch-series-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_series5 = "' . (isset($_POST['switch-series-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_radio = "' . (isset($_POST['switch-radio-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_radio2 = "' . (isset($_POST['switch-radio-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_radio3 = "' . (isset($_POST['switch-radio-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_radio4 = "' . (isset($_POST['switch-radio-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_radio5 = "' . (isset($_POST['switch-radio-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_catchup = "' . (isset($_POST['switch-catchup-one']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_catchup2 = "' . (isset($_POST['switch-catchup-two']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_catchup3 = "' . (isset($_POST['switch-catchup-three']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_catchup4 = "' . (isset($_POST['switch-catchup-four']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_catchup5 = "' . (isset($_POST['switch-catchup-five']) ? 'Yes' : 'No') . '", ';
	$sql .= 'btn_account = "' . (isset($_POST['switch-account-one']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_account2 = "' . (isset($_POST['switch-account-two']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_account3 = "' . (isset($_POST['switch-account-three']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_pr = "' . (isset($_POST['switch-reminders-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_rec = "' . (isset($_POST['switch-recordings-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_vpn = "' . (isset($_POST['switch-vpn-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_noti = "' . (isset($_POST['switch-messages-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_update = "' . (isset($_POST['switch-update-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_login_setting = "' . (isset($_POST['switch-service-select-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'show_expire = "' . (isset($_POST['switch-expiry-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'stream_type = "' . $_POST['switch-output-format-misc'] . '", ';
	$sql .= 'player = "' . $_POST['switch-player-misc'] . '", ';
	$sql .= 'player_tv = "' . $_POST['switch-player-tv-misc'] . '", ';
	$sql .= 'player_vod = "' . $_POST['switch-player-vod-misc'] . '", ';
	$sql .= 'player_series = "' . $_POST['switch-player-series-misc'] . '", ';
	$sql .= 'player_catchup = "' . $_POST['switch-player-catchup-misc'] . '", ';
	$sql .= 'message_enable = "' . (isset($_POST['switch-messages-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'announcement_enabled = "' . (isset($_POST['switch-announcements-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'updateuserinfo_enabled = "' . (isset($_POST['switch-user-info-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'ms = "' . (isset($_POST['switch-multiscreen-one']) ? 'yes' : 'no') . '", ';
	$sql .= 'ms2 = "' . (isset($_POST['switch-multiscreen-two']) ? 'yes' : 'no') . '", ';
	$sql .= 'ms3 = "' . (isset($_POST['switch-multiscreen-three']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_fav = "' . (isset($_POST['switch-favourites-one']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_fav2 = "' . (isset($_POST['switch-favourites-two']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_fav3 = "' . (isset($_POST['switch-favourites-three']) ? 'yes' : 'no') . '", ';
	$sql .= 'btn_signup = "' . (isset($_POST['switch-signup-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'epg_url = "' . $_POST['switch-extra-epg-misc'] . '", ';
	$sql .= 'ovpn_url = "' . (isset($_POST['switch-multi-vpn-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'show_cat_count = "' . (isset($_POST['switch-category-count-misc']) ? 'yes' : 'no') . '", ';
	$sql .= 'activation_url = "' . $_POST['switch-signup-link-misc'] . '";';
	$sqlite3->exec($sql);
	header('Location: ottrunxciptv_application.php');
}

echo '<!doctype html>' . "\r\n" . '<html lang="en">' . "\r\n\r\n" . '<head>' . "\r\n\r\n" . '    ';
include 'assets/includes/title-meta.php';
echo "\r\n" . '    ';
include 'assets/includes/head-css.php';
echo "\r\n" . '</head>' . "\r\n\r\n" . '<body data-sidebar="dark">' . "\r\n\r\n" . '    <!-- Loader -->' . "\r\n" . '    <div id="preloader">' . "\r\n" . '        <div id="status">' . "\r\n" . '            <div class="spinner">' . "\r\n" . '                <i class="ri-loader-line spin-icon"></i>' . "\r\n" . '            </div>' . "\r\n" . '        </div>' . "\r\n" . '    </div>' . "\r\n\r\n" . '    <div id="layout-wrapper">' . "\r\n\r\n" . '        ';
include 'assets/includes/topbar.php';
echo "\r\n" . '        ';
include 'assets/includes/sidebar.php';
echo "\r\n" . '        <div class="main-content">' . "\r\n\r\n" . '            <div class="page-content">' . "\r\n" . '                <div class="container-fluid">' . "\r\n\r\n" . '                    <div class="row">' . "\r\n" . '                        <div class="col-12">' . "\r\n" . '                            <div class="page-title-box d-flex align-items-center justify-content-between">' . "\r\n" . '                                <h4 class="mb-0"> </h4>' . "\r\n\r\n" . '                                <div class="page-title-right">' . "\r\n" . '                                    <ol class="breadcrumb m-0">' . "\r\n" . '                                        <li class="breadcrumb-item"><a href="javascript: void(0);">OTTRun XCIPTV</a></li>' . "\r\n" . '                                        <li class="breadcrumb-item"><a href="javascript: void(0);">Configuration</a></li>' . "\r\n" . '                                        <li class="breadcrumb-item active">Application</li>' . "\r\n" . '                                    </ol>' . "\r\n" . '                                </div>' . "\r\n\r\n" . '                            </div>' . "\r\n" . '                        </div>' . "\r\n" . '                    </div>' . "\r\n\r\n" . '                    <div class="row">' . "\r\n" . '                        <div class="col-12">' . "\r\n" . '                            <div class="card">' . "\r\n" . '                                <div class="card-body">' . "\r\n\r\n" . '                                    <form method="POST" action="ottrunxciptv_application.php">' . "\r\n\r\n" . '                                        <h4 class="card-title">Active Service List</h4>' . "\r\n" . '                                        <p class="card-title-desc">Add New Services to your OTTRun XCIPTV applications.</p>' . "\r\n\r\n" . '                                        <br />' . "\r\n" . '                                        <div id="basic-pills-wizard" class="twitter-bs-wizard">' . "\r\n" . '                                            <ul class="twitter-bs-wizard-nav">' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-one" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">01</span>' . "\r\n" . '                                                        <span class="step-title">';
echo $xciptv_app_data['portal_name'];
echo '</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-two" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">02</span>' . "\r\n" . '                                                        <span class="step-title">';
echo $xciptv_app_data['portal2_name'];
echo '</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-three" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">03</span>' . "\r\n" . '                                                        <span class="step-title">';
echo $xciptv_app_data['portal3_name'];
echo '</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-four" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">04</span>' . "\r\n" . '                                                        <span class="step-title">';
echo $xciptv_app_data['portal4_name'];
echo '</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-five" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">05</span>' . "\r\n" . '                                                        <span class="step-title">';
echo $xciptv_app_data['portal5_name'];
echo '</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                                <li class="nav-item">' . "\r\n" . '                                                    <a href="#portal-misc" class="nav-link" data-toggle="tab">' . "\r\n" . '                                                        <span class="step-number">@</span>' . "\r\n" . '                                                        <span class="step-title">ALL</span>' . "\r\n" . '                                                    </a>' . "\r\n" . '                                                </li>' . "\r\n" . '                                            </ul>' . "\r\n" . '                                            <div class="tab-content twitter-bs-wizard-tab-content">' . "\r\n" . '                                                <div class="tab-pane" id="portal-one">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-one-name">Service Name</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-one-name" name="portal-one-name" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal_name'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-one-dns">Service DNS</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-one-dns" name="portal-one-dns" placeholder="Enter service dns" value="';
echo $xciptv_app_data['portal'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-livetv-one">Display LIVE TV button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-livetv-one" name="switch-livetv-one" switch="bool" ';
echo $xciptv_app_data['btn_live'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-livetv-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-tvguide-one">Display TV GUIDE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-tvguide-one" name="switch-tvguide-one" switch="bool" ';
echo $xciptv_app_data['btn_epg'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-tvguide-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vod-one">Display VOD button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vod-one" name="switch-vod-one" switch="bool" ';
echo $xciptv_app_data['btn_vod'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vod-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-series-one">Display SERIES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-series-one" name="switch-series-one" switch="bool" ';
echo $xciptv_app_data['btn_series'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-series-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-catchup-one">Display CATCHUP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-catchup-one" name="switch-catchup-one" switch="bool" ';
echo $xciptv_app_data['btn_catchup'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-catchup-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-radio-one">Display RADIO button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-radio-one" name="switch-radio-one" switch="bool" ';
echo $xciptv_app_data['btn_radio'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-radio-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-multiscreen-one">Display MULTISCREEN button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-multiscreen-one" name="switch-multiscreen-one" switch="bool" ';
echo $xciptv_app_data['ms'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-multiscreen-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-favourites-one">Display FAVOURITES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-favourites-one" name="switch-favourites-one" switch="bool" ';
echo $xciptv_app_data['btn_fav'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-favourites-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-account-one">Display ACCOUNT button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-account-one" name="switch-account-one" switch="bool" ';
echo $xciptv_app_data['btn_account'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-account-one" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                </div>' . "\r\n" . '                                                <div class="tab-pane" id="portal-two">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-two-name">Service Name</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-two-name" name="portal-two-name" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal2_name'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-two-dns">Service DNS</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-two-dns" name="portal-two-dns" placeholder="Enter service dns" value="';
echo $xciptv_app_data['portal2'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-livetv-two">Display LIVE TV button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-livetv-two" name="switch-livetv-two" switch="bool" ';
echo $xciptv_app_data['btn_live2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-livetv-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-tvguide-two">Display TV GUIDE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-tvguide-two" name="switch-tvguide-two" switch="bool" ';
echo $xciptv_app_data['btn_epg2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-tvguide-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vod-two">Display VOD button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vod-two" name="switch-vod-two" switch="bool" ';
echo $xciptv_app_data['btn_vod2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vod-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-series-two">Display SERIES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-series-two" name="switch-series-two" switch="bool" ';
echo $xciptv_app_data['btn_series2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-series-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-catchup-two">Display CATCHUP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-catchup-two" name="switch-catchup-two" switch="bool" ';
echo $xciptv_app_data['btn_catchup2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-catchup-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-radio-two">Display RADIO button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-radio-two" name="switch-radio-two" switch="bool" ';
echo $xciptv_app_data['btn_radio2'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-radio-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-multiscreen-two">Display MULTISCREEN button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-multiscreen-two" name="switch-multiscreen-two" switch="bool" ';
echo $xciptv_app_data['ms2'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-multiscreen-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-favourites-two">Display FAVOURITES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-favourites-two" name="switch-favourites-two" switch="bool" ';
echo $xciptv_app_data['btn_fav2'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-favourites-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-account-two">Display ACCOUNT button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-account-two" name="switch-account-two" switch="bool" ';
echo $xciptv_app_data['btn_account2'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-account-two" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                </div>' . "\r\n" . '                                                <div class="tab-pane" id="portal-three">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-three-name">Service Name</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-three-name" name="portal-three-name" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal3_name'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-three-dns">Service DNS</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-three-dns" name="portal-three-dns" placeholder="Enter service dns" value="';
echo $xciptv_app_data['portal3'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-livetv-three">Display LIVE TV button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-livetv-three" name="switch-livetv-three" switch="bool" ';
echo $xciptv_app_data['btn_live3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-livetv-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-tvguide-three">Display TV GUIDE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-tvguide-three" name="switch-tvguide-three" switch="bool" ';
echo $xciptv_app_data['btn_epg3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-tvguide-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vod-three">Display VOD button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vod-three" name="switch-vod-three" switch="bool" ';
echo $xciptv_app_data['btn_vod3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vod-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-series-three">Display SERIES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-series-three" name="switch-series-three" switch="bool" ';
echo $xciptv_app_data['btn_series3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-series-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-catchup-three">Display CATCHUP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-catchup-three" name="switch-catchup-three" switch="bool" ';
echo $xciptv_app_data['btn_catchup3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-catchup-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-radio-three">Display RADIO button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-radio-three" name="switch-radio-three" switch="bool" ';
echo $xciptv_app_data['btn_radio3'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-radio-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-multiscreen-three">Display MULTISCREEN button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-multiscreen-three" name="switch-multiscreen-three" switch="bool" ';
echo $xciptv_app_data['ms3'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-multiscreen-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-favourites-three">Display FAVOURITES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-favourites-three" name="switch-favourites-three" switch="bool" ';
echo $xciptv_app_data['btn_fav3'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-favourites-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-account-three">Display ACCOUNT button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-account-three" name="switch-account-three" switch="bool" ';
echo $xciptv_app_data['btn_account3'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-account-three" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                </div>' . "\r\n" . '                                                <div class="tab-pane" id="portal-four">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-four-name">Service Name</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-four-name" name="portal-four-name" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal4_name'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-four-dns">Service DNS</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-four-dns" name="portal-four-dns" placeholder="Enter service dns" value="';
echo $xciptv_app_data['portal4'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-livetv-four">Display LIVE TV button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-livetv-four" name="switch-livetv-four" switch="bool" ';
echo $xciptv_app_data['btn_live4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-livetv-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-tvguide-four">Display TV GUIDE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-tvguide-four" name="switch-tvguide-four" switch="bool" ';
echo $xciptv_app_data['btn_epg4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-tvguide-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vod-four">Display VOD button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vod-four" name="switch-vod-four" switch="bool" ';
echo $xciptv_app_data['btn_vod4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vod-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-series-four">Display SERIES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-series-four" name="switch-series-four" switch="bool" ';
echo $xciptv_app_data['btn_series4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-series-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-catchup-four">Display CATCHUP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-catchup-four" name="switch-catchup-four" switch="bool" ';
echo $xciptv_app_data['btn_catchup4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-catchup-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-radio-four">Display RADIO button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-radio-four" name="switch-radio-four" switch="bool" ';
echo $xciptv_app_data['btn_radio4'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-radio-four" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                    </div>' . "\r\n" . '                                                </div>' . "\r\n\r\n" . '                                                <div class="tab-pane" id="portal-five">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-five-name">Service Name</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-five-name" name="portal-five-name" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal5_name'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="portal-five-dns">Service DNS</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="portal-five-dns" name="portal-five-dns" placeholder="Enter service dns" value="';
echo $xciptv_app_data['portal5'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-livetv-five">Display LIVE TV button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-livetv-five" name="switch-livetv-five" switch="bool" ';
echo $xciptv_app_data['btn_live5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-livetv-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-tvguide-five">Display TV GUIDE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-tvguide-five" name="switch-tvguide-five" switch="bool" ';
echo $xciptv_app_data['btn_epg5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-tvguide-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vod-five">Display VOD button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vod-five" name="switch-vod-five" switch="bool" ';
echo $xciptv_app_data['btn_vod5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vod-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-series-five">Display SERIES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-series-five" name="switch-series-five" switch="bool" ';
echo $xciptv_app_data['btn_series5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-series-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-catchup-five">Display CATCHUP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-catchup-five" name="switch-catchup-five" switch="bool" ';
echo $xciptv_app_data['btn_catchup5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-catchup-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-radio-five">Display RADIO button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-radio-five" name="switch-radio-five" switch="bool" ';
echo $xciptv_app_data['btn_radio5'] == 'Yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-radio-five" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                    </div>' . "\r\n" . '                                                </div>' . "\r\n\r\n" . '                                                <div class="tab-pane" id="portal-misc">' . "\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-4"></div>' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="alert alert-info text-center">' . "\r\n" . '                                                                Miscellaneous settings affecting all applications.<br />' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-4"></div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-reminders-misc">Display REMINDERS button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-reminders-misc" name="switch-reminders-misc" switch="bool" ';
echo $xciptv_app_data['btn_pr'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-reminders-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-recordings-misc">Display RECORDINGS button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-recordings-misc" name="switch-recordings-misc" switch="bool" ';
echo $xciptv_app_data['btn_rec'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-recordings-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-vpn-misc">Display VPN button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-vpn-misc" name="switch-vpn-misc" switch="bool" ';
echo $xciptv_app_data['btn_vpn'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-vpn-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-category-count-misc">Display CATEGORY COUNT text</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-category-count-misc" name="switch-category-count-misc" switch="bool" ';
echo $xciptv_app_data['show_cat_count'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-category-count-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-multi-vpn-misc">Allow MULTI-VPN option</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-multi-vpn-misc" name="switch-multi-vpn-misc" switch="bool" ';
echo $xciptv_app_data['ovpn_url'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-multi-vpn-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-user-messages-misc">Allow USER-MESSAGES in-app</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-user-messages-misc" name="switch-user-messages-misc" switch="bool" ';
echo $xciptv_app_data['message_enable'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-user-messages-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-user-info-misc">Allow USER-INFO in-app</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-user-info-misc" name="switch-user-info-misc" switch="bool" ';
echo $xciptv_app_data['updateuserinfo_enabled'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-user-info-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-messages-misc">Display MESSAGES button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-messages-misc" name="switch-messages-misc" switch="bool" ';
echo $xciptv_app_data['btn_noti'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-messages-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-update-misc">Display UPDATE button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-update-misc" name="switch-update-misc" switch="bool" ';
echo $xciptv_app_data['btn_update'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-update-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-expiry-misc">Display EXPIRY text</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-expiry-misc" name="switch-expiry-misc" switch="bool" ';
echo $xciptv_app_data['show_expire'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-expiry-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-service-select-misc">Display SERVICE-SELECT option</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-service-select-misc" name="switch-service-select-misc" switch="bool" ';
echo $xciptv_app_data['btn_login_setting'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-service-select-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-announcements-misc">Allow ANNOUNCEMENTS in-app</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-announcements-misc" name="switch-announcements-misc" switch="bool" ';
echo $xciptv_app_data['announcement_enabled'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-announcements-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-output-format-misc">Stream OUTPUT format</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <select class="custom-select" id="switch-output-format-misc" name="switch-output-format-misc">' . "\r\n" . '                                                                        <option value="ts" ';
echo $xciptv_app_data['stream_type'] == 'ts' ? 'selected' : '';
echo '>mpegts</option>' . "\r\n" . '                                                                        <option value="hls" ';
echo $xciptv_app_data['stream_type'] == 'hls' ? 'selected' : '';
echo '>hls</option>' . "\r\n" . '                                                                    </select>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-login-type-misc">Choose LOGIN format</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <select class="custom-select" id="switch-login-type-misc" name="switch-login-type-misc">' . "\r\n" . '                                                                        <option value="login" ';
echo $xciptv_app_data['login_type'] == 'login' ? 'selected' : '';
echo '>xc login</option>' . "\r\n" . '                                                                        <option value="mac" ';
echo $xciptv_app_data['login_type'] == 'mac' ? 'selected' : '';
echo '>mac address</option>' . "\r\n" . '                                                                        <option value="activation" ';
echo $xciptv_app_data['login_type'] == 'activation' ? 'selected' : '';
echo '>active code</option>' . "\r\n" . '                                                                    </select>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n\r\n\r\n\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-extra-vod-misc">Extra VOD source</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-extra-vod-misc" name="switch-extra-vod-misc" placeholder="Enter service name" value="';
echo $xciptv_app_data['portal_vod'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-extra-series-misc">Extra SERIES source</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-extra-series-misc" name="switch-extra-series-misc" placeholder="Enter extra series source" value="';
echo $xciptv_app_data['portal_series'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-4">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-extra-epg-misc">Extra EPG Source</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-extra-epg-misc" name="switch-extra-epg-misc" placeholder="Enter extra epg source" value="';
echo $xciptv_app_data['epg_url'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-signup-misc">Display SIGN-UP button</label>' . "\r\n" . '                                                                <div class="square-switch float-right">' . "\r\n" . '                                                                    <input type="checkbox" id="switch-signup-misc" name="switch-signup-misc" switch="bool" ';
echo $xciptv_app_data['btn_signup'] == 'yes' ? 'checked' : '';
echo ' />' . "\r\n" . '                                                                    <label for="switch-signup-misc" data-on-label="Yes" data-off-label="No"></label>' . "\r\n" . '                                                                </div>' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                            <label for="switch-signup-link-misc">SIGN-UP URL</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-signup-link-misc" name="switch-signup-link-misc" placeholder="Enter sign-up url" value="';
echo $xciptv_app_data['activation_url'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-support-1-misc">Support Line 1 (email)</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-support-1-misc" name="switch-support-1-misc" placeholder="Enter support line 1" value="';
echo $xciptv_app_data['support_email'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                        <div class="col-lg-6">' . "\r\n" . '                                                            <div class="form-group">' . "\r\n" . '                                                                <label for="switch-support-2-misc">Support Line 2 (phone)</label>' . "\r\n" . '                                                                <input type="text" class="form-control" id="switch-support-2-misc" name="switch-support-2-misc" placeholder="Enter support line 2" value="';
echo $xciptv_app_data['support_phone'];
echo '">' . "\r\n" . '                                                            </div>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="row">' . "\r\n" . '                                                        <div class="col-lg-12">' . "\r\n" . '                                                            <hr /><br />' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                    <div class="form-group">' . "\r\n" . '                                                        <label for="switch-player-misc">Player DEFAULT software</label>' . "\r\n" . '                                                        <div class="square-switch float-right">' . "\r\n" . '                                                            <select class="custom-select" id="switch-player-misc" name="switch-player-misc">' . "\r\n" . '                                                                <option value="EXO" ';
echo $xciptv_app_data['player'] == 'EXO' ? 'selected' : '';
echo '>Exo</option>' . "\r\n" . '                                                                <option value="VLC" ';
echo $xciptv_app_data['player'] == 'VLC' ? 'selected' : '';
echo '>VLC</option>' . "\r\n" . '                                                            </select>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                    <div class="form-group">' . "\r\n" . '                                                        <label for="switch-player-tv-misc">Player TV software</label>' . "\r\n" . '                                                        <div class="square-switch float-right">' . "\r\n" . '                                                            <select class="custom-select" id="switch-player-tv-misc" name="switch-player-tv-misc">' . "\r\n" . '                                                                <option value="EXO" ';
echo $xciptv_app_data['player_tv'] == 'EXO' ? 'selected' : '';
echo '>Exo</option>' . "\r\n" . '                                                                <option value="VLC" ';
echo $xciptv_app_data['player_tv'] == 'VLC' ? 'selected' : '';
echo '>VLC</option>' . "\r\n" . '                                                            </select>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                    <div class="form-group">' . "\r\n" . '                                                        <label for="switch-player-vod-misc">Player VOD software</label>' . "\r\n" . '                                                        <div class="square-switch float-right">' . "\r\n" . '                                                            <select class="custom-select" id="switch-player-vod-misc" name="switch-player-vod-misc">' . "\r\n" . '                                                                <option value="EXO" ';
echo $xciptv_app_data['player_vod'] == 'EXO' ? 'selected' : '';
echo '>Exo</option>' . "\r\n" . '                                                                <option value="VLC" ';
echo $xciptv_app_data['player_vod'] == 'VLC' ? 'selected' : '';
echo '>VLC</option>' . "\r\n" . '                                                            </select>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                    <div class="form-group">' . "\r\n" . '                                                        <label for="switch-player-series-misc">Player SERIES software</label>' . "\r\n" . '                                                        <div class="square-switch float-right">' . "\r\n" . '                                                            <select class="custom-select" id="switch-player-series-misc" name="switch-player-series-misc">' . "\r\n" . '                                                                <option value="EXO" ';
echo $xciptv_app_data['player_series'] == 'EXO' ? 'selected' : '';
echo '>Exo</option>' . "\r\n" . '                                                                <option value="VLC" ';
echo $xciptv_app_data['player_series'] == 'VLC' ? 'selected' : '';
echo '>VLC</option>' . "\r\n" . '                                                            </select>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n" . '                                                    <div class="form-group">' . "\r\n" . '                                                        <label for="switch-player-catchup-misc">Player CATCHUP software</label>' . "\r\n" . '                                                        <div class="square-switch float-right">' . "\r\n" . '                                                            <select class="custom-select" id="switch-player-catchup-misc" name="switch-player-catchup-misc">' . "\r\n" . '                                                                <option value="EXO" ';
echo $xciptv_app_data['player_catchup'] == 'EXO' ? 'selected' : '';
echo '>Exo</option>' . "\r\n" . '                                                                <option value="VLC" ';
echo $xciptv_app_data['player_catchup'] == 'VLC' ? 'selected' : '';
echo '>VLC</option>' . "\r\n" . '                                                            </select>' . "\r\n" . '                                                        </div>' . "\r\n" . '                                                    </div>' . "\r\n\r\n" . '                                                </div>' . "\r\n\r\n" . '                                            </div>' . "\r\n" . '                                            <ul class="pager wizard twitter-bs-wizard-pager-link">' . "\r\n" . '                                                <li class="previous"><a href="#">Previous</a></li>' . "\r\n" . '                                                <li class="next"><a href="#">Next</a></li>' . "\r\n" . '                                            </ul>' . "\r\n" . '                                        </div>' . "\r\n\r\n" . '                                        <br />' . "\r\n\r\n" . '                                        <div class="form-group">' . "\r\n" . '                                            <button class="btn btn-primary btn-block" name="submit_settings" type="submit">Save</button>' . "\r\n" . '                                        </div>' . "\r\n" . '                                    </form>' . "\r\n\r\n" . '                                </div>' . "\r\n\r\n" . '                            </div>' . "\r\n\r\n" . '                        </div>' . "\r\n\r\n\r\n" . '                    </div>' . "\r\n" . '                </div>' . "\r\n\r\n" . '                ';
include 'assets/includes/footer.php';
echo "\r\n" . '            </div>' . "\r\n\r\n" . '        </div>' . "\r\n\r\n" . '        ';
include 'assets/includes/right-sidebar.php';
echo "\r\n" . '        ';
include 'assets/includes/vendor-scripts.php';
echo "\r\n" . '        <script src="./assets/js/app.js"></script>' . "\r\n\r\n" . '</body>' . "\r\n\r\n" . '</html>';

?>