mirror of
https://github.com/TangentFoxy/lua-htmlparser.git
synced 2025-07-28 19:12:18 +00:00
closes #6
:not(), [att=val], [att!=val], [att|=val], [att*=val], [att~=val], [att^=val], [att$=val] Note that the selection is now returned as a simple Set, breaking the abilty brought in by #8 and #9 tot :select() or () on the selection. Of course, the elements in the returned Set are still ElementNodes that can be selected upon.
This commit is contained in:
11
test.lua
11
test.lua
@@ -60,6 +60,17 @@ select("[itemscope='']")
|
||||
select("[itemscope=]")
|
||||
select("[itemscope]")
|
||||
|
||||
select("[itemscope][itemprop='address']")
|
||||
select("[itemscope][itemprop!='address']")
|
||||
select("[itemscope][itemprop!='adres']")
|
||||
select("[itemscope][itemprop!='']")
|
||||
select("[hreflang|='en']")
|
||||
select("[itemprop*='address']")
|
||||
select("[words~='two']")
|
||||
select("[words~='three']")
|
||||
select("[itemprop$='ion']")
|
||||
select("[hreflang^='en']")
|
||||
|
||||
print("\nchapters")
|
||||
local sel, chapters = root("ol.chapters > li"), {}
|
||||
for e in pairs(sel) do
|
||||
|
Reference in New Issue
Block a user