How to link images to a URL if image preview is enabled
Asked by Dave Rook:

I'm struggling with something that should be very simple. All I want to do is make an image clickable, so when the users clicks the image they are directed to a URL.

When in edit mode, if I click an image I get the option to add a Web Link, it saves but doesn't do what it suggests because when I test my changes (not logged in) the URL has been overridden with the image preview.

This is basic functionality (nearly every web page I can think of has a company logo which when clicked returns the user to the home page) and as such, I'm convinced I'm doing something wrong, Can some one help?


Answers:
author: Dave Rook
body: We had a plug in that was overriding the default behaviour (lightbox)


author: Thomas Schlegel
body: Hi [@Dave Rook](/t5/user/viewprofilepage/user-id/1179489) ,

it should work like this:

Add an image to your page, select it and click on "Link":

![image.png](https://community.atlassian.com/t5/image/serverpage/image-id/60033iCE2F083FCDAF92ED/image-size/large?v=v2&px=999 "image.png")

Add a Weblink and insert it:

![image.png](https://community.atlassian.com/t5/image/serverpage/image-id/60035i354E0321B0912EE8/image-size/large?v=v2&px=999 "image.png")

Save the page. Clicking the image should lead you to the web address.

comments: author: Dave Rook
body: Hi [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483)

That is the process I (tried to) described. I am doing exactly what you've shared.

The issue is, after I log out and return to the page (simulating someone visiting my web page), when i click the link, it shows an image preview (the image only in the browser).


author: Thomas Schlegel
body: Do you link to a webpage or to another Confluence page?


author: Dave Rook
body: Another confluence page (different URL), via the Web link. [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483)

The destination web link is on another domain

eg, linking from

mysite.com/page

to

someOtherSiteThatWeOwn/page2


author: Thomas Schlegel
body: That's a strange behaviour. I tested it again in my environment, also as an anonymous user and it works perfectly.

Just for clarification: you are using Confluence Server, right?

What do you see in your browser's footer, when you hover over your image? The link to someOtherSiteThatWeOwn/page2?

Which Browser are you using?


author: Dave Rook
body: Chrome.

If you're not seeing it, then perhaps it's something controlled/configured on the admin side (which I don't have access too)... I will chat with IT now I know this seems like it is not a confluence issue


author: Dave Rook
body: It turned out it's something to do with a plugin called Lunchbox that is overriding the behaviour. Thanks for your help [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483)


author: Thomas Schlegel
body: You're welcome, [@Dave Rook](/t5/user/viewprofilepage/user-id/1179489) - great that you found the problem!


author: Saeed Hessami
body: [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483) I am trying to do the same - linking an image to a URL. However, I don't even see the link option when I click on the image. I am using the cloud version of Confluence.

Appreciate your help.


author: Thomas Schlegel
body: Hi [@Saeed Hessami](/t5/user/viewprofilepage/user-id/2651113) ,

on Cloud, it should be exactly the same. I just tried it and it looks like this:

![image.png](https://community.atlassian.com/t5/image/serverpage/image-id/66880iEA9899784B3EC63F/image-size/large?v=v2&px=999 "image.png")

* Edit the page
* Select the image
* and then you should see the buttons


author: Saeed Hessami
body: Thanks [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483) for your response. I tried it again and the same issue. Then I created another page but this time I did not choose the option I had selected the first time and this time when I inserted an image I could see what you see.

I created the page I had an issue with using the selection shown in the screenshot below:

![Confluence.PNG](https://community.atlassian.com/t5/image/serverpage/image-id/66923iF40C0D477A7C6CC9/image-dimensions/560x303?v=v2 "Confluence.PNG")

I assume this page handles images differently.

Thanks for your patience and help.


author: Thomas Schlegel
body: You're welcome, [@Saeed Hessami](/t5/user/viewprofilepage/user-id/2651113)


author: AMT
body: Hello, [@Thomas Schlegel](/t5/user/viewprofilepage/user-id/781483)

I seem to be having the same issue as Saeed Hessami in the thread above. My image is a JPEG. As you can see I don't have an option to link the URL to the image. Your assistance is appreciated. Thank you.

![2020-04-16_17-15-06.jpg](https://community.atlassian.com/t5/image/serverpage/image-id/90822iE063AC208E6170A3/image-size/large?v=v2&px=999 "2020-04-16_17-15-06.jpg")


author: Rahul Kumar
body: [@AMT](/t5/user/viewprofilepage/user-id/3707276) I am also facing the same issue.


Tags: confluence-server

server