Python Forum
find chars after chars in 'pre' tag
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
find chars after chars in 'pre' tag
#9
(Aug-20-2017, 02:56 PM)Fran_3 Wrote: Can you tell me where is the documentation on the .text method? I Googled & looked in BS doc's but couldn't find.
lso the difference in get_text and .text is ?
There is no difference,they should have update there doc on get_text() an mention that .text is preferred. 
 .text is just a @property that calls get_text().
They also have they old getText(),to keep backward compatibility.
>>> p.text
'Calculation Results is'
>>> p.get_text()
'Calculation Results is'
>>> p.getText()
'Calculation Results is'
However, get_text() can also support various keyword arguments to change how it behaves (separator, strip, types).
If need more control over the result.
Reply


Messages In This Thread
find chars after chars in 'pre' tag - by Fran_3 - Aug-17-2017, 11:18 PM
RE: find chars after chars in 'pre' tag - by Fran_3 - Aug-19-2017, 04:27 PM
RE: find chars after chars in 'pre' tag - by Fran_3 - Aug-19-2017, 08:30 PM
RE: find chars after chars in 'pre' tag - by Fran_3 - Aug-20-2017, 02:56 PM
RE: find chars after chars in 'pre' tag - by snippsat - Aug-20-2017, 03:48 PM
RE: find chars after chars in 'pre' tag - by Fran_3 - Aug-22-2017, 11:44 PM

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020