Quote:
I tried that one but it didn't work
This is not informative !
Your browser have a developer console which show you error messages and problems in JS.
First of all you should spend some time to learn properly html, JS and Jquery.
W3Schools Online Web Tutorials[
^]
JavaScript Tutorial[
^]
jQuery Tutorial[
^]
Any html page is compound of a
<header> and a
<body>. This is html 101.
When you open a tag, you also must close it:
<title>njfhdf</title>
Js code should be enclosed in
<script> tags
JS lines should end with ';'
arr_val = $ ("#arr_val").val();
arr.append(arr_val);
Declaration of a variable must be done only once:
var arr = [];
var arr = []
Each one of those is enough to have a 'not work'.
And I have not even tried to see what your code is supposed to do.