<?php
$page_title = "Admob Settings";
include("includes/header.php");

$qry = "SELECT * FROM tbl_settings where id='1'";
$result = mysqli_query($mysqli, $qry);
$settings_row = mysqli_fetch_assoc($result);

if (isset($_POST['admob_submit']) && PURCHASE == '') {
    if (
        empty(validate_input($_POST['publisher_id'])) ||
        empty(validate_input($_POST['f_publisher_id']))
    ) {
        $_SESSION['msg'] = "15";
        $_SESSION['class'] = 'error';
        header("Location:admob_setting.php");
        exit;
    }
    $data = array(
        'publisher_id'  =>  validate_input($_POST['publisher_id']),
        'f_publisher_id'  =>  validate_input($_POST['f_publisher_id']),
        'al_publisher_id'  =>  validate_input($_POST['al_publisher_id']),
        'interstital_ad_id'  =>  $_POST['interstital_ad_id'],
        'banner_ad_id'  =>  $_POST['banner_ad_id'],
        'interstital_ad_id_ios'  =>  $_POST['interstital_ad_id_ios'],
        'banner_ad_id_ios'  =>  $_POST['banner_ad_id_ios'],
        'app_open_ad_id' => $_POST['app_open_ad_id'],
        'ios_app_open_ad_id' => $_POST['ios_app_open_ad_id'],
        'rewarded_android' => $_POST['rewarded_android'],
        'rewarded_ios' => $_POST['rewarded_ios'],
        'f_interstital_ad_id'  =>  $_POST['f_interstital_ad_id'],
        'f_banner_ad_id'  =>  $_POST['f_banner_ad_id'],
        'f_interstital_ad_id_ios'  =>  $_POST['f_interstital_ad_id_ios'],
        'f_banner_ad_id_ios'  =>  $_POST['f_banner_ad_id_ios'],
        'f_app_open_ad_id' => $_POST['f_app_open_ad_id'],
        'f_ios_app_open_ad_id' => $_POST['f_ios_app_open_ad_id'],
        'f_rewarded_android' => $_POST['f_rewarded_android'],
        'f_rewarded_ios' => $_POST['f_rewarded_ios'],

        'al_interstital_ad_id'  =>  $_POST['al_interstital_ad_id'],
        'al_banner_ad_id'  =>  $_POST['al_banner_ad_id'],
        'al_app_open_ad_id' => $_POST['al_app_open_ad_id'],
        'al_rewarded_android' => $_POST['al_rewarded_android'],

        'al_interstital_ad_id_ios'  =>  $_POST['al_interstital_ad_id_ios'],
        'al_banner_ad_id_ios'  =>  $_POST['al_banner_ad_id_ios'],        
        'al_app_open_ad_id_ios' => $_POST['al_app_open_ad_id_ios'],    
        'al_rewarded_ios' => $_POST['al_rewarded_ios'],
        
        'd_limit' => $_POST['d_limit'],
        
    );

    $settings_edit = Update('tbl_settings', $data, "WHERE id = '1'");


    if ($settings_edit > 0) {

        $_SESSION['msg'] = "11";
        header("Location:admob_setting.php");
        exit;
    }
}
?>
<main id="main" class="main">
    <section class="section">
        <div class="row g-3">
            <div class="col-lg-12">
                <div class="pagetitle">
                    <h1><?php _e($page_title); ?></h1>
                </div>
            </div>
        </div><br>

        <div class="card"><br />
            <div class="row">
                <form class="row g-3" action="" name="addeditcategory" method="post" enctype="multipart/form-data">
                    <div class="col-4">
                        <div class="card-body">
                            <label for="inputNanme4" class="form-label">Google App Id</label>
                            <input type="text" class="form-control mb-2" name="publisher_id" value="<?php _e($settings_row['publisher_id']); ?>">
                        </div>
                    </div>

                    <div class="col-4">
                        <label for="inputNanme4" class="form-label">Facebook App Id</label>
                        <input type="text" class="form-control mb-2" name="f_publisher_id" value="<?php _e($settings_row['f_publisher_id']); ?>">
                    </div>
                    <div class="col-4">
                        <label for="inputNanme4" class="form-label">App Lovin key</label>
                        <input type="text" class="form-control mb-2" name="al_publisher_id" value="<?php _e($settings_row['al_publisher_id']); ?>">
                    </div>
                    <div class="col-6">
                        <div class="card-body">
                            <label for="inputNanme4" class="form-label">Show Ads</label>
                            <label for="inputNanme4" class="form-label">Status</label>
                            <?php if ($settings_row['showAds'] == "1") { ?>
                                <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="showAds">
                                    <img src="assets/img/btn_enabled.png" style="width:50px" />
                                </a>
                            <?php } else { ?>
                                <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="showAds">
                                    <img src="assets/img/btn_disabled.png" style="width:50px" />
                                </a>
                            <?php } ?>
                        </div>
                    </div>
                    <div class="col-4">
                        <label for="inputNanme4" class="form-label">Limit</label>
                        <input type="text" class="form-control mb-2" name="d_limit" value="<?php _e($settings_row['d_limit']); ?>">
                    </div>
            </div>
            <div class="row">
                <div class="col-6">
                    <h1 class="text-center">Android</h1>
                    <div class="card-body">
                        <div class="row">
                            <div class="col-3"><label for="inputNanme4" class="form-label">Banner Ads</label>
                                <?php if ($settings_row['banner_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="banner_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="banner_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"><label for="inputNanme4" class="form-label">Interstitial Ads</label>
                                <?php if ($settings_row['interstital_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="interstital_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="interstital_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"> <label for="inputNanme5" class="form-label">Rewarded Ads</label>
                                <?php if ($settings_row['rewarded_android_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="rewarded_android_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="rewarded_android_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"> <label for="inputNanme5" class="form-label">Native Ad ID</label>
                                <?php if ($settings_row['app_open_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="app_open_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="app_open_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                        </div>
                    </div>
                </div>

                <div class="col-6">
                    <h1 class="text-center">IOS</h1>
                    <div class="card-body">
                        <div class="row">
                            <div class="col-3"><label for="inputNanme4" class="form-label">Banner Ads</label>
                                <?php if ($settings_row['ios_banner_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="ios_banner_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="ios_banner_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"><label for="inputNanme4" class="form-label">Interstital Ads</label>
                                <?php if ($settings_row['ios_interstital_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="ios_interstital_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="ios_interstital_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"><label for="inputNanme5" class="form-label">Rewarded Ads</label>
                                <?php if ($settings_row['rewarded_ios_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="rewarded_ios_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="rewarded_ios_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                            <div class="col-3"> <label for="inputNanme5" class="form-label">Native Ad ID</label>
                                <?php if ($settings_row['ios_app_open_ad_id_status'] == "1") { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="active" data-column="ios_app_open_ad_id_status">
                                        <img src="assets/img/btn_enabled.png" style="width:50px" />
                                    </a>
                                <?php } else { ?>
                                    <a title="Change Status" class="toggle_btn_a form-control" href="javascript:void(0)" data-id="<?php _e($settings_row['id']); ?>" data-action="deactive" data-column="ios_app_open_ad_id_status">
                                        <img src="assets/img/btn_disabled.png" style="width:50px" />
                                    </a>
                                <?php } ?>
                            </div>
                        </div>
                    </div>
                </div>

            </div>
            <h1 class="text-center">Google</h1>
            <div class="row">
                <div class="col-lg-6">


                    <div class="card-body">
                        <h3 class="card-title">Android</h3>



                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne" aria-expanded="true" aria-controls="collapseOne">
                                        Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne" class="accordion-collapse collapse show" aria-labelledby="headingOne" data-bs-parent="#accordionExample">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner AD ID</label>
                                            <input type="text" class="form-control mb-2" name="banner_ad_id" value="<?php _e($settings_row['banner_ad_id']); ?>">
                                        </div>

                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo" aria-expanded="false" aria-controls="collapseTwo">
                                        Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo" class="accordion-collapse collapse" aria-labelledby="headingTwo" data-bs-parent="#accordionExample">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital AD ID</label>
                                            <input type="text" class="form-control mb-2" name="interstital_ad_id" value="<?php _e($settings_row['interstital_ad_id']); ?>">
                                        </div>

                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour" aria-expanded="false" aria-controls="collapsefour">
                                        Rewarded Ads
                                    </button>
                                </h2>
                                <div id="collapsefour" class="accordion-collapse collapse" aria-labelledby="headingFour" data-bs-parent="#accordionExample">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Aewarded Android ID</label>
                                            <input type="text" class="form-control mb-2" name="rewarded_android" value="<?php _e($settings_row['rewarded_android']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div><!-- End Default Accordion Example -->
                    </div>

                </div>


                <div class="col-lg-6">

                    <div class="card-body">
                        <h3 class="card-title">IOS</h3>

                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample2">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne2">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne2" aria-expanded="true" aria-controls="collapseOne2">
                                        IOS Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne2" class="accordion-collapse collapse show" aria-labelledby="headingOne2" data-bs-parent="#accordionExample2">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner ID</label>
                                            <input type="text" class="form-control mb-2" name="banner_ad_id_ios" value="<?php _e($settings_row['banner_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo2">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo2" aria-expanded="false" aria-controls="collapseTwo2">
                                        IOS Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo2" class="accordion-collapse collapse" aria-labelledby="headingTwo2" data-bs-parent="#accordionExample2">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital ID</label>
                                            <input type="text" class="form-control mb-2" name="interstital_ad_id_ios" value="<?php _e($settings_row['interstital_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour2">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour2" aria-expanded="false" aria-controls="collapsefour2">
                                        Rewarded Ios
                                    </button>
                                </h2>
                                <div id="collapsefour2" class="accordion-collapse collapse" aria-labelledby="headingFour2" data-bs-parent="#accordionExample">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Rewarded Ios ID</label>
                                            <input type="text" class="form-control mb-2" name="rewarded_ios" value="<?php _e($settings_row['rewarded_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                    </div>

                </div>
            </div>
            <!-- /////////////////////////////////////////////// -->
            <h1 class="text-center">FACE BOOK</h1>
            <div class="row">
                <div class="col-lg-6">
                    <div class="card-body">
                        <h3 class="card-title">Android</h3>
                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample11">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne1">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne1" aria-expanded="true" aria-controls="collapseOne">
                                        Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne1" class="accordion-collapse collapse show" aria-labelledby="headingOne" data-bs-parent="#accordionExample11">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner AD ID</label>
                                            <input type="text" class="form-control mb-2" name="f_banner_ad_id" value="<?php _e($settings_row['f_banner_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo1">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo1" aria-expanded="false" aria-controls="collapseTwo">
                                        Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo1" class="accordion-collapse collapse" aria-labelledby="headingTwo" data-bs-parent="#accordionExample11">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital AD ID</label>
                                            <input type="text" class="form-control mb-2" name="f_interstital_ad_id" value="<?php _e($settings_row['f_interstital_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour1">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour1" aria-expanded="false" aria-controls="collapsefour">
                                        Rewarded Ids
                                    </button>
                                </h2>
                                <div id="collapsefour1" class="accordion-collapse collapse" aria-labelledby="headingFour" data-bs-parent="#accordionExample11">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Aewarded Android ID</label>
                                            <input type="text" class="form-control mb-2" name="f_rewarded_android" value="<?php _e($settings_row['f_rewarded_android']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div><!-- End Default Accordion Example -->
                    </div>

                </div>
                <div class="col-lg-6">

                    <div class="card-body">
                        <h3 class="card-title">IOS</h3>

                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample22">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne21">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne21" aria-expanded="true" aria-controls="collapseOne2">
                                        IOS Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne21" class="accordion-collapse collapse show" aria-labelledby="headingOne21" data-bs-parent="#accordionExample22">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner ID</label>
                                            <input type="text" class="form-control mb-2" name="f_banner_ad_id_ios" value="<?php _e($settings_row['f_banner_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo21">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo21" aria-expanded="false" aria-controls="collapseTwo2">
                                        IOS Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo21" class="accordion-collapse collapse" aria-labelledby="headingTwo21" data-bs-parent="#accordionExample22">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital ID</label>
                                            <input type="text" class="form-control mb-2" name="f_interstital_ad_id_ios" value="<?php _e($settings_row['f_interstital_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour21">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour21" aria-expanded="false" aria-controls="collapsefour2">
                                        Rewarded Ios
                                    </button>
                                </h2>
                                <div id="collapsefour21" class="accordion-collapse collapse" aria-labelledby="headingFour21" data-bs-parent="#accordionExample22">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Rewarded Ios ID</label>
                                            <input type="text" class="form-control mb-2" name="f_rewarded_ios" value="<?php _e($settings_row['f_rewarded_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                    </div>

                </div>
            </div>

            <h1 class="text-center">Applovin</h1>
            <div class="row">
                <div class="col-lg-6">
                    <div class="card-body">
                        <h3 class="card-title">Android</h3>
                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample12">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne12">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne12" aria-expanded="true" aria-controls="collapseOne">
                                        Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne12" class="accordion-collapse collapse show" aria-labelledby="headingOne" data-bs-parent="#accordionExample12">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner AD ID</label>
                                            <input type="text" class="form-control mb-2" name="al_banner_ad_id" value="<?php _e($settings_row['al_banner_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo12">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo12" aria-expanded="false" aria-controls="collapseTwo">
                                        Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo12" class="accordion-collapse collapse" aria-labelledby="headingTwo" data-bs-parent="#accordionExample12">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital AD ID</label>
                                            <input type="text" class="form-control mb-2" name="al_interstital_ad_id" value="<?php _e($settings_row['al_interstital_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingThree">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseThree" aria-expanded="false" aria-controls="collapseThree">
                                        Native Ad ID
                                    </button>
                                </h2>
                                <div id="collapseThree" class="accordion-collapse collapse" aria-labelledby="headingThree" data-bs-parent="#accordionExample">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Native Ad ID</label>
                                            <input type="text" class="form-control mb-2" name="al_app_open_ad_id" value="<?php _e($settings_row['al_app_open_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour12">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour12" aria-expanded="false" aria-controls="collapsefour">
                                        Rewarded Ids
                                    </button>
                                </h2>
                                <div id="collapsefour12" class="accordion-collapse collapse" aria-labelledby="headingFour" data-bs-parent="#accordionExample12">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Aewarded Android ID</label>
                                            <input type="text" class="form-control mb-2" name="al_rewarded_android" value="<?php _e($settings_row['al_rewarded_android']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div><!-- End Default Accordion Example -->
                    </div>

                </div>
                <div class="col-lg-6">

                    <div class="card-body">
                        <h3 class="card-title">IOS</h3>

                        <!-- Default Accordion -->
                        <div class="accordion" id="accordionExample222">
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingOne212">
                                    <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#collapseOne212" aria-expanded="true" aria-controls="collapseOne2">
                                        IOS Banner Ads
                                    </button>
                                </h2>
                                <div id="collapseOne212" class="accordion-collapse collapse show" aria-labelledby="headingOne212" data-bs-parent="#accordionExample222">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Banner ID</label>
                                            <input type="text" class="form-control mb-2" name="al_banner_ad_id_ios" value="<?php _e($settings_row['al_banner_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingTwo212">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseTwo212" aria-expanded="false" aria-controls="collapseTwo2">
                                        IOS Interstital Ads
                                    </button>
                                </h2>
                                <div id="collapseTwo212" class="accordion-collapse collapse" aria-labelledby="headingTwo212" data-bs-parent="#accordionExample222">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">Interstital ID</label>
                                            <input type="text" class="form-control mb-2" name="al_interstital_ad_id_ios" value="<?php _e($settings_row['al_interstital_ad_id_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingThree2">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapseThree2" aria-expanded="false" aria-controls="collapseThree2">
                                        IOS Native Ad ID
                                    </button>
                                </h2>
                                <div id="collapseThree2" class="accordion-collapse collapse" aria-labelledby="headingThree2" data-bs-parent="#accordionExample2">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme4" class="form-label">IOS Native Ad ID</label>
                                            <input type="text" class="form-control mb-2" name="ios_app_open_ad_id" value="<?php _e($settings_row['ios_app_open_ad_id']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="accordion-item">
                                <h2 class="accordion-header" id="headingFour212">
                                    <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#collapsefour212" aria-expanded="false" aria-controls="collapsefour2">
                                        Rewarded Ios
                                    </button>
                                </h2>
                                <div id="collapsefour212" class="accordion-collapse collapse" aria-labelledby="headingFour212" data-bs-parent="#accordionExample222">
                                    <div class="accordion-body">
                                        <div class="col-12">
                                            <label for="inputNanme5" class="form-label">Rewarded Ios ID</label>
                                            <input type="text" class="form-control mb-2" name="al_rewarded_ios" value="<?php _e($settings_row['al_rewarded_ios']); ?>">
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>

                    </div>

                </div>
            </div>
            <!-- /////////////////////////////////////////////// -->

            <div class="text-center">
                <button type="submit" name="admob_submit" class="btn btn-primary <?php _e(PURCHASE); ?>">Save</button>
                <button type="reset" class="btn btn-secondary">Reset</button>
            </div>
            </form>
        </div><br>
        </div>
    </section>
    <script type="text/javascript">
        $(".toggle_btn_a").on("click", function(e) {
            e.preventDefault();

            var _for = $(this).data("action");
            var _id = $(this).data("id");
            var _column = $(this).data("column");
            var _table = 'tbl_settings';
            $.ajax({
                type: 'post',
                url: 'processdata.php',
                dataType: 'json',
                data: {
                    id: _id,
                    for_action: _for,
                    column: _column,
                    table: _table,
                    'action': 'admob_add',
                    'tbl_id': 'id'
                },
                success: function(res) {
                    console.log(res);
                    if (res.status == '1') {
                        location.reload();
                    }
                }
            });

        });
    </script>
</main>
<?php include("includes/footer.php"); ?>