Adding an item to array by code (JS)


  • This item was already here
<!-- Adds a new item to specified array, with the following specified data. -->
<form>
  <ul data-array="Items" id="somearray">
    <li data-func="input" data-name="Title" data-placeholder="Enter a title">This item was already here</li>
  </ul>
</form>
var $form = $("form").smartform();
$form.AddItem($("#somearray"), {Title:"This is an inserted item"});

Output templates

Templates used for document and web page generation:

Friendly Name File Name Template