title: TinyMCE file_picker_callback select image from default browser file selection
body: <p>Im using TinyMCE in a project and want the user to select and upload images to the server using its default insert image window.</p>
  
  <p>I want to click the following button:</p>
  
  <p><a href="https://i.stack.imgur.com/Zxs59.png" rel="noreferrer"><img src="https://i.stack.imgur.com/Zxs59.png" alt="enter image description here"></a></p>
  
  <p>Open the browsers default file select window and add the selected image to the editor:</p>
  
  <p><a href="https://i.stack.imgur.com/DVYxF.png" rel="noreferrer"><img src="https://i.stack.imgur.com/DVYxF.png" alt="enter image description here"></a></p>
  
  <p>My code so far is as follows..</p>
  
  <p>JS:</p>
  
  <pre><code>tinymce.init({
          selector: '#html-editor',
          language: 'pt_PT',
          plugins: [
              "bdesk_photo advlist autolink link image lists charmap preview hr anchor pagebreak",
              "searchreplace wordcount visualblocks visualchars code media nonbreaking",
              "table contextmenu directionality paste textcolor colorpicker imagetools"
          ],
          add_unload_trigger: false,
          toolbar: "styleselect | bold italic | alignleft aligncenter alignright alignjustify | bullist numlist outdent indent | link image media preview | forecolor backcolor table",
          image_advtab: true,
  
          file_picker_callback: function (callback, value, meta)
          {
              $('#html-editor input').click();
  
              //how to get selected image data and add to editor?
          },
  
          paste_data_images: true,
          images_upload_handler: function (blobInfo, success, failure)
          {
              // no upload, just return the blobInfo.blob() as base64 data
              success("data:" + blobInfo.blob().type + ";base64," + blobInfo.base64());
          }
      });
  </code></pre>
  
  <p>HTML:</p>
  
  <pre><code>&lt;div id="html-editor"&gt;
      &lt;input name="image" type="file" style="width:0;height:0;overflow:hidden;"&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>What kind of changes must i make to the <em>file_picker_callback</em> event in order to get the selected file and add it to the editor?</p>