Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- javascript: var re = function (ar) {
- return ar[Math.floor(Math.random() * ar.length)];
- };
- var t = window.location.pathname.split("/")[3];
- var a = function () {
- var n = $(".b-comment_b-info a[name]");
- var w = $(".b-comment_b-body").text().split(/\s+/).filter(function (a) {
- return a.match(/[А-Я]+/);
- }).map(function (a) {
- return a.replace(/[\.!?()]/g, "").toLowerCase()
- });
- $.post("http://1chan.ru/news/res/" + t + "/add_comment/", {
- "post_id": t,
- "text": ">>" + $(re(n)).text() + "\r\n" + (function () {
- var r = [];
- var rand = Math.random() * 30;
- for (var i = 0; i < rand; i++) {
- r.push(re(w))
- };
- var s = r.join(" ");
- return s.charAt(0).toUpperCase() + s.substr(1);;
- })() + "."
- })
- };
- if (true) {
- a();
- } else {
- setInterval('a()', 5000)
- };
Advertisement
Add Comment
Please, Sign In to add comment