example code of put html code in javascript to insert table by listen on a click
example code of put html code in javascript to insert table by listen on a click
![Forrest Ling](https://secure.gravatar.com/avatar/9fe3f5d477c2079d6e5d2286bf1be183/?default=https%3A%2F%2Fvanillicon.com%2F9fe3f5d477c2079d6e5d2286bf1be183_200.png&rating=g&size=120)
Link to test case:
Debugger code (debug.datatables.net):
Error messages shown:
Description of problem: Could any expert advise if I can put HTML
in javascript section to insert the table dynamically by clients clicking a button. ?
This discussion has been closed.
Replies
This is the sample code. Any example code of putting HTML of
<
table> combining with table data in JSON sent from server side to client <script> for rendering?
I want to put HTML
<
table> tags together with Table data in the ajax json response, is it possible?
Isn't valid Javascript.
Assuming you can target modern browsers use a template literal which makes multi-line string so much easier. Otherwise add a
+
concatenation operator between each string.Allan