0

This is my proxy.php file:

$url = urldecode($_GET['url']);
$url = 'http://' . str_replace('http://', '', $url);
echo file_get_contents($url);

And this is my reader.js file:

    var site = 'http://wanteddomain.com/index.aspx?lang=34&team1=0&team2=0&next_turn=1'

    var url = 'http://localhost/mydomain.pl/admin/proxy.php?url=' + encodeURIComponent(site)

    $.ajax({
        url      : url,
        type     : 'GET',
        contentType: "text/html;charset=utf-8",
        dataType : 'html'
    }).done(function(res) {

        //when I access special dom element, I have for example æ³°æå°å¡ instead of 广告
    });

What to do to have chinese characters?

Bartłomiej Semańczyk
  • 59,234
  • 49
  • 233
  • 358

0 Answers0