title: jquery get all form elements attributes and values
body: <p>In the below html i want to read all the input elements of the form and get the custom field and the selected values or the input entered,how to do this?</p>
  
  <pre><code>function create()
  {
     $("form").each(function(){
       var elements = $(this).find(':input');
       for(var ele in elements)
       {
            console.log("++++++++++++")
            console.log(ele)
            console.log("++++++++++++")
       }
    }
  </code></pre>
  
  <p>}</p>
  
  <pre><code>&lt;form name="UserForm"&gt;
     &lt;input type="text" name="name1" readonly class="form-control" custom="input"/&gt;
     &lt;select  name="iType" id="iType" custom="SelectList"&gt;
        &lt;option value="3" selected&gt;school&lt;/option&gt;
     &lt;/select&gt;
     &lt;select multiple id="multi" id="multi" custom="multiselect"&gt;
        &lt;option value="1"&gt; 1&lt;/option&gt;
        &lt;option value="2"&gt; 2&lt;/option&gt;
        &lt;option value="3"&gt; 3&lt;/option&gt;
     &lt;/select&gt; 
     &lt;input type="checkbox" value="1" custom="checkbox" /&gt; 
     &lt;input type="radio" value="1"  custom ="radio" /&gt;
  &lt;/form&gt;
  </code></pre>