[Tutor] Delete an attribute using Beautiful Soup?
Bob Tanner
tanner at real-time.com
Tue Nov 22 09:34:53 CET 2005
Bob Tanner wrote:
> I'd like to delete an attribute of tag, the BGCOLOR to the BODY tag to be
> exact.
I believe I answered my own question. Looking for confirmation this is the
"right" solution.
del(soup.body['bgcolor'])
--
Bob Tanner <tanner at real-time.com> | Phone : (952)943-8700
http://www.real-time.com, Minnesota, Linux | Fax : (952)943-8500
Key fingerprint = AB15 0BDF BCDE 4369 5B42 1973 7CF1 A709 2CC1 B288
More information about the Tutor
mailing list