Widget:MoveListTrimmer: Difference between revisions

From Elwiki
(Created page with "<includeonly> $('#content h2').each(function(){ var next = $(this).next(); if(next.not('h2').length != 0){ $(this).remove(); } })</includeonly>")
 
mNo edit summary
 
(8 intermediate revisions by the same user not shown)
Line 1: Line 1:
<includeonly>
<includeonly><script>
$('#content h2').each(function(){
$(function(){
    var next = $(this).next();
    $('ul#mw-whatlinkshere-list').prev('h2').addClass('persist');
    if(next.not('h2').length != 0){
    $('table.mw-prefixindex-list-table').each(function(){
         $(this).remove();
        var t = $(this).text();
     }
        var h = $(this).prev('h2').children('span.mw-headline').text().replace('Subpages of ', '');
})</includeonly>
        if(h != t){
            $(this).prev('h2').addClass('persist');
         }
        else{
            $(this).remove();
        }
     });
    $('#content h2').not('.persist').remove();
});</script></includeonly>

Latest revision as of 15:45, 25 May 2015