Opened 3 years ago
Closed 2 months ago
#58647 closed defect (bug) (invalid)
wp_generate_attachment_metadata generates scaled images
| Reported by: | picard102 | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Review |
| Component: | Media | Version: | 6.2.2 |
| Severity: | major | Keywords: | close |
| Cc: | Focuses: |
Description
When using wp_generate_attachment_metadata() it seems to ignore the filter to turn off "big_image_size_threshold".
add_filter( 'big_image_size_threshold', 'return_false' );
$generateThumbs = wp_generate_attachment_metadata( $attachmentId, $file );
This results in a scaled version of the media being created and _wp_attached_file meta being replaced with the scaled versions path.
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
'return_false'is not a function. you need to use'__return_false', or justfalse.If it is still scaling, it is because something has forced conversion.
Closing this issue