Community

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
emilycraddock
New Member

Open links in new tab

Jump to solution

How can you get web links to pictures to open in a new tab?

If I have an image that is hyperlinked to an external website, I'd like it to open in a new tab.  Currently, when editing it, there is not "load in a new tab" option when you hyperlink to pictures and it always opens in the same tab and replaces Canvas, which isn’t ideal. 

3 Solutions

Accepted Solutions
Stef_retired
Community Team
Community Team

emilycraddock​, to "force" a hyperlink to open in a new window or tab, the HTML of the page needs to be edited to insert a "new page" attribute. When editing the content page, click on the HTML Editor link at the upper right to switch to the HTML view for the page, then insert the target="_blank" attribute immediately after the quotation marks that end the URL. The code for a link to a picture of Toompea Castle on Wikimedia Commons looks like this:

<p><a href="https://upload.wikimedia.org/wikipedia/commons/7/79/Toompea_loss_2014.jpg" target="_blank">Toompea Castle, Talinn, Estonia</a></p>

View solution in original post

Stef_retired
Community Team
Community Team

Thanks to a recent post by  @biray ​, I learned about another--easier--way to force links to open in a new window/tab--and this alternative method doesn't require any HTML editing.

Click on the hyperlink or highlight the words you want to change into a link, and then click Ctrl-K. This will open a pop-up window on the text that you want to link (or if you've already linked your text it will allow you to edit the link) where you can select the target to "open link in a new window" from the drop-down.

I've just tested this in a sandbox course, and it works like a charm!

View solution in original post

I'm frustrated that THIS is not the post that was promoted as the Correct Answer, as, clearly, it is. Thanks!

View solution in original post

17 Replies
Stef_retired
Community Team
Community Team

emilycraddock​, to "force" a hyperlink to open in a new window or tab, the HTML of the page needs to be edited to insert a "new page" attribute. When editing the content page, click on the HTML Editor link at the upper right to switch to the HTML view for the page, then insert the target="_blank" attribute immediately after the quotation marks that end the URL. The code for a link to a picture of Toompea Castle on Wikimedia Commons looks like this:

<p><a href="https://upload.wikimedia.org/wikipedia/commons/7/79/Toompea_loss_2014.jpg" target="_blank">Toompea Castle, Talinn, Estonia</a></p>

Awesome- I tried it and it worked right away. Thanks!

Stef_retired
Community Team
Community Team

Thanks to a recent post by  @biray ​, I learned about another--easier--way to force links to open in a new window/tab--and this alternative method doesn't require any HTML editing.

Click on the hyperlink or highlight the words you want to change into a link, and then click Ctrl-K. This will open a pop-up window on the text that you want to link (or if you've already linked your text it will allow you to edit the link) where you can select the target to "open link in a new window" from the drop-down.

I've just tested this in a sandbox course, and it works like a charm!

Hi Stefanie - thanks so much for this!  But when i tried it on my Mac, it was Command-K, not Ctrl-K.....then it worked great......

Ah, yes, nlatimer​, Mac, how could I possibly have forgotten about Mac??! :smileylaugh: Thanks for sharing that!

Nice! I love a good keyboard shortcut I didn't already know about.

lmd5
New Member

This does not force the app to open in a browser window.

I'm frustrated that THIS is not the post that was promoted as the Correct Answer, as, clearly, it is. Thanks!

This worked Brilliantly!