Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When images are stored externally to WordPress, you should be able to add a custom URL #22

Open
antekera opened this issue Mar 6, 2017 · 11 comments

Comments

@antekera
Copy link

antekera commented Mar 6, 2017

Hi i´ve installed this plugin and set up my domains correctly, my wordpress images are saving in https://img.noticiascol.com/2017 and images are being saved by imgix but i cant make this work, do i need to do something else? modify wordpress theme or something? images in imgix are serving ok.

https://img.noticiascol.com/2017/03/pasaporte-300x230.jpg
https://ncol.imgix.net/2017/03/pasaporte-300x230.jpg

@thisislawatts
Copy link
Collaborator

Hey @antekera

Thanks for reporting this issue. Once you've activated the plugin it will rewrite all image urls hosted on your WordPress domain to point at the imgix URL.

I can see that all your images are hosted on a separate subdomain, img.noticiascol.com. How have you set this up?

Thanks again, Luke

@antekera
Copy link
Author

antekera commented Mar 7, 2017

I've set up the plugin this way: http://bit.ly/2mAIVQu

My WP version is 4.7.3.

@thisislawatts
Copy link
Collaborator

Thanks for sending that across Miguel.

Have you got any other plugins that are doing something with the images?
Your images are all served from the subdomain img.noticiascol.com, this could be the cause of the issue.

This plugin attempts the following, using the WordPress URL:

  1. Identify an image URL eg. https://wordpress.url/example.jpg
  2. Replace's WordPress URL part with imgix URL.

So we would rewrite a URL as:
https://wordpress.url/example.jpg

https://wordpress.imgix.net/example.jpg

What are your URLs here set as:

wordpressurls

@antekera
Copy link
Author

antekera commented Mar 7, 2017

This way: https://cl.ly/jSHY

These are my active plugins:

  • Ajax Load More
  • CloudFlare Flexible SSL
  • Force SSL
  • Jetpack by WordPress.com
  • SSL Insecure Content Fixer
  • WP Super Cache

@thisislawatts
Copy link
Collaborator

thisislawatts commented Mar 7, 2017 via email

@thisislawatts
Copy link
Collaborator

Hey @antekera,

Did you manage to get to the bottom of this issue at all?

@antekera
Copy link
Author

antekera commented Mar 8, 2017

I made some tests and disable all plugins but still not working.

@thisislawatts
Copy link
Collaborator

Thanks @antekera. After disabling the other plugins, can you confirm what the image URLs were. For example on this single post page?
https://www.noticiascol.com/2017/03/08/mataron-a-adolescente-zuliano-en-barranquilla

@antekera
Copy link
Author

antekera commented Mar 9, 2017

The image url in this post is this:
https://img.noticiascol.com//2017/03/sijinx.jpg_1609701233-660x440.jpg

@thisislawatts
Copy link
Collaborator

OK, so I'm guessing that within imgix your Web Folder is set up as something like https://img.noticiascol.com? Trying to load an image that's on the same server as WordPress returns an error. eg. https://ncol.imgix.net/wp-content/themes/ncol/library/images/favicon.png

Currently the plugin is making the assumption that your images will be stored on the same server as the WordPress instance. However as all your images are being offloaded to img.noticiascol.com you need to be able to set a custom string that get's replaced.

I will update the issue title slightly and mark it as a feature request. Would you like to write this functionality and submit a PR? Alternatively I will aim to pick it up ASAP.

@thisislawatts thisislawatts changed the title Not working When images are stored externally to WordPress, you should be able to add a custom URL Mar 10, 2017
@urlexsven
Copy link

Hello,

was there any update in regards of this "feature request" after the fact?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants