A
A
Ainur Shakirov2016-03-25 23:40:29
Java
Ainur Shakirov, 2016-03-25 23:40:29

JSOP how to parse element with space and Cyrillic in id?

I iterate over the table:

for (Element element3 : element.select("th[id=Д-8 ]"))

In Intelji IDEA, it worked as it should, finding all elements with the specified id. But it doesn't work in the studio. (just finds th)
I suspect that the problem is due to the fact that "D" is Cyrillic. Or the gap interferes .. I can’t figure it out ..
Maybe someone came across?
UDP did a search just th, displayed id, they are without a karabzayak, everything is fine .. and a space is in place ..
The encoding is UTF-8
UDP In the answer.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Ainur Shakirov, 2016-03-26
@Fqyeh29

UDP has done this so far:

for (Element element3 : element.select("th"))
                    {
                        text = element3.attr("id"); 
                        if(text.indexOf("Д-8") != -1){}
}

Works.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question