View Single Post
Old 03-16-2010, 07:08 PM   #1613
kiklop74
Guru
kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.kiklop74 can program the VCR without an owner's manual.
 
kiklop74's Avatar
 
Posts: 800
Karma: 194644
Join Date: Dec 2007
Location: Argentina
Device: Kindle Voyage
Quote:
Originally Posted by Starson17 View Post
AFAIK, the order has no effect. If a tag is not in the keep list, it gets dropped (along with all of its contents).

Actually it does have an effect. If for example you have content like this:

PHP Code:
<div class="a"></div>
garbage
<div class="b"></div>
garbage
<div class="c"></div
And you put in your recipe this:

Code:
keep_only_tags=[dict(name='div',attrs={'class':['c','a','b']})]
You will get this result:

Code:
<div class="c"></div>
<div class="a"></div>
<div class="b"></div>
Therefore the order is important.
kiklop74 is offline