$('#interval').bootstrapSlider();

$(document).ready(function () {
    $('#hideTitle').on('change', function () {
        var isChecked = $(this).prop('checked');
        $.ajax({
            type: 'post',
            url: './includes/post_webview_rtxmoviebanner.php',
            data: { 
                post_hideTitle: 1,
                hideTitle: isChecked ? 'enabled' : 'disabled' 
            },
            success: function (response) {
                location.reload();
            }
        });
    });
});

$(document).ready(function () {
    $('#hideSubtitle').on('change', function () {
        var isChecked = $(this).prop('checked');
        $.ajax({
            type: 'post',
            url: './includes/post_webview_rtxmoviebanner.php',
            data: { 
                post_hideSubtitle: 1,
                hideSubtitle: isChecked ? 'enabled' : 'disabled' 
            },
            success: function (response) {
                location.reload();
            }
        });
    });
});

$(document).ready(function () {
    $('#hideRating').on('change', function () {
        var isChecked = $(this).prop('checked');
        $.ajax({
            type: 'post',
            url: './includes/post_webview_rtxmoviebanner.php',
            data: { 
                post_hideRating: 1,
                hideRating: isChecked ? 'enabled' : 'disabled' 
            },
            success: function (response) {
                location.reload();
            }
        });
    });
});