<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Open Dropbox API Authorization request in a new Tab in Dropbox API Support &amp; Feedback</title>
    <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23162#M714</link>
    <description>&lt;P&gt;The API itself doesn't offer an option for this, as the&amp;nbsp;Dropbox API app authorization page is just a normal web page on the&amp;nbsp;Dropbox web site, so this would be more of a browser&amp;nbsp;behavior. That is, you can instruct the browser to open a link in a new tab/window (e.g., see these StackOverflow posts: &lt;A href="https://stackoverflow.com/questions/15551779/open-link-in-new-tab" rel="nofollow noreferrer"&gt;Open link in new tab&lt;/A&gt;, &lt;A href="https://stackoverflow.com/questions/6296013/how-can-i-open-a-link-in-new-tab-and-not-new-window" rel="nofollow noreferrer"&gt;How can I open a link in new tab (and not new window)?&lt;/A&gt;).&lt;/P&gt;

&lt;P&gt;Or, you can open the page in a popup window, like the &lt;A href="https://github.com/dropbox/dropbox-js/blob/stable/guides/builtin_drivers.md" rel="nofollow noreferrer"&gt;dropbox.js library does&lt;/A&gt;.&lt;/P&gt;</description>
    <pubDate>Wed, 05 Aug 2015 00:58:48 GMT</pubDate>
    <dc:creator>Greg-DB</dc:creator>
    <dc:date>2015-08-05T00:58:48Z</dc:date>
    <item>
      <title>Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23161#M713</link>
      <description>&lt;P&gt;I have a web application running on my local host and I am using&amp;nbsp;Dropbox&amp;nbsp;Core API in the web app to upload files. However, the Dropbox authentication page opens in the same tab in the browser as my webapp. Is it possible that I force Dropbox&amp;nbsp;API authorization webpage to open in a new tab? Is there a setting for this in Dropbox Core API?&lt;/P&gt;</description>
      <pubDate>Wed, 29 May 2019 09:40:44 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23161#M713</guid>
      <dc:creator>Humza A.</dc:creator>
      <dc:date>2019-05-29T09:40:44Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23162#M714</link>
      <description>&lt;P&gt;The API itself doesn't offer an option for this, as the&amp;nbsp;Dropbox API app authorization page is just a normal web page on the&amp;nbsp;Dropbox web site, so this would be more of a browser&amp;nbsp;behavior. That is, you can instruct the browser to open a link in a new tab/window (e.g., see these StackOverflow posts: &lt;A href="https://stackoverflow.com/questions/15551779/open-link-in-new-tab" rel="nofollow noreferrer"&gt;Open link in new tab&lt;/A&gt;, &lt;A href="https://stackoverflow.com/questions/6296013/how-can-i-open-a-link-in-new-tab-and-not-new-window" rel="nofollow noreferrer"&gt;How can I open a link in new tab (and not new window)?&lt;/A&gt;).&lt;/P&gt;

&lt;P&gt;Or, you can open the page in a popup window, like the &lt;A href="https://github.com/dropbox/dropbox-js/blob/stable/guides/builtin_drivers.md" rel="nofollow noreferrer"&gt;dropbox.js library does&lt;/A&gt;.&lt;/P&gt;</description>
      <pubDate>Wed, 05 Aug 2015 00:58:48 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23162#M714</guid>
      <dc:creator>Greg-DB</dc:creator>
      <dc:date>2015-08-05T00:58:48Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23163#M715</link>
      <description>&lt;P&gt;just by adding "_BLANK" attribute to &amp;lt;a&amp;gt; doesnot make this work. I doubt if this would be that straightforward. May be dropbox doesnot want its auth window to be opened in a new tab, otherwise what is the sense behind them asking for redirect uri.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Sep 2015 10:40:30 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23163#M715</guid>
      <dc:creator>Humza A.</dc:creator>
      <dc:date>2015-09-14T10:40:30Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23164#M716</link>
      <description>&lt;P&gt;You mean target="_blank", right? If that's not working for you,&amp;nbsp;perhaps you can share your code, but it sounds like purely an HTML issue. The Dropbox API doesn't know or care whether you open the&amp;nbsp;auth page in the same browser tab or a different one.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Sep 2015 11:35:27 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23164#M716</guid>
      <dc:creator>Steve M.</dc:creator>
      <dc:date>2015-09-14T11:35:27Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23165#M717</link>
      <description>&lt;P&gt;The code is the same as HelloWorld Dropbox code. &amp;nbsp;I have pasted it below.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;lt;!doctype html&amp;gt;&lt;BR /&gt;&amp;lt;html&amp;gt;&lt;BR /&gt;&amp;lt;head&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;script src="&lt;A href="https://www.dropbox.com/static/api/dropbox-datastores-1.0-latest.js%22&amp;gt;&amp;lt;/script" rel="nofollow noreferrer"&gt;https://www.dropbox.com/static/api/dropbox-datastores-1.0-latest.js"&amp;gt;&amp;lt;/script&lt;/A&gt;&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;link rel="stylesheet" href="style.css"&amp;gt;&lt;BR /&gt;&amp;lt;/head&amp;gt;&lt;/P&gt;
