This script uses a javascript table called simpledatatables.
window.addEventListener('DOMContentLoaded', event => {
// Simple-DataTables
// https://github.com/fiduswriter/Simple-DataTables/wiki
const datatablesSimple = document.getElementById('datatablesSimple');
if (datatablesSimple) {
new simpleDatatables.DataTable(datatablesSimple);
}
});
Example usage for creating a dynamic table with delete and edit hyperlinks. Please note, that the data is in the format expected from mysqli. I.E. array with number indexes and each element is an array with text indexes. These text indexes are used for the column headings.
JSTableEx::QuickWrite($aTemplates, 'id', Link::$rootWeb.'admin/site/templates/edit', Link::$rootWeb.'admin/site/templates/delete', 50);
PHP HTML Table
Brought to you by:
mortontech
Downloads:
0 This Week