Skip Navigation

[Resolved] Media Library Image Link Now Broken – Going To Image Page Instead

This support ticket is created 4 years, 3 months ago. There's a good chance that you are reading advice that it now obsolete.

This is the technical support forum for Toolset - a suite of plugins for developing WordPress sites without writing PHP.

Everyone can read this forum, but only Toolset clients can post in it. Toolset support works 6 days per week, 19 hours per day.

Sun Mon Tue Wed Thu Fri Sat
- 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 9:00 – 12:00 -
- 13:00 – 18:00 13:00 – 18:00 13:00 – 18:00 14:00 – 18:00 13:00 – 18:00 -

Supporter timezone: America/Jamaica (GMT-05:00)

This topic contains 6 replies, has 2 voices.

Last updated by brianS-5 4 years, 3 months ago.

Assisted by: Shane.

Author
Posts
#2048055

Hey!

So I'm not sure if it was an update that broke my View but I had created a View for the Post Type "Media" to create a gallery. In the loop template I had selected Post URL and wrapped it in <img> which was working. But now it's not because the Post URL is now displaying the media image's page not the direct image link.

This is the Loop:

<div class="images-grid">



[wpv-conditional if="( $(wpcf-link-back-to-house-plan) ne '' )"]

[ticon icon="home" size="22"]

[/wpv-conditional]
</div>

Right now it's outputting: /mbv2-41/
And it should be outputting: /wp-content/uploads/2020/08/MBV2-41.jpg

How can I fix this so that the <a> and <img> go to the full size image link?

This is the link to the page in question: hidden link

#2048107

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Brian,

Thank you for getting in touch.

I believe I understand the issue here as you are listing out the Posts from the Media Library Post type.

Would you mind allowing me to have admin access to the site so that I can have a look at this one for you in further details ?

Thanks,
Shane

#2048157

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Brian,

I see the issue but do you have a site where it is actually working ? Because clicking on the link takes me to a page like this.
hidden link

IF there is a site that this is working on I can have a look and see if I can identify any issues.

Thanks,
Shane

#2048169
incorrect URL.jpg
correct URL.jpg

It was working previously but now it's not, unfortunately I don't have another site as an example. Basically on the Gallery page it was displaying the media images themselves. When clicking on the image it would open a light box of the thumbnail.

The image links are redirecting to the page you mentioned because it's not working. So, the view changed from outputting the image URL (correct) to the attachment URL (incorrect). Does that make sense?

#2048237

Shane
Supporter

Languages: English (English )

Timezone: America/Jamaica (GMT-05:00)

Hi Brian,

I suspect that something might have changed on the website given that you say it was working. Are you able to temporarily disable all the non-toolset plugins and try again ?

I've done a test of this on my end and it worked fine on my test site. The images are showing when I add the URL to the img tag.

So I would recommend disabling your non-toolset plugins and checking.

Thanks,
Shane

#2050713

So it turned out that we had a redirect in place to point the media attachment URLs to the images themselves but it was removed. Added it back in and everything works. Thanks for your help!

#2050715

My issue is resolved now. Thank you!