I am using the phantom
module with Node.js not the phantomjs
runtime.
How do I access page.content
?
The example below does not work.
var phantom = require('phantom')
phantom.create(function (ph) {
ph.createPage(function (page) {
page.open('http://www.google.com', function (status) {
console.log(status) // -> success
console.log(page.content) // -> undefined
console.log(page.getContent()) // -> undefined
ph.exit()
})
})
})