title: Retrieve Firebase parent from .push
body: <p>I have the following code that creates a randomly generated parent in Firebase and stores a name and text like so:</p>
  
  <pre><code>    ref.push({
          name : myName,
          text : myText
      });
  </code></pre>
  
  <p>Then to retrieve the data, I use the <code>.on("child_added")</code>.
  However, I'm trying to retrieve firebase's randomly generated parents and set them as the id's of their respective elements. 
  Here is what I came up with so far: </p>
  
  <pre><code>    ref.on("child_added", function (snapshot) {
        var obj = snapshot.val();
        var parent = ...;
        $(".message").append('&lt;div id="'+ parent + '"&gt;&lt;/div&gt;');
     });
  </code></pre>
  
  <p>Thanks!</p>