[wp-trac] [WordPress Trac] #32378: Image Uploads automatically puts "Olympus Digital Camera" as caption

WordPress Trac noreply at wordpress.org
Fri Jul 27 17:52:28 UTC 2018


#32378: Image Uploads automatically puts "Olympus Digital Camera" as caption
-------------------------------------------------+-------------------------
 Reporter:  vparkhere                            |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Future
                                                 |  Release
Component:  Media                                |     Version:  4.2
 Severity:  normal                               |  Resolution:
 Keywords:  dev-feedback needs-unit-tests has-   |     Focuses:
  patch                                          |
-------------------------------------------------+-------------------------

Comment (by mattday):

 Just wondering what needs to happen now for this to make it into core.

 I appreciate it may be a non-issue for some professional photographers,
 although I believe it is a real annoyance for average users. Some people
 just want take a JPG file off their camera and upload it to their site. So
 it would be splendid if the title and caption were not automatically set
 to 'OLYMPUS DIGITAL CAMERA'.

 The last patch by @dmsnell looks good to me. It is very generic and can
 still be applied without modification to 4.9.7. However, it did not work
 for me. In debugging, I found it was necessary to tweak the pattern
 strings slightly for the preg_match. I then tested on a number of images
 from different Olympus and non-Olympus cameras.

 One thing I found through the testing was that taking the file name
 directly from the EXIF field is not ideal. The resulting names are
 inconsistent with images uploaded from other cameras, because they include
 the ".jpg" extension at the end. I further modified the patch to address
 this and have attached an
 [https://core.trac.wordpress.org/attachment/ticket/32378/32378-4.patch
 updated version].

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/32378#comment:18>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list