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: Fetching image attributes (author, URL to gallery, title)?  (Read 6293 times)

0 Members and 1 Guest are viewing this topic.

Slideshow Bob

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
Fetching image attributes (author, URL to gallery, title)?
« on: September 05, 2006, 05:36:23 am »

Are there methods to return the author, gallery URL, or title of an image?

Here's a call to get an image name:   
    $imagename = $objCpm->getImageToUse($row['pFilepath'], $row['pFilename'] ,"normal_");

might there be corresponding functions to use to get the other info?
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: Fetching image attributes (author, URL to gallery, title)?
« Reply #1 on: September 05, 2006, 05:46:43 am »

Are there methods to return the author, gallery URL, or title of an image?

Here's a call to get an image name:   
    $imagename = $objCpm->getImageToUse($row['pFilepath'], $row['pFilename'] ,"normal_");

might there be corresponding functions to use to get the other info?


I *think* you can call it something like this:

$string = $objCpm->createDescription("%f",$row);

The result would be returned to the string.  the %f you would replace with the codes to get whatever you want.  See subtitles in the documentation. 

Hope that works

Logged
Please post for help to the forum... PM me only if you are sending security related items (passwords, security problems, etc).

cpmFetch - Images, RSS feeds from CPG from outside CPG
New release notification signup also. 
See http://cpmfetch.fistfullofco

Slideshow Bob

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
Re: Fetching image attributes (author, URL to gallery, title)?
« Reply #2 on: September 05, 2006, 03:39:09 pm »

Once again, you are the man!  :)  Thanks!!

Are there parameters to get the custom fields?
Logged

cgc0202

  • Coppermine frequent poster
  • ***
  • Offline Offline
  • Posts: 199
Re: Fetching image attributes (author, URL to gallery, title)?
« Reply #3 on: September 05, 2006, 03:51:44 pm »

Did it work for you Bob? Can you please share the complete script?  And, how the actual description that is stored in the database of CPG can be included also.

CGC
Logged

Slideshow Bob

  • Coppermine novice
  • *
  • Offline Offline
  • Posts: 20
Re: Fetching image attributes (author, URL to gallery, title)?
« Reply #4 on: September 05, 2006, 04:27:01 pm »

Yup.  Here's a page from the documentation where it shows all the values:

http://cpmfetch.fistfullofcode.com/php-lib/showexternal.php?url=http://www.fistfullofcode.com/projects/copperminefetch/manual/index.html

Check out Chapter 6. Using the OptionsArray
Logged
Pages: [1]   Go Up
 

Page created in 0.021 seconds with 19 queries.