开发者

How to downlaod ajaxed pages with WinInet

I am using WinInet for downloading webpages in my small C++ program. With the increased use of Ajaxed pages (urls with hashbang), the download does not work good. Instead of getting the current state of the page, I always get the previous state.

Is there some ways to handle it with WinInet? Are there any other libraries or specific proc开发者_运维百科edures to follow? Should I integrate a javascript engine as well to do the job.

Will appreciate any help or sample code to handle this in a C++ Program.

Thanks!


You are probably falling victim to the cache, especially with # in the URL. Try INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_CACHE_WRITE (ignore cache and reload from network | do not bother writing response to cache) for dwFlags in HttpOpenRequest or InternetOpenURL.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