MediaWiki:Common.js

From Thương mại - Thuong mai
Revision as of 15:22, 31 January 2024 by Wikibadboy (talk | contribs)

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
/* SORTABLE */
importScript('https://storage.googleapis.com/khuong-itvtbadboy-8383.appspot.com/wiki/sorttable/core.js');

$(document).ready(function() {
	var mytable = new ttable('ttable');
	$('#exporttable').click(function() {alert($('#ttable').tocsv(','));});
	mytable.style.table = 'table-default';
	mytable.style.tablehead = 'head-default';
	mytable.style.tablebody = 'body-default';
	mytable.style.tablecaption = 'caption-default';
	mytable.style.headhover = true;
	mytable.style.tablehead_hover = 'hoverhead-default';
	mytable.style.tableheadtd_hover = 'hoverheadtd-default';
	mytable.style.bodyhover = true;
	mytable.style.tablebody_hover = 'hoverbody-default';
	mytable.highlight.enabled = true;
	mytable.highlight.style = 'highlight-default';
	mytable.highlight.onclick = true;
	mytable.highlight.onclick_style = 'clicklight-default';
	mytable.style.stripped = true;
	mytable.style.odd_row = 'odd-default';
	mytable.style.num = true;
	mytable.style.num_class = 'num-default';
	mytable.sorting.enabled = true;
	mytable.sorting.sortall = true;
	mytable.sorting.resetnum = true;
	mytable.sorting.sortedstyle = 'sorted-default';
	mytable.sorting.clickablestyle = 'clickable-default';
	mytable.sorting.sortascstyle = 'sortasc-default';
	mytable.sorting.sortdescstyle = 'sortdesc-default';
	mytable.pagination.enabled = true;
	mytable.pagination.rowperpage=5;
	mytable.edit.enabled = false;
	mytable.search.enabled = true;
	mytable.search.inputID = 'filter';
	mytable.search.casesensitive = true;
	mytable.rendertable();
});