Converted data-tables-functions.php to Javascript