Advanced search  

News:

cpg1.5.48 Security release - upgrade mandatory!
The Coppermine development team is releasing a security update for Coppermine in order to counter a recently discovered vulnerability. It is important that all users who run version cpg1.5.46 or older update to this latest version as soon as possible.
[more]

Pages: [1]   Go Down

Author Topic: Upload via Batch using Lightroom as Editor = no title  (Read 12029 times)

0 Members and 1 Guest are viewing this topic.

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Upload via Batch using Lightroom as Editor = no title
« on: January 20, 2012, 12:50:24 am »

Originally posted in the dev boards:

Hi guys

Been suffering with an issue for a while now.

I use Adobe lightroom to control my image workflow, and until now I have manually been amending files to allow me to populate the "headline" field in the IPTC Data, this is then copied to a network path (since my service is in my house) and I batch add the files using non browsable batch mode.

Looking at the IPTC which lightroom populates as their title, they use "Document Title"

Headline populated - http://widowmaker.is-a-geek.com/displayimage.php?album=11&pid=1743#top_display_media
Pure from lightroom - http://widowmaker.is-a-geek.com/displayimage.php?album=10&pid=1599#top_display_media

Attached are 2 files one with the Headline field populated and one straight from lightroom

Here is my website: http://widowmaker.is-a-geek.com

Any ideas?

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Logged

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #2 on: January 20, 2012, 09:47:35 am »

Hi Andre,

Unfortunatel, I have looked at that thread, and attempted to implement that change, however in my version of the code (cpg1.5.18) line 67 is shown as:

           } else {
                @unlink($uploaded_pic);
                $msg = sprintf($lang_db_input_php['err_fsize_too_large'], $CONFIG['max_upl_width_height'], $CONFIG['max_upl_width_height']);
                return array('error' => $msg, 'halt_upload' => 1);
            }
        }
Also when I search for that code, I find it is on line 48:

                $title = (isset($iptc['Headline'])) ? $iptc['Headline'] : $title;
                $caption = (isset($iptc['Caption'])) ? $iptc['Caption'] : $caption;
                $keywords = (isset($iptc['Keywords'])) ? implode($CONFIG['keyword_separator'], $iptc['Keywords']) : $keywords;

Having changed that line to "Title" as described, the issue is still apparent.

Any ideas?

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #3 on: January 20, 2012, 10:36:33 am »

Please attach an example photo with IPTC data from Adobe Lightroom and tell me the value of the "headline", so I can find the corresponding IPTC value.
Logged

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #4 on: January 20, 2012, 02:41:44 pm »

Here you go.

Note the "Headline" in IPTC is populated manually.

The field which should be populated is from the Exif : Title "Fantasy of Flight 2012"

Martin

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #5 on: January 20, 2012, 02:43:40 pm »

Attaching Screenshot of Title:


Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #6 on: January 20, 2012, 03:23:47 pm »

I just uploaded your picture to my test gallery and everything seems to work as expected. It automatically added the following meta data to the picture in Coppermine:
Quote
Title: Fantasy of Flight 2012
Description: January 2012 trip to Fantasy of Flight in Florida
Keywords: Fantasy of Flight 2012


Hardly surprising, as you said:
the "Headline" in IPTC is populated manually.
which is read by Coppermine. Maybe that was my fault, as I mixed up something.


Coppermine reads the following data from the file during upload:
Quote
Array
(
    [Title] => Fantasy of Flight 2012
    [Urgency] =>
    [Category] =>
    [SubCategories] =>
    [Keywords] => Array
        (
            [0] => Fantasy of Flight 2012
        )

    [Instructions] =>
    [CreationDate] => 20120105
    [CreationTime] => 165800
    [ProgramUsed] =>
    [Author] => Martin Pring
    [Position] =>
    [City] =>
    [State] =>
    [Country] =>
    [TransmissionReference] =>
    [Headline] => Fantasy of Flight 2012
    [Credit] =>
    [Source] =>
    [Copyright] => Copyright: All Images are Copyright of Martin Pring
    [Caption] => January 2012 trip to Fantasy of Flight in Florida
    [CaptionWriter] =>
)
I marked all occurrences of "Fantasy of Flight 2012" bold. As you don't want to manually amend your files, I assume changing
Code: [Select]
$title = (isset($iptc['Headline'])) ? $iptc['Headline'] : $title;back to
Code: [Select]
$title = (isset($iptc['Title'])) ? $iptc['Title'] : $title;in include/picmgmt.inc.php should fix your issue. Obviously that's the opposite of what we did here and you have to apply that change after each update.
Logged

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #7 on: January 20, 2012, 06:21:36 pm »

Hi Andre

I have just tested that change, and I am still unable to insert the title :S

Could you let me know how you got that array?

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #8 on: January 20, 2012, 06:24:52 pm »

Attached "test image"

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #9 on: January 20, 2012, 06:27:28 pm »

apologies that file is the wrong one

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #10 on: January 20, 2012, 06:38:00 pm »

I will need to test it further but I think if i make the "Caption" the title, this resolves the issue, I believe adobe are using caption for title from Lightroom, will test it when home,

Andre, could you confirm how I get that array info?

Martin

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #11 on: January 20, 2012, 07:02:56 pm »

Could you let me know how you got that array?
Open include/picmgmt.inc.php, find
Code: [Select]
$iptc = get_IPTC($image);and below, add
Code: [Select]
print_r($iptc); die();and use the single HTTP uploader.


Of course that change only affects files uploaded after the code change.
Logged

uk_tomcat_fan

  • Coppermine novice
  • *
  • Country: 00
  • Offline Offline
  • Posts: 20
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #12 on: January 20, 2012, 10:43:07 pm »

Thanks!

I have now fixed the issue by changing "Headline" back to "Title"

Αndré

  • Administrator
  • Coppermine addict
  • *****
  • Country: de
  • Offline Offline
  • Gender: Male
  • Posts: 15760
Re: Upload via Batch using Lightroom as Editor = no title
« Reply #13 on: January 21, 2012, 12:11:18 am »

Please
tag your answer as "solved" by clicking on the "Topic Solved" button on the bar at the left hand side at the bottom of your thread.
Logged
Pages: [1]   Go Up
 

Page created in 0.026 seconds with 19 queries.