title: Use Javascript to open download link when feed dialog box is successfully shared?
body: <p>Can someone please explain to me how can I have a download link appear when a user presses the share button on a feed dialog box? I'm using the following code: (with my own information of course)</p>
  
  <p>
      
      
      <p>Post to Feed</p>
      </p></p>
  
  <pre><code>&lt;script&gt; 
    FB.init({appId: "YOUR_APP_ID", status: true, cookie: true});
  
    function postToFeed() {
  
      // calling the API ...
      var obj = {
        method: 'feed',
        link: 'https://developers.facebook.com/docs/reference/dialogs/',
        picture: 'http://fbrell.com/f8.jpg',
        name: 'Facebook Dialogs',
        caption: 'Reference Documentation',
        description: 'Using Dialogs to interact with users.'
      };
  
      function callback(response) {
        document.getElementById('msg').innerHTML = "Post ID: " + response['post_id'];
      }
  
      FB.ui(obj, callback);
    }
  
  &lt;/script&gt;
  </code></pre>
  
  <p></p>
  
  <p>I have no clue on how to do is: what code do I need so that when a user clicks "share" a download box appears? But if they click cancel a message pops up telling them they need to share first? I have posted a similar question before and I got an answer saying I need to use some sort of JavaScript but the problem is I don't know how or what to write? Can someone please show and explain the sort of JavaScript I need to me because I don't know how to use JavaScript one bit.</p>
  
  <p>Thanks in advance for any answers/help!!</p>