Advanced search  

News:

CPG Release 1.6.26
Correct PHP8.2 issues with user and language managers.
Additional fixes for PHP 8.2
Correct PHP8 error with SMF 2.0 bridge.
Correct IPTC supplimental category parsing.
Download and info HERE

Pages: [1]   Go Down

Author Topic: Creating Album List with CPMFetch possible?  (Read 5014 times)

0 Members and 1 Guest are viewing this topic.

bngMONSTER

  • Coppermine newbie
  • Offline Offline
  • Gender: Male
  • Posts: 4
Creating Album List with CPMFetch possible?
« on: December 16, 2006, 03:16:39 pm »

Hi!
is it possible to create a list of all albums in my gallery with CPMFetch
sortet A->Z
and the category behind the album in a table?

like this?

| Albumname1 (link to album)| category of Album 1 (link to category) |

| Albumname2 (link to album)| category of Album 1 (link to category) |

| Albumname2 (link to album)| category of Album 1 (link to category) |


other way to do that?
greetz MONSTER
PS Antwort in Deutsch geht auch :)
Logged

vuud

  • Moderator
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 1803
  • [cpmfetch.fistfullofcode.com]
    • Fist Full Of Code
Re: Creating Album List with CPMFetch possible?
« Reply #1 on: December 16, 2006, 07:59:11 pm »

Hi!
is it possible to create a list of all albums in my gallery with CPMFetch
sortet A->Z
and the category behind the album in a table?

like this?

| Albumname1 (link to album)| category of Album 1 (link to category) |

| Albumname2 (link to album)| category of Album 1 (link to category) |

| Albumname2 (link to album)| category of Album 1 (link to category) |


other way to do that?
greetz MONSTER
PS Antwort in Deutsch geht auch :)

I have a client that has a requirement similar to that for a project I am working on.  Fortunately that functionality will then be passed back into the development release.

But for now, cpmFetch does not have anything like that...


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

niks_007

  • Coppermine regular visitor
  • **
  • Offline Offline
  • Posts: 73
Re: Creating Album List with CPMFetch possible?
« Reply #2 on: December 19, 2006, 09:33:12 pm »

hi i did similer thing what you are asking hope can help you.

Code: [Select]
    <?
include "cpmfetch.php";
$objCpm = new cpm('/wallpapers');
$objCpm->cpm_setReturnType("resultset");
$data = $objCpm->cpm_viewLastAddedMediaFrom(1000, 1000, "cat=6,18");

$cnt = 0;
$arrayofalbums = array();

foreach ($data as $row) {
if (! in_array($row['aTitle'],$arrayofalbums))
{
?>
<a href="wallpapers/thumbnails.php?album=<? print $row['pAid']; ?>"> <?
print $row['aTitle'];
print '</a>';
print "";
print "\n";
array_push($arrayofalbums,$row['aTitle']);
$cnt++;
print "<br>";
if ($cnt == 6) break;
}
}
$objCpm->cpm_close();
?>

This displays the list of albums from seleted category but you can leave this blank to get if from all categories.

Thanks
Niks
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 19 queries.