I cannot load data/objects.txt
I cannot load data/objects.txt
Alex67000
Posts: 39Questions: 6Answers: 0
<script>
$(document).ready(function () {
$('#lfg').DataTable({
ajax: '/data/objects.txt',
columns: [
{ data: 'name' },
{ data: 'position' },
{ data: 'office' },
{ data: 'extn' },
{ data: 'start_date' },
{ data: 'salary' },
],
});
});
</script>
I'm stuck on "Loading..." in the table.
See the screencaptures below:
https://i.gyazo.com/631b045c0db5bf5e1bf9df2c6be6491d.png
https://i.gyazo.com/61f6801535d8d634558a716e2e214e74.png
This question has an accepted answers - jump to answer
Answers
Look for errors in your web server. Look for errors in the browser's console. Let us know what you find.
Kevin
Hey Kevin!
Thank you for trying to help me.
Here is a screen capture of the browser's console:
https://i.gyazo.com/3aedbec89143527754c78704c06cf926.png
I have the solution!
Load jQuery Core 3.6.1 - minified and do NOT load jQuery Core slim minified.
Yes, I don't believe slim has ajax built in. Glad its working now.
Kevin