diff options
author | Leonard Richardson <leonardr@segfault.org> | 2017-05-06 21:38:56 -0400 |
---|---|---|
committer | Leonard Richardson <leonardr@segfault.org> | 2017-05-06 21:38:56 -0400 |
commit | a860302f892294d43d509d4b47c07623f44be947 (patch) | |
tree | 48de7402726a87a113c3ec42e887392c5dcd786a /doc/source | |
parent | 797c844c569f0f32ee243642bb6a286d12a004a8 (diff) |
Replace get_attribute_text with get_attribute_list.
Diffstat (limited to 'doc/source')
-rw-r--r-- | doc/source/index.rst | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/doc/source/index.rst b/doc/source/index.rst index 7bee329..e1b73aa 100644 --- a/doc/source/index.rst +++ b/doc/source/index.rst @@ -428,11 +428,11 @@ consolidated:: print(rel_soup.p) # <p>Back to the <a rel="index contents">homepage</a></p> -You can use ```get_attribute_text`` to get the value of any attribute as a -string, whether or not it's a multi-valued atribute:: +You can use ```get_attribute_list`` to get a value that's always a list, +string, whether or not it's a multi-valued atribute - css_soup.p.get_attribute_text('class') - # "body strikeout" + id_soup.p.get_attribute_list('id') + # ["my id"] If you parse a document as XML, there are no multi-valued attributes:: |