I have this html:
<html lang="en" class="no-js">
<div>
<p class="price ">
3.75
</p>
<p>21</p>
</div>
</html>
I want to get the class of this
The problem is what ever I do to try to get it, every time he comes without the space.
current_element.get(‘class’)…
Even str(current_element) come like this:
'<p class="price">3.75</p>'
How can I get the text of the class in raw? Or something like that?
Regex of all the html is not a option cuz I can have htmls with 11k of lines and more
Thanks!
mauro maurosayan5 baeza is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.