@teodor7teodor7

Как сделать регер mail.ru на casperjs?

Почему пишет регистрация в данном домене не доступна.
var casper = require('casper').create();
casper.options.viewportSize = {width:1024 ,height: 768};
var fs = require('fs'); 

//casper.userAgent('Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.100 Safari/537.36');
casper.start('https://m.mail.ru/cgi-bin/reg');

casper.then(function() {
   this.wait(1000, function() { 
   this.capture('start.png');
}); });
casper.then(function() { 
   var genderName = this.evaluate(function() {
      return  'input#'+document.querySelector('form.reg_form input[type=radio]').id;
   });
   this.fillSelectors('form.reg_form', {
     'input': 'Ivan',
   },false);

// this.click('#man1');
   this.sendKeys('#Username','casperjs');
   this.click(genderName);
});

casper.then(function() {
this.fillSelectors('form.reg_form', {
   'input#Username': 'ca75122',
   'input.birthday': '11',
   'select[name=BirthMonth]': '12',
   'input.birthyear': '1981',
},false);
this.wait(1000, function() { 
this.capture('midle.png');
});this.fillSelectors('form.reg_form', { 
  'input.birthday': '11',},true);
   this.wait(1000, function() {
      this.capture('end.png');
   });
});
casper.run();
Какие могут быть причины?
  • Вопрос задан
  • 165 просмотров
Пригласить эксперта
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Войти через центр авторизации
Похожие вопросы