allow hotlinking to that resources to access media files like (png|jpg|jpeg)

Hi,

I have a website in WordPress and want to allow its media files to be accessed on some other website in embedded form. I have tried with few options to set headers in .platform.app.yaml file but its still not allowing to embed my WordPress sites of media files to some other website. Please see the attached screenshot of my .platform.app.yaml file.

Conclusion: I have a website say xyz.com hosted over platform.sh server and I want my sites media files can also be served through some other website say abc.com in such a way when abc.com  wants to display image from xyz.com  it should allow.

for eg.: from site abc.com  there is html content like: 

<p> Lorem ipsum is a dummy text. <img src="https://xyz.com/wp-content/uploads/2024/11/AvantGarde2-228x160.jpg" width="200" height="200" /></p>

Thanks in advance.

 

0

Comments

3 comments
Date Votes
  • As far as I know we don't do anything to prevent what you're describing. Can you give some specific examples and the specific errors you're seeing?

    0
  • Hi Paul,

    Thank you for your response.

    I’m attaching a screenshot to show an issue where I’m trying to embed an image from a source (mediaburn.org), which is hosted on the platform.sh server. Unfortunately, the image is not rendering and is resulting in a 403 Forbidden error.

    In my initial post, I included the configurations from the .platform.app.yaml file. If there are any additional configurations required to ensure the image from mediaburn.org can be served on the site, please let me know.

    Thank you for your assistance!

    0
  • I dont think this is a platform.sh issue, but a cloudflare issue, possibly a WAF rule? 

    Grab the value in the `Cf-ray` response header. Search the Firewall Logs under the Security tab on your Cloudflare Dashboard for this value. That will tell you what rule is possibly being triggered. 

    0

Please sign in to leave a comment.

 

Didn't find what you were looking for?

New post