View Single Post
Old 04-01-2010, 11:40 AM   #1713
Starson17
Wizard
Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.Starson17 can program the VCR without an owner's manual.
 
Posts: 4,004
Karma: 177841
Join Date: Dec 2009
Device: WinMo: IPAQ; Android: HTC HD2, Archos 7o; Java:Gravity T
Quote:
Originally Posted by gambarini View Post
Does "keep_only_tags" support more than one condition?
It doesn't support conditionals at all. It will allow you to define extensive lists of tags:

Code:
keep_only_tags = [dict(name='div', attrs={'class':['feature','banner']}),
                          dict(name='a', attrs={'id':['first','second','third']}),
                          dict(name='span', attrs={'potato':['idaho', 'red']})  
                                  ]
Conditionals can be supported with other methods.

Edit: actually, it may support conditionals, I've just never used it.
Starson17 is offline