PHP CURL Response возвращает закодированный символ - PullRequest
0 голосов
/ 17 января 2019

Добрый вечер, мой друг. У меня есть следующая проблема с моим локоном. Я пытаюсь просмотреть мою банковскую мутацию. Первым делом я должен войти в систему. После успешного входа в систему и достижения какой-либо конечной точки. Я получил закодированный HTML. Я хочу, чтобы закодировать, но не найти пути. Это картинка enter image description here

И вот код, который я использую:

public function getMutasiRekening($from, $to)
    {
        if( !$this->isLoggedIn ) $this->login( $this->username, $this->password );

        $this->curlSetPost();

        curl_setopt( $this->curlHandle, CURLOPT_URL, 'https://ib.muamalatbank.com/ib-app-mobile/en/homewelcome' );
        curl_setopt( $this->curlHandle, CURLOPT_REFERER, $this->_defaultTargets['loginAction'] );
        $this->exec();


        curl_setopt( $this->curlHandle, CURLOPT_URL, 'https://ib.muamalatbank.com/ib-app-mobile/en/HomeAccountInfo' );
        curl_setopt( $this->curlHandle, CURLOPT_REFERER, 'https://ib.muamalatbank.com/ib-app-mobile/en/homewelcome' );
        $this->exec();


        curl_setopt( $this->curlHandle, CURLOPT_URL, 'https://ib.muamalatbank.com/ib-app-mobile/en/MI11300a');
        curl_setopt( $this->curlHandle, CURLOPT_REFERER, 'https://ib.muamalatbank.com/ib-app-mobile/en/HomeAccountInfo' );
        $this->exec();

        $params = array(
            'radiogroup=0',
            'hidden=09/01/2019',
            'dfrom-s1=9',
            'dfrom-s2=1',
            'dform-s3=2019',
            'accountSelect=4550004619'
        );
        $params = implode( '&', $params );

        curl_setopt( $this->curlHandle, CURLOPT_URL, 'https://ib.muamalatbank.com/ib-app-mobile/en/mi11300a.form1' );
        curl_setopt( $this->curlHandle, CURLOPT_REFERER, 'https://ib.muamalatbank.com/ib-app-mobile/en/MI11300a' );

        curl_setopt( $this->curlHandle, CURLOPT_POSTFIELDS, $params );
        $html = $this->exec();

        var_dump("Content of HTML");
        var_dump(html_entity_decode(  iconv("UTF-8", "ISO-8859-1", $html) ));
        exit;

        return $this->getMutasiRekeningTable($html);
    }
Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...