0

I am using "request" module to get page contents with following headers

var headers = {
'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10.8; rv:24.0) Gecko/20100101 Firefox/24.0' };

still, the page I am trying to fetch somehow displays different content than View > Source from browser (looks like it detects for javascript support) , before diving into phantomjs (which I want to avoid due performance limitations) is there any way to get the html as it is on the browser?. Thanks

Radoslav
  • 1,812
  • 3
  • 17
  • 27
  • You have to find what the website do when a browser hits it, and replicate it in your app – michelem Jul 01 '15 at 08:12
  • Just figured that out by reading this http://stackoverflow.com/questions/12303134/curl-request-on-a-page-requiring-javascript-support ... it must be cookie – Radoslav Jul 01 '15 at 08:16

0 Answers0