다음 카페 크롤러 검색결과 없을시 m_Last = true
git-svn-id: svn://192.168.0.12/source@74 8346c931-da38-4b9b-9d4c-e48b93cbd075
This commit is contained in:
@@ -941,12 +941,13 @@ void SCrawler::saveFrameDaumCafeList(QWebFrame *frame)
|
||||
|
||||
static int cz = 0;
|
||||
// Debug(frame->frameName() + QString::number(cz++) + ".html",frame->toHtml());
|
||||
|
||||
//int nLast = 0;
|
||||
QWebElement eleMain = Find(frame->documentElement(),"div","class","type_fulltext wid_f");
|
||||
foreach(QWebElement eleSub,eleMain.findAll("div"))
|
||||
{
|
||||
if (eleSub.attribute("class") == "wrap_cont")
|
||||
{
|
||||
//nLast++;
|
||||
QString strUrl,strTitle;
|
||||
foreach(QWebElement eleSubUrl,eleSub.findAll("a"))
|
||||
{
|
||||
@@ -983,6 +984,16 @@ void SCrawler::saveFrameDaumCafeList(QWebFrame *frame)
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
/*
|
||||
QWebElement noResult = Find(frame->documentElement(),"div","id","noResult");
|
||||
if(!noResult.isNull())
|
||||
m_bLast = true;
|
||||
*/
|
||||
if(eleMain.isNull())
|
||||
m_bLast = true;
|
||||
}
|
||||
|
||||
{
|
||||
bool b_last = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user