&lt;P&gt;&amp;lt;body&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;center&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;a id="writeButton" target="_BLANK" &amp;gt;Click to create hello.txt in Dropbox. &amp;nbsp; &amp;nbsp; &amp;lt;/a&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;&amp;lt;/center&amp;gt;&lt;BR /&gt; &lt;BR /&gt; &amp;lt;script&amp;gt;&lt;BR /&gt;&amp;nbsp; &amp;nbsp;var client = new Dropbox.Client({ key: '&amp;lt;your-app-key&amp;gt;' });&lt;BR /&gt; &lt;BR /&gt; function doHelloWorld() {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;client.writeFile('hello.txt', 'Hello, World!', function (error) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;if (error) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;alert('Error: ' + error);&lt;BR /&gt;&amp;nbsp; &amp;nbsp;} else {&lt;/P&gt;
&lt;P&gt;&amp;nbsp; &amp;nbsp;alert('File written successfully!');&lt;BR /&gt;&amp;nbsp; &amp;nbsp; }&lt;BR /&gt;&amp;nbsp; &amp;nbsp;});&lt;BR /&gt; }&lt;BR /&gt; &lt;BR /&gt; // Try to complete OAuth flow.&lt;BR /&gt; client.authenticate({ interactive: false }, function (error, client) {&lt;BR /&gt; if (error) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;alert('Error: ' + error);&lt;BR /&gt; }&lt;BR /&gt; });&lt;BR /&gt; &lt;BR /&gt; if (client.isAuthenticated()) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;doHelloWorld();&lt;BR /&gt; }&lt;BR /&gt; &lt;BR /&gt; document.getElementById('writeButton').onclick = function () {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;client.authenticate(function (error, client) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;if (error) {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;alert('Error: ' + error);&lt;BR /&gt;&amp;nbsp; &amp;nbsp;} else {&lt;BR /&gt;&amp;nbsp; &amp;nbsp;doHelloWorld();&lt;BR /&gt;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp;});&lt;BR /&gt; }&lt;BR /&gt; &amp;lt;/script&amp;gt;&lt;BR /&gt;&amp;lt;/body&amp;gt;&lt;BR /&gt;&amp;lt;/html&amp;gt;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Sep 2015 12:08:59 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23165#M717</guid>
      <dc:creator>Humza A.</dc:creator>
      <dc:date>2015-09-14T12:08:59Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23166#M718</link>
      <description>&lt;P&gt;Well yes, you're adding target="_blank" to an anchor tag&amp;nbsp;but then intercepting the click. &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@FBF7D2AB59A0D6E861EBF6A36F93B7E2/emoticons/1f642.png" alt=":slightly_smiling_face:" title=":slightly_smiling_face:" /&gt;&lt;/P&gt;
&lt;P&gt;It looks like you're using dropbox.js to open the auth page. Take a look at&amp;nbsp;&lt;A href="https://github.com/dropbox/dropbox-js/blob/stable/guides/builtin_drivers.md" rel="nofollow noreferrer"&gt;https://github.com/dropbox/dropbox-js/blob/stable/guides/builtin_drivers.md&lt;/A&gt;, which Greg linked to in his first response.&amp;nbsp;There you'll find the various options that the dropbox.js library&amp;nbsp;has implemented. I think the popup driver is probably your best bet. JavaScript can't force a page to open in a new tab versus a new window. (This is controlled by the browser and varies from browser to browser.)&lt;/P&gt;
&lt;P&gt;You could&amp;nbsp;use an actual anchor tag with target="_blank", but&amp;nbsp;this sort of thing isn't implemented in dropbox.js, so you'd be on your own to construct the right URL.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Sep 2015 12:39:15 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23166#M718</guid>
      <dc:creator>Steve M.</dc:creator>
      <dc:date>2015-09-14T12:39:15Z</dc:date>
    </item>
    <item>
      <title>Re: Open Dropbox API Authorization request in a new Tab</title>
      <link>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23167#M719</link>
      <description>&lt;P&gt;I do not care if its another window or another tab, only thing I wish is stop dropbox auth driver to do redirect on my web app, because that forces the app to refresh itself thus losing its flow.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I guess I will look into the pop-up driver then. Many Thanks for your help in this. &lt;img class="lia-deferred-image lia-image-emoji" src="https://www.dropboxforum.com/html/@FBF7D2AB59A0D6E861EBF6A36F93B7E2/emoticons/1f642.png" alt=":slightly_smiling_face:" title=":slightly_smiling_face:" /&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 14 Sep 2015 12:43:08 GMT</pubDate>
      <guid>https://www.dropboxforum.com/t5/Dropbox-API-Support-Feedback/Open-Dropbox-API-Authorization-request-in-a-new-Tab/m-p/23167#M719</guid>
      <dc:creator>Humza A.</dc:creator>
      <dc:date>2015-09-14T12:43:08Z</dc:date>
    </item>
  </channel>
</rss>

