Errors QueryPath Accent

1

I'm using one of the recommended libraries in this answer , QueryPath . To get the data I'm using Guzzle .

However, I am having problems with data return (accent), it is replacing the characters with ? .

OBS: The problem is not in Guzzle , since I tested with another parser, which according to the above answer is not one of the recommended ones ... and I also did not continue its use because it did not meet some html's complexes that I need to deal with ... but the fact is, that it returned accentuation correctly.

Solutions tested unsuccessfully:

//Primeira Tentativa
$content = mb_convert_encoding($resposta->getBody()->getContents(), 'UTF-8', 'auto');
$html = htmlqp($content); // Problema acentuação ?????????

//Segunda Tentativa
$html5 = new HTML5();
$content = $html5->loadHTML($resposta->getBody()->getContents());
$html = htmlqp($content); // Problema acentuação ?????????

//Terceira Tentativa
$qp = html5qp($resposta->getBody()->getContents());

//Quarta Tentativa
$options = ['convert_to_encoding' => 'UTF-8'];
$qp = htmlqp($resposta->getBody()->getContents(), null, $options);

I do not know what to test anymore .... What could it be?

    
asked by anonymous 03.06.2015 / 14:42

0 answers