• Resolved ernstwg

    (@ernstwg)


    Hi David.

    My copyright notice [+iptc:2#116+] looks like this © 2018 Ernst Wilhelm Grueter, ewgfoto@posteo.de. Is there a way to extract the email address in order to use it in case of a download at a later stage?

    Or do you have another recommendation to store the email-adress. To me it seems, not all IPTC fields are accessible in wordpress.

    Thank you very much, Ernst Wilhelm

Viewing 4 replies - 1 through 4 (of 4 total)
  • Plugin Author David Lingren

    (@dglingren)

    Thanks for an interesting question.

    I assume your email address does not change from file to file, so it would be easier to just enter it manually when you need it. Why bother to “extract it“?

    The answer may depend on what you mean by “use it in case of a download at a later stage“. Can you be more specific?

    You wrote “To me it seems, not all IPTC fields are accessible in WordPress.” The MLA iptc: prefix gives you access to all of the IPTC elements, and you could define a rule to, for example, copy the value to a WordPress custom field.

    If I have not understood your question, any further details you can provide will help me give you more specific guidance. Thanks.

    Thread Starter ernstwg

    (@ernstwg)

    David

    My comment about the completeness of IPTC Fields I am thinking of the email adress in the creator contact info. I have no idea how to get this piece of information, which can be set via Lightroom. So far I have not experience with word press custom fields. It sounds feasible, but how to get it?

    Why bother? Firstly, in a previous life I worked as a programmer. Hardcoded stuff is not preferred =D Second: I work with some other guys in a club of amateur photographers. When you think of a multi-user environment, it makes sense to have this information in the picture. I can control my own workflow by putting this information into a certain IPTC attribute. Other photographers may add this information as part of a field like description, copyright notice or similar. The idea is, to inform the photographer about a download as a kind of appreciation.

    Looking forward to your reply 🙂

    Plugin Author David Lingren

    (@dglingren)

    Thank you for clarifying your question. I was able to look at the metadata in one of your images and locate the information you need. From the IPTC documentation How IPTC Photo Metadata Evolved Over Time section:

    After development over two decades IPTC Photo Metadata can be embedded in the following ways:

    • IPTC Core fields can be embedded in the IIM format and/or in the XMP format. A key challenge for metadata embedded in parallel in IIM and XMP is that the values are synchronised – this should be taken care of by the image management software.
    • IPTC Extension fields can be embedded only in XMP format.

    MLA’s iptc: data sources are limited to the “Core Fields” because that is all the PHP function MLA uses to extract the data supports. The data you seek looks like this in the XMP metadata:

        'Iptc4xmpCore' => 
        array (
          'CreatorContactInfo' => 
          array (
            'CiAdrCity' => 'Hamburg',
            'CiAdrCtry' => 'Deutschland',
            'CiEmailWork' => 'ernst.grueter@gmail.com',
            'CiUrlWork' => 'https://ernst-wilhelm-grueter.de',
          ),
          'IntellectualGenre' => 'Demonstationen',
          'Location' => '2_Detail',
          'Scene' => 
          array (
            0 => '2_s',
          ),
          'SubjectCode' => 
          array (
            0 => 'Ostermarsch',
          ),
        ),
    

    You can use MLA’s xmp: data sources to get the email address. Since the address is buried within nested arrays you need to use a compound name to specify it:

    [+xmp:Iptc4xmpCore.CreatorContactInfo.CiEmailWork+]
    

    You can find more information about using compound names in the xmp: prefix section of the Documentation tab.

    Copying the email address to a custom field would make accessing it more efficient. TO do that, follow the steps in this recent topic:

    Combine image ISO, Shutter speed, Aperture with decription

    In those steps, replace “Change the Data Source dropdown to “post_content”.” with these two steps:

    • Change the Data Source dropdown to “– Template (see below) –“.
    • Enter ([+xmp:Iptc4xmpCore.CreatorContactInfo.CiEmailWork+]) in the Meta/Template text box.

    I hope that answers your question. I am marking this topic resolved, but please update it if you have any problems or further questions regarding the above suggestions. Thanks for your continued interest in the plugin.

    Thread Starter ernstwg

    (@ernstwg)

    Good Morning, David. Very helpful. Very grateful for your willingness and abilty to help. First time I understood myself the difference between IPTC and IPTC extensions and the different ways to access it.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘String extraction’ is closed to new replies.