Advertisement
loller5

Яндекс. Комменты

Apr 4th, 2019
889
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. try
  2. {
  3.  
  4. await cookiesRemoveAsync();
  5.  
  6. var frame=await navigateAsync("http://buzkoin.ru/1.txt",null,{onFrame: "DOMContentLoaded"});
  7. //await waitFrameReloadAsync(frame);
  8. await waitAsync(1000);
  9. var kod = frame.document.body.innerHTML;
  10. var a = kod.split('\n')[0].replace('<pre>','').split(';');
  11. commandAsync("setvar::mail="+a[0]);
  12. commandAsync("setvar::pass="+a[1]);
  13. //await navigateAsync("http://buzkoin.ru/mail/remove1.php",null,{onFrame: "DOMContentLoaded"});
  14. //await waitAsync(1000);
  15.  
  16. await navigateAsync("http://buzkoin.ru/2.txt",null,{onFrame: "DOMContentLoaded"});
  17. //await waitFrameReloadAsync(frame);
  18. await waitAsync(1000);
  19. var kod = frame.document.body.innerHTML;
  20. var b = kod.split('\n')[0].replace('<pre>','');
  21. commandAsync("setvar::link="+b);
  22. //await navigateAsync("http://buzkoin.ru/mail/remove2.php",null,{onFrame: "DOMContentLoaded"});
  23. //await waitAsync(1000);
  24.  
  25. await navigateAsync("http://buzkoin.ru/3.txt",null,{onFrame: "DOMContentLoaded"});
  26. //await waitFrameReloadAsync(frame);
  27. await waitAsync(1000);
  28. var kod = frame.document.body.innerHTML;
  29. var c = kod.split('\n')[0].replace('<pre>','');
  30. commandAsync("setvar::text="+c);
  31. //await navigateAsync("http://buzkoin.ru/mail/remove3.php",null,{onFrame: "DOMContentLoaded"});
  32. //await waitAsync(1000);
  33.  
  34. await navigateAsync("https://passport.yandex.ru/",null,{onFrame: "DOMContentLoaded"});
  35. await waitFrameReloadAsync(frame);
  36. //await waitAsync(2000);
  37.  
  38. let element = frame.document.querySelector('#passp-field-login');
  39. await inputTextAsync(element, a[0]);
  40.  
  41. //await frame.wrappedJSObject.jQuery('#passp-field-login').val(a[0]);
  42. await waitAsync(1000);
  43. await frame.wrappedJSObject.jQuery('.passp-sign-in-button > button').eq(0).click();
  44.  
  45. // await waitFrameReloadAsync(frame);
  46. await waitAsync(5000);
  47.  
  48. element = frame.document.querySelector('#passp-field-passwd');
  49. await inputTextAsync(element, a[1]);
  50.  
  51. // await frame.wrappedJSObject.jQuery('#passp-field-passwd').val(a[1]);
  52. await waitAsync(1000);
  53. await frame.wrappedJSObject.jQuery('form').submit();
  54.  
  55. //await waitFrameReloadAsync(frame);
  56. await waitAsync(2000);
  57.  
  58. commandAsync("debug::Test1");
  59.  
  60. await navigateAsync(b,"https://passport.yandex.ru/",{onFrame: "DOMContentLoaded"});
  61. await waitAsync(2000);
  62.  
  63. commandAsync("debug::Test2");
  64.  
  65. frame.document.querySelector("div.public-DraftEditor-content > div > div div > span").textContent = c;
  66.  
  67. let button1 = frame.document.querySelector('div.public-DraftEditor-content');
  68. await clickAsync (button1);
  69.  
  70. await waitAsync(2000);
  71.  
  72. let button2 = frame.document.querySelector('button.answer-form__button_page');
  73. await clickAsync (button2, { frameReloadEvent: "load" });
  74.  
  75. }
  76. catch(e)
  77. {
  78. commandAsync("debug::Exception " + e);//В случае возникновения ошибок выводим информацию об ошибке в журнал
  79. await stopAsync(1);//Досрочно немедленно останавливаем презентацию, кредиты за неиспользованное время будут возвращены.
  80. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement