User:Pathoschild/Scripts/AJAX transclusion table

AJAX transclusion table

Screenshot of a row collapsed, loading, and expanded.

The AJAX transclusion table script adds a "[show]" link in the first cell of every row in tables with the "attable" class. Clicking the link will display the linked page below (see screenshots at right). No show/hide link will be shown in rows that don't contain a link, like headings.

Installation edit

  1. Copy the following code to your global.js page (for all wikis) or your common.js page (for Meta only).
    /**
     * Ajax transclusion table adds dynamic content loading to tables with class="attable".
     * @see https://meta.wikimedia.org/wiki/Ajax_transclusion_table
     * @update-token [[File:Pathoschild/ajaxtransclusiontable.js]]
     */
    mw.loader.load('//tools-static.wmflabs.org/meta/scripts/pathoschild.ajaxtransclusiontable.js');
    
  2. Refresh your browser to reload the JavaScript. (In Chrome or Firefox, press [CTRL] and [R] at the same time.)

See also edit