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

Featured Images links have not been updated #1

Open
duetg opened this issue Oct 3, 2023 · 3 comments
Open

Featured Images links have not been updated #1

duetg opened this issue Oct 3, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@duetg
Copy link

duetg commented Oct 3, 2023

Hi, I found it used 'the_content' in the code. That can not update links in featured image which use the <figure> tag outside the content.

@BennyThink BennyThink added the bug Something isn't working label Feb 8, 2024
@n0vad3v
Copy link
Member

n0vad3v commented Feb 8, 2024

Apologies for the delayed response due to an oversight on our part. We're now actively addressing the issue you raised. Thank you for your patience.

In our demo Wordpress site, https://wordpress.webp.se/fk7-running-shanghai-tianma/ our featured image is using post-thumbnail class, could you please provide an example of your case that we could address it precisely?

@duetg
Copy link
Author

duetg commented Feb 9, 2024

The theme is the Twenty Twenty-Four and was Twenty Twenty-Three before. They can be modified by the block-editor. There are many kinds of blocks could be added to the page and the featured image which I mentioned is one of them. So that kind of featured image is not a part of post. It is using wp-block-post-featured-image class, and the sector of the image is also not in the_content (<main>), it is independent which using <figure> tag.
It is like this:
<figure class="wp-block-post-featured-image"><img ...></figure>
Twenty Twenty-Four is the stock theme which is shipped with wordpress code. For this reason I think it is better that the plugin should be compatible with it. Thanks.

@n0vad3v
Copy link
Member

n0vad3v commented Feb 10, 2024

Thanks for update, we'll look into this more.

Recently we've found a workaround for this that works even better than our plugin at the moment, by utilizing a famous plugin called WP Super Cache, the plugin contains another plugin called OSSDL CDN off-linker. (However that plugin itself seems not working in our dev environment).

OSSDL CDN off-linker has been integrated into WP Super Cache to provide basic CDN support.

Workaround is as below, suppose you:

  1. Have WP Super Cache installed and enabled
  2. Your site URL is https://duetg.com/
  3. Your images URL is https://duetg.com/wp-content/uploads/2023/10/teams-access-newway-diagram-1024x495.jpg, this should be the same as your site URL if your images are inserted using Wordpress's Media library
  4. Your Proxy Address on WebP Cloud Services is https://abc.webp.ee

Then you can configure WP Super Cache plugin as below:

  1. Site URL: https://duetg.com
  2. Off-site URL: https://abc.webp.ee
  3. Include directories: wp-content/uploads
  4. Exclude if substring: .php,.css,.js

Screenshot 2024-02-10 at 14-17-30 WP Super Cache ‹ WebP Cloud Services Wordpress Demo — WordPress

Please pay special attention to Include directories and Exclude if substring part, to make sure only images URL under wp-content/uploads are changed to WebP Cloud Services

In the configuration above, all images in posts and featured image will be changed accordingly, example site(with twentytwentythree theme):

  1. https://wordpress.webp.se/fk7-running-shanghai-tianma/
  2. https://wordpress.webp.se/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants