(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.There is no difference,they should have update there doc on get_text() an mention that
lso the difference in get_text and .text is ?
.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.