title: JQuery Convert Date fromat
body: <p>I want to convert date from Format 'dd/MM/yyyy' to 'MM/dd/yyyy' and vice-versa</p>
  
  <p>I tried following method for conversion</p>
  
  <pre><code>var val1 = '1/2/2014';
  var newDate1 = new Date(val);
  
  alert(newDate1); //returns Thu Jan 02 2014
  
  var val2 = '2/1/2014';
  var newDate2 = new Date(val);
  
  alert(newDate2); // returns Sat Feb 01 2014
  </code></pre>
  
  <p>It is always considering above values in 'MM/dd/yy' format, in one case i need to take date format as 'dd/MM/yy' and convert it to some other</p>
  
  <p>Is it possible to define the 'Date format' of the 'Date' we are going to convert?</p>
  
  <p>Please suggest..</p>