ClonPost

Clonador de posts, clona cualquier post solo poniendo la Id. (el famoso repost)

Stan na 27-02-2016. Zobacz najnowsza wersja.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name       ClonPost
// @version    0.7
// @description  Clonador de posts, clona cualquier post solo poniendo la Id. (el famoso repost)
// @match      http://www.taringa.net/agregar
// @include     *://*.taringa.net/agregar
// @include     *://*.taringa.net/posts/editar/*
// @copyright  @Cazador4ever
// @namespace http://www.taringa.net/Cazador4ever
// @icon      https://a.fsdn.com/allura/p/taringaapp/icon
// ==/UserScript==
/* jshint -W097 */
'use strict';

(function() {
    var clonar = $('<center><div class="box" Style="background-color:#d9e6f2"><font color="grey"><h5>-| Clonar posts |-</h5></font><input type="text" name="PostId" id="PostId" autocomplete="on" placeholder="Id del post..."><a class="btn g clon" href="#" id="clonarpost">[Clonar]</a></div></div></center>');
    $('#sidebar').prepend(clonar);
    
    
    function clon() {
        $("#clonarpost").css("background","#36BBCE");
        var id = $('#PostId').val();
        var api = 'http://api.taringa.net/post/view/' + id;
        $.getJSON( api, function(json) {
        var body= $('#markItUp').val();
        var a = $('#markItUp');
        var titulo = $('#titulo-input');
        var tit = json.title;
        var d = json.body;
        var c = ''+d+'';
        a.val(body+c).click().focus();
        titulo.val(tit).click().focus();});
       } clonarpost.onclick=clon;
 
   })();