Closed GoogleCodeExporter closed 9 years ago
Can't be done. See
http://stackoverflow.com/questions/4907843/open-a-url-in-a-new-tab-using-javascr
ipt, especially answer by cupcake.
Original comment by steven3...@gmail.com
on 19 Aug 2014 at 9:02
Using Google Chrome browser, right-clicking on a download link and choosing
'Open link in new tab' should work; a new tab is opened, but no content is
loaded. This is because the download link is unprocessed, it is an URL that
looks like,
http://patron.api.overdrive.com/v1/patrons/me/checkouts/A4322244-1C5C-46FB-81F8-
F745B8C6A877/formats/ebook-overdrive/downloadlink?errorpageurl={errorpageurl}&od
readauthurl={odreadauthurl}
ie, it is still a link template. Clicking on the link processes the link into
an URL that works, the template variables are filled in and the URL is changed
to a proxy address where on the server it is reverse-proxied.
Original comment by steven3...@gmail.com
on 25 Aug 2014 at 6:58
Fixed by not trying to process the clicking of the content link using
Javascript. Instead, we use an action dialogue box to guide the user through
the process, and we render the content link as a direct link to allow the user
to right-click it. The content link has a 60 seconds expiration time, so we
want to automatically close the dialogue box before it expires. See comment in
issue 10 on this and on how errors arising from the download process is handled.
Original comment by steven3...@gmail.com
on 15 Sep 2014 at 7:56
Original issue reported on code.google.com by
steven3...@gmail.com
on 18 Aug 2014 at 10:51