How can i use datatable from CDN in NODERUN?

On my workspace “Customer Crud” I’m trying to use datatable ( https://datatables.net/) but it seems that the CDN is not working fine, it seems to be broke on my workspace, what am I doing wrong? can you pls help me on this.
I’m pointing to the external source in my EJS file like this
For the style

and for the JS functionality

but is not working, however if I use this in a plain HTML it works without any issue.

Hi,

I think you have to use https instead of http, and then it should work.

Alex

Thank you so much Alex for your quick respond I really appreciate it, but it is not working, it is not even considering the CDN Style for the datatable. I like your datagrid and I know I can use it for this kind of development that I’m trying to do but what I miss with your datagrid is that I would like to have a search textbox that works more like the datatable and as per the video that I saw with your datagrid the user has to click on the column to do a search or a filter, maybe there is an easy way to do this which I don’t know, if you make an example or explain how to, it would be great, also I would like to see a counter under the datagrid as it is used by datatable if you are seeing 5 records of 20 it tells you at the bottom 5 records out of 20 something like this more or less . Thank again again Alex for taking your time to answer all my questions, I’m really enjoying NODERUN, a great idea that your company came with.

Hi again!

At the bottom of your file, I see:

<script type="text/javascript" charset="utf8" src="http://ajax.aspnetcdn.com/ajax/jQuery/jquery-1.8.2.min.js"></script>
<script type="text/javascript" charset="utf8" src="http://ajax.aspnetcdn.com/ajax/jquery.dataTables/1.9.4/jquery.dataTables.min.js"></script>

And when I run the app, in Chrome Developer Tools, I see:

image

So, the files were blocked. But when I change these links to https, the files are not blocked any more, and I can start to see the shape of a data table. However, there are more js errors in jquery.dataTables.min.js. As I am not familiar with the dataTables library, I am not sure what the real problem is. But the initial issue was related to not using https.

About using the NodeRun Rich Display Grid, I do have a full example of a “Customer CRUD with Search”. See here: https://noderun.com/alex/crud-with-search/.

It shows the page number at the bottom of the grid.

Alex