Getting started with casperjs – First program to getting started

var casper = require('casper').create();
casper.start('http://casperjs.org/');

casper.then(function() {
    this.echo('First Page: ' + this.getTitle());
});

casper.thenOpen('http://phantomjs.org', function() {
    this.echo('Second Page: ' + this.getTitle());
});

casper.run();

if you want to reproduce, please indicate the source:
Getting started with casperjs – First program to getting started - CodeDay