ddur
Forum Replies Created
-
Yes, I can help you.
Change
public function on_intermediate_image_sizes_advanced_minus100_filter( $sizes, $metadata ) {to
public function on_intermediate_image_sizes_advanced_minus100_filter( $sizes, $metadata = false ) {That should fix your problem until next update.
Forum: Plugins
In reply to: [Regenerate Thumbnails] All SVG files were removed after plugin workUnfortunately, WP 5.3, and above, is removing all $image_meta[sizes] on regenerate.
I guess, SVG media should never be regenerated. At least because there is nothing to be regenerated.
1) AFAIK, there is no class-editor that supports SVG
2) SVG is supposed to be “all-sizes-fit”
3) No sizes needed for SVG.Forum: Plugins
In reply to: [Regenerate Thumbnails] missing and cropped imagesMaybe?
https://github.com/Automattic/regenerate-thumbnails/issues/102- This reply was modified 6 years, 2 months ago by ddur.
Please take look at rewrite rules examples and links in plugin “Help”, top-right on settings page.
Actually, when you apply server rewrite rules (see plugin help on settings page), browsers that do send “image/webp” in the HTTP: “Accept:” header, will be automatically served with “WebP” image, which is created both for “original image” and for “thumbnails” (other image sizes).
Thanks @thomaskr.
Rewrite rules may or may not work for every CDN, depends on CDN configuration. If “Vary Accept” header is sent from your server and your CDN service obeys it, correct image is sent to client browser.
https://www.igvita.com/2013/05/01/deploying-webp-via-accept-content-negotiation/
Unfortunately, detecting browser capability is not a problem that can be solved with simple and fast solution using either rewrite rules or PHP. Not all major browsers/versions will send “Accept: image/webp” header, even when they do support webp images.
Tag <picture> is planned for the future release, because it should work via every CDN. But, this solution still leaves out CSS or JS applied images as problem to solve with rewrite-rules (and HTTP-headers) whether using CDN or not.
@ddur, please don’t write the same in all topics. This is the second topic.
The get_avatar() issue is only related to 1-2 plugins’ conflict, nothing more. So please don’t search this rare conflict in all support topics. Again, it has no any relation to the get_avatar() function ad this conflict is already fixed in upcoming version.I’m trying to help your customer which have paid for your plugin and cannot use Simple History along with wpDisguz.
Thanks for future fixing of that issue.
BTW two topics is not all topics
Handling get_avatar is triggering fatal error (PHP7.4) which can cause next (or by ajax invoked) code in other plugins not to execute, resulting in random/unexpected failures.
- This reply was modified 6 years, 2 months ago by ddur.
For all hard to explain errors in other plugins (involving users and gravatars), caused by or related to wpDiscuz, test if problem disappears when changing user avatars to anything else than “Gravatar Logo” in Admin menu -> Settings -> Discussion.
Because wpDiscuz is doing some deep sh#t in handling ‘get_avatar’ filter and denies a problem (blames other plugins) for more than year now:
- This reply was modified 6 years, 2 months ago by ddur.
Forum: Plugins
In reply to: [Comments - wpDiscuz] WPDiscuz causing errorsTry to change user avatars from Gravatar Logo to anything else.
I believe it may help. See: Admin menu -> Settings -> DiscussionWordPress media editor, by WP design, preserves original image compression & quality as source for all theme sizes/thumbnails and for image editor (crop/flip/resize).
Compression applies only on images derived from original, not on original.
Else each “regenerate thumbnails” from compressed original image would further degenerate quality of derived thumbnails (would not be repeatable with same result as first time after upload).In example, regenerating thumbnails from 50% reduced original would generate 50% of 50%, which is 25% quality.
In addition, original would loose quality each time is re-compressed again.
Solution: Do not use original on the www, use one of generated sizes/thumbnails or WebP image created from original.
- This reply was modified 6 years, 3 months ago by ddur.
Actually your images are quite small.
If you are looking for the speed improvement, there are other opportunities to speed your site up.
In “thumbnail_image” function prototype, $filter is set to default value (FILTER_TRIANGLE), which is AFAIK, never set by calling functions.
So, if no caller is ever setting other values, default value is always used.
To have other value as default, in function “thumbnail_image”, change $filter_name = ‘FILTER_TRIANGLE’ to whatever value you want.
That is in deriving class file
…./plugins/warp-imagick/classes/class-warp-image-editor-imagick.phpYou will find by WP accepted filter values in original class
…./wp-includes/class-wp-image-editor-imagick.php
function thumbnail_imageHowever, I would only increase jpeg image quality, in plugin settings.
In the code, you may try/experiment with increased image quality settings only when thumbnail image has smaller geometry/size. Then you may get better quality, but larger file. At your personal taste.
Forum: Plugins
In reply to: [SAM Pro (Free Edition)] SAM Pro Lite or SAM Pro Free?Thanks