Load only div from a specific site

1

Hello, I'm trying to get all the information from a page to a webview via jsoup but the letters are all deformed when I load and it does not look like this on the site, there's some way to load the site, but only the div that I want, which in this case is the div "inside2"?

This is the site: link

Code where you load the information but it gets deformed:

private class MyTask extends AsyncTask<String, Integer, String> {

    @Override
    protected void onPreExecute() {
        super.onPreExecute();
    }

    @Override
    protected String doInBackground(String... params) {

        Bundle CursoInfoData = getIntent().getExtras();

        site = CursoInfoData.getString("site");

        Document doc = null;
        try {
            doc = Jsoup.connect(site).get();
        } catch (IOException e) {
            e.printStackTrace();
        }
         ele = doc.select(".inside2");
        return "start";
    }

    @Override
    protected void onProgressUpdate(Integer... values) {
        super.onProgressUpdate(values);
    }

    @Override
    protected void onPostExecute(String result) {
        super.onPostExecute(result);
        String text = "<html><head>"
                + "<style type=\"text/css\">body{color: #01A9DB; background-color: #FFFFFF;}"
                + "</style></head>"
                + "<body>"
                + ele.toString()
                + "</body></html>";
        cursoInfoWeb.loadData(text, "text/html", "utf-8");
    }
}

    
asked by anonymous 01.09.2017 / 19:19

0 answers