I need to crawl a site and get all the links from it, the problem is - this site uses ajax, and Go's standart http.Get(..) will return something like:
<body>
//javascript here
<div class="content"></div>
//javascript here
</body>
Div is empty. Is there some solution with golang?
http.Get(Url) just get the response of the Url. resp.Content is like:
<body>
//javascript here
<div class="content"></div>
//javascript here
</body>
if you want to get the content in the div, you need to analysis the javascript and know how the ajax to get data. Then you can simulate the processes the get what you want.
You must use one of the headless webbrowsers. Without checking i'm saying that there is no Go binding for the three remaining browser engines (Webkit/Firefox,IE).
Switch to python and javascript.