Sauter la navigation

[En attente du retour de l'utilisateur] Showing Media File URL in View

This support ticket is created Il y a 4 jours et 20 heures. 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
- 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 10:00 – 13:00 -
- 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 14:00 – 18:00 -

Supporter timezone: Asia/Kolkata (GMT+05:30)

Ce sujet contient 1 réponse, a 1 voix.

Dernière mise à jour par Minesh Il y a 4 jours et 17 heures.

Assisté par: Minesh.

Auteur
Publications
#2808254
Screenshot 2025-05-09 at 9.56.10 AM.png

Hi,

I have a page on a client's website with multiple views set up. The one I'm having issues with is the top view on the page that is looping through the media library and showing the images that match the criteria set. It was working perfectly but lately I've seen that some of the images are broken. Each item in the view should be showing the image, then underneath a preview link (opens the image in a new tab) and a download link (downloads the image). The preview and download links are working, and most of the images are showing but some are broken. I've been working through the issue with an AI chatbot and I think it is because the image src is [wpv-post-url], which is WordPress's permalink without the file extension. Ideally, I would be able to make the src something like [wpv-file-url] but this doesn't exist.

Can you please advise how I would retrieve the file URL for the image? I tried <img src="[wpv-post-url].jpg"> (even though they won't always be jpg) but this didn't work as it made the src URL like ".../image-name/.jpg".

Also, the site seems to have some image optimiser as every image uploaded has "-scaled" added to it. Is there a way to retrieve the non-optimised one? I know it still exists because if you visit the URL without "-scaled" it shows up. I have example URLs below. Ideally, we would show the scaled version on the page, and the preview/download buttons would link to the non-scaled version.

Here is the URL of the page in question: lien caché

Scaled image: lien caché
Non-scaled image: lien caché

#2808265

Minesh
Supporter

Les langues: Anglais (English )

Fuseau horaire: Asia/Kolkata (GMT+05:30)

Hello. Thank you for contacting the Toolset support.

I need to check how exactly you setup your view and how exactly you are displaying the medai files.

*** Please make a FULL BACKUP of your database and website.***
I would also eventually need to request temporary access (WP-Admin and FTP) to your site. Preferably to a test site where the problem has been replicated if possible in order to be of better help and check if some configurations might need to be changed.

I have set the next reply to private which means only you and I have access to it.