-1

now a days there are web pages which developed using some ajax based frameworks (dynamically or lazy loading). Just wondering if there is any way to download html contents of such pages as when i try to download using htmlAgilityPack but all i get is header and empty body part but when i try to inspect element then only i can see proper htmls/div but of that page when i try to look into view source i see empty body...

is there any third party like htmlAgilityPack or any other way?

Muhammad Adnan
  • 1,375
  • 6
  • 19
  • 40
  • Use your browser's F12 tools to inspect the actual HTTP requests seen in your browser and then use a HTTP client (use `HttpWebRequest` or `HttpClient` directly). Note that the requests might depend on some kind of client or server state, such as cookies or you having made previous requests. – Dai Aug 11 '15 at 20:14

2 Answers2

0

You would need to be able to run the js that is inside. Which according to this answer is not possible with htmlAgilityPack.

Community
  • 1
  • 1
litelite
  • 2,857
  • 4
  • 23
  • 33
0

You can see it.Getting web content by Html Agility Pack.https://code.msdn.microsoft.com/Getting-web-content-by-bb07d17d...