WordPress.org

Make WordPress Core

Ticket #11420: 11420.fix-search-and-pagination.diff

File 11420.fix-search-and-pagination.diff, 1019 bytes (added by nacin, 3 years ago)

Don't forget to send the title when making a pagination request.

  • wp-includes/js/tinymce/plugins/wplink/js/wplink.dev.js

     
    149149                        setTimeout(function() { 
    150150                                var newTop = t.scrollTop(), 
    151151                                        newBottom = newTop + t.height(), 
    152                                         waiting = t.find('.river-waiting'); 
     152                                        waiting = t.find('.river-waiting'), 
     153                                        s = inputs.search.val(), 
     154                                        args = {}; 
    153155 
    154156                                if ( bottom != newBottom || newBottom != ul.height() || river.active || river.allLoaded ) 
    155157                                        return; 
     
    157159                                river.active = true; 
    158160                                waiting.show(); 
    159161                                t.scrollTop( newTop + waiting.outerHeight() ); 
    160  
    161                                 wpLink.linkAJAX( t, { page : river.page }, function(r) { 
     162                                args = { page : river.page }; 
     163                                if ( s ) 
     164                                        args.title = s; 
     165                                wpLink.linkAJAX( t, args, function(r) { 
    162166                                        river.page++; 
    163167                                        river.active = false; 
    164168                                        river.allLoaded = !r;