Good evening, please tell me what you need to register in the add function to pass the test data array?
The form:
<form action="" method="post" onsubmit="add();return false;"> Тест поле1: <input type="text" value="..." name="test[name]" /><br/> Тест поле2: <input type="text" value="5" name="test[price]" /><br/> <input type="submit" value="Добавить" /> </form>