EzDevInfo.com

trifleJS

Headless automation for Internet Explorer

TrifleJS quitting; "Unexpected ."

Can somebody tell me what is wrong with my syntax? While running this code in trifle JS it tells me that

. is unexpected at (2,4).

var page = require('webpage').create(),
    page.open("http://www.phantomjs.org", function(status) {
        if ( status === "success" ) {
            page.includeJs("http://ajax.googleapis.com/ajax/libs/jquery/1.6.1/jquery.min.js", function() {
                console.log(page.evaluate(function() {
                    return $("#intro").text();
                }));
                phantom.exit();
            });
        }
    });

Source: (StackOverflow)