<?php
/*https://www.jqueryscript.net/demo/SocialCount-Mobile-Friendly-Social-Networking-Widgets/*/
$optres['css'][] = $path . 'amodules/social_media/widgets/facebook_like_box/facebook_like_box.css';
//$optres['js'][] = $path . 'amodules/social_media/widgets/facebook_like_box/facebook_like_box.js';

// Get the actual URL
$is_online = true;
$ultra_domainname = $line_domain['domainname'];
$ultra_addonname = $line_domain['addonname'];
$current_url = $protocol . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI'];

if(strpos($current_url, 'cypruswebsites') !== false) $is_online = false;

if(!$is_online) {
    $current_uri = str_replace($ultra_addonname, '', $_SERVER['REQUEST_URI']);
    $current_url = $protocol . $ultra_domainname . $current_uri;
}

if(isset($social_accounts['facebook'])) {
    ?>
    <div class="facebook-like-box">
        <div class="fb-page" data-href="<?=$social_accounts['facebook']['page_url'];?>" data-tabs="timeline"  data-height="70" data-small-header="false" data-adapt-container-width="true" data-hide-cover="false" data-show-facepile="false"><blockquote cite="<?=$social_accounts['facebook']['page_url'];?>" class="fb-xfbml-parse-ignore"><a href="<?=$social_accounts['facebook']['page_url'];?>"><?=$line_domain['title_en'];?></a></blockquote></div>
    </div>

    <?php
}
