<style>
.tab {
    overflow: hidden;
    border: 1px solid #ccc;
    background-color: #f1f1f1;
    margin-top: 15px;
}
/* Style the buttons inside the tab */
.tab button {
    background-color: inherit;
    float: left;
    border: none;
    outline: none;
    cursor: pointer;
    padding: 14px 16px;
    transition: 0.3s;
    font-size: 17px;
}
/* Change background color of buttons on hover */
.tab button:hover {
    background-color: #ddd;
}
/* Create an active/current tablink class */
.tab button.active {
        background-color: #717070!important;
        color: #ffffff!important;
}
/* Style the tab content */
.tabcontent {
    display: none;
    padding: 6px 12px;
    border: 1px solid #ccc;
    border-top: none;
}
/* Style the close button */
.topright {
    float: right;
    cursor: pointer;
    font-size: 28px;
}
.topright:hover {color: red;}
</style>
<?php 
if (isset($_REQUEST['tab']) && $_REQUEST['tab']=='wpch_social_sharing'){
?>
<div class="tab">
    <button class="tablinks " onclick="location.href = '<?php echo get_admin_url().'admin.php?page=mywpch_sharing&tab=wpch_1click_post'; ?>'" id = "">1-Click Post Indexer</button>
    <button class="tablinks active"  onclick="location.href = '<?php echo get_admin_url().'admin.php?page=mywpch_sharing&tab=wpch_social_sharing'; ?>';" id = "">Social Media Sharer</button>
</div>
<?php	
require_once ( WPCH_PLUGIN_DIR.'/social_media.php' );	
}else{	
?>
<div class="tab">
    <button class="tablinks active" onclick="location.href = '<?php echo get_admin_url().'admin.php?page=mywpch_sharing&tab=wpch_1click_post'; ?>'" id = "">1-Click Post Indexer</button>
    <button class="tablinks "  onclick="location.href = '<?php echo get_admin_url().'admin.php?page=mywpch_sharing&tab=wpch_social_sharing'; ?>';" id = "">Social Media Sharer</button>
</div>
<?php
require_once ( WPCH_PLUGIN_DIR.'/1-click-post.php' );
}
?>