|
今天录制百度时输入关键字“茶叶”,录制完毕观察脚本,提交的是一个表单,回放后搜索结果并不是“茶叶”,而是个“?”
web_submit_data("s",
"Action=http://www.baidu.com/s",
"Method=GET",
"EncType=",
"TargetFrame=",
"RecContentType=text/html",
"Referer=http://www.baidu.com/",
"Snapshot=t27.inf",
"Mode=HTML",
ITEMDATA,
"Name=wd", "Value=茶叶", ENDITEM,
EXTRARES,
"Url=http://s.baidu.com/w.gif?q=%B2%E8%D2%B6&fm=se&T=1263525191&y=EE937F2F&path=http://www.baidu.com/s?wd=%B2%E8%D2%B6&cid=9&qid=cae6a742041d1025&t=1263525137216", "Referer=http://www.baidu.com/s?wd=%B2%E8%D2%B6", ENDITEM,
"Url=http://i2u.", "Referer=http://www.baidu.com/s?wd=%B2%E8%D2%B6", ENDITEM,
"Url=http://i2u.", "Referer=http://www.baidu.com/s?wd=%B2%E8%D2%B6", ENDITEM,
LAST);
而录制GOOGLE后,关键字仍然是“茶叶”,回放脚本却正确显示出搜索内容:
web_url("search",
"URL=http://www.google.cn/search?hl=zh-CN&source=hp&q=%E8%8C%B6%E5%8F%B6&aq=f&oq=",
"Resource=0",
"RecContentType=text/html",
"Referer=http://www.google.cn/",
"Snapshot=t2.inf",
"Mode=HTML",
LAST);
请教各位高手,为什么百度录制的脚本,回放出来却是“?”的搜索结果,而google却能正确显示搜索结果。有什么办法能回放百度的脚本时,能正确显示出“茶叶”这个搜索结果呢? |
|