User:Suppa chuppa/diffplus.js

$(document).ready(function {   if(wgPageName == 'User:Suppa chuppa/RecentChangesHybrid')    {        $('#quickdiff').each.click(function { var class = $(this).attr('class').split('\\=\\'); var diff = class[0]; var page = class[1]; $.ajax({               url: wgScriptPath + '/api.php',                dataType: 'json',                data: {                    format: 'json',                    action: 'query',                    prop: 'revisions',                    titles: page,                    rvdifftotext: diff,                    indexpageids: true                },                success: function(data)                {                    var div = $(' ').attr('class', 'qdiff');                    div.html(data.query.pages[data.query.pageids[0]].revisions[0].diff['*']);                    $(this).append(div);                }            }); });   } });