lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


> In the site http://www2.camara.gov.br/glossario/ there's a lot of
> definitions that I want to grab to a txt file.

Try finding TR and then extracting the two TD's inside them.
Something like this (tested!):

local pattern="<TR>.-<H4 class=sessaoPagina>(.-)</H4>.-<TD>(.-)</TD></TR>"
for w,d in string.gfind(page,pattern) do
   print(w)
   print(d)
   print("---------------------")
end

--lhf