正则表达式HTML脚本
http://ckarea.com/bbs/forum.php?mod=forumdisplay&fid=468&page=1
http://ckarea.com/bbs/forum.php?mod=forumdisplay&fid=468&page=2
.
http://ckarea.com/bbs/forum.php?mod=forumdisplay&fid=468&page=10
请教如何用正则表达式,只获取page=1,其余均过滤掉,
这脚本语法分别代表甚么意思
if (string.find(HTML.Url,'-%d+')) then
local s,e=string.find(HTML.Content,'fullview');
if (s and e) then
s=string.find(HTML.Content,'http',e+1);
if (s) then
e=string.find(HTML.Content,'jpg',s+5);
if (e) then
local url=string.sub(HTML.Content,s,e+2);
url=string.gsub(url,'\\/','/');
AddLink(url,HTML.Url,HTML.Title,'',HTML.TaskID,0);
end
end
end
else
DefaultParser(HTML.Content,HTML.Url,HTML.Title,HTML.TaskID,HTML.Level);
end