title: Web Firebase Get Download URL of image from Storage to Display in Table
body: <p>I want to download the image from the Firebase storage, but I want it to be a button in a table, but I am not sure how to do that? Below is my JS:</p>
  
  <pre><code>    var email = sessionStorage.getItem("email");
  var rootRef = firebase.database().ref().child("users");
  rootRef.on("child_added", snap =&gt; {
  
      var medname = snap.child("MedName").val();
      var description = snap.child("description").val();
      var end = snap.child("End").val();
      var start = snap.child("Start").val();
      var type = snap.child("Type").val();
      var file = snap.child("fileName").val();
  
  var storageRef = firebase.storage.ref("users/file");
  storageRef.getDownloadURL().then(function(url) {
    window.alert(url);
  });
  $("#demo").append("&lt;tr&gt;&lt;td&gt;"+ medname +"&lt;/td&gt;&lt;td&gt;" + description + 
                          "&lt;/td&gt;&lt;td&gt;"+ type + "&lt;/td&gt;&lt;td&gt;" + start + 
                          "&lt;/td&gt;&lt;td&gt;" + end +"&lt;/td&gt;&lt;td&gt;&lt;/td&gt;&lt;/tr&gt;");    
  });
  </code></pre>
  
  <p>The name of the file gets saved into the database and <code>file.name</code>, then I retrieve that specific <code>file.name</code> and I want to get the URL download for that image from the storage and display that to the user in a table.</p>