title: convert base64 to image in javascript/jquery
body: <p>I have written some code for image capturing using javascript/jquery 
  Below is the code:</p>
  
  <pre><code>function capture_image(){ 
      alert("capture_image");
      var p = webcam.capture();
      webcam.save();           
      alert("capture complete "+p); //getting true here
  
  
       var img = canvas.toDataURL("image");
      var item_image = img.replace(/^data:image\/(png|jpg);base64,/, "") ; 
      alert("item_image"+item_image);
  }
  </code></pre>
  
  <p>The item_image print the base64 format,
  How to convert that base64 to image and how to use that path in javascript clientside.</p>
  
  <p>Am searching google so many websites but its not working and that code is not suitable for my requirement.</p>