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: Private Gallery in UserGallery  (Read 4333 times)

0 Members and 1 Guest are viewing this topic.

gismo

  • Coppermine newbie
  • Offline Offline
  • Posts: 8
Private Gallery in UserGallery
« on: June 05, 2005, 10:57:20 am »

Hi.

I have a little problem.

I have the UserGallery with 3 albums. All are privates.
So when a visitor com to the gallery...he isn't allowed to enter in this UserGallerie Categorie !

And when just an album is private....visitors can enter in the category but this private album is not displayed in !

I just want to display all the albums with the PRIVATE PICS in the thumbnails.

thx foryour help.
« Last Edit: June 07, 2005, 07:28:21 am by GauGau »
Logged

gismo

  • Coppermine newbie
  • Offline Offline
  • Posts: 8
Re: Private Gallery in UserGallery
« Reply #1 on: June 05, 2005, 12:01:33 pm »

...

how I can do, to display a private album in this category ?  :-\\
Logged

Nibbler

  • Guest
Re: Private Gallery in UserGallery
« Reply #2 on: June 05, 2005, 03:54:09 pm »

Have you tried the "Show private album Icon to unlogged user" option in config ?
Logged

gismo

  • Coppermine newbie
  • Offline Offline
  • Posts: 8
Re: Private Gallery in UserGallery
« Reply #3 on: June 05, 2005, 05:03:03 pm »

yé yé...I have put on "YES".

But...It's very hard to explain my problem....

Fox example :

In UserGallerie -> My Album -> Folder1
                                        -> Folder 2

If I put Folder 2 on PRIVATE......we can see the PRIVATE ICON.

If I put Folder 1 + Folder 2 on PRIVATE.......we cant' See Nothing ! We are Not allowed to enter in UserGalleries.
Logged

Joachim Müller

  • Dev Team member
  • Coppermine addict
  • ****
  • Offline Offline
  • Gender: Male
  • Posts: 47843
  • aka "GauGau"
    • gaugau.de
Re: Private Gallery in UserGallery
« Reply #4 on: June 05, 2005, 11:57:36 pm »

post a link and a screenshot how it looks for allowed users.
Logged

gismo

  • Coppermine newbie
  • Offline Offline
  • Posts: 8
Re: Private Gallery in UserGallery
« Reply #5 on: June 06, 2005, 02:39:03 pm »

OK

HERE you have screenshots step by step  ;)

Logged

Nibbler

  • Guest
Re: Private Gallery in UserGallery
« Reply #6 on: June 06, 2005, 09:08:51 pm »

Ah, I understand. Look in your index.php for the query:

Code: [Select]
        $sql = "SELECT user_id, " .
               "user_name, " .
               "COUNT(DISTINCT a.aid) as alb_count, " .
               "COUNT(DISTINCT pid) as pic_count, " .
               "MAX(pid) as thumb_pid " .
               "FROM {$CONFIG['TABLE_USERS']} AS u " .
               "INNER JOIN {$CONFIG['TABLE_ALBUMS']} AS a ON category = " . FIRST_USER_CAT . " + user_id " .
               "LEFT JOIN {$CONFIG['TABLE_PICTURES']} AS p ON (p.aid = a.aid AND approved = 'YES') ";
        if ($FORBIDDEN_SET != "") $sql .= "WHERE $FORBIDDEN_SET ";
        $sql .= "GROUP BY user_id " .
                "ORDER BY user_name";

and change it to this:

Code: [Select]
        $sql = "SELECT user_id, " .
               "user_name, " .
               "COUNT(DISTINCT a.aid) as alb_count, " .
               "COUNT(DISTINCT pid) as pic_count, " .
   ($FORBIDDEN_SET ? "IF ($FORBIDDEN_SET, MAX(pid), '0')" : 'MAX(pid)') ." AS thumb_pid " .
               "FROM {$CONFIG['TABLE_USERS']} AS u " .
               "INNER JOIN {$CONFIG['TABLE_ALBUMS']} AS a ON category = " . FIRST_USER_CAT . " + user_id " .
               "LEFT JOIN {$CONFIG['TABLE_PICTURES']} AS p ON (p.aid = a.aid AND approved = 'YES') ";
        $sql .= "GROUP BY user_id " .
                "ORDER BY user_name";
Logged

gismo

  • Coppermine newbie
  • Offline Offline
  • Posts: 8
Re: Private Gallery in UserGallery
« Reply #7 on: June 06, 2005, 09:24:47 pm »

WWhouaa !!!

Thank You Very Much !

SOLVED !

 ;) ;) ;) ;D
Logged
Pages: [1]   Go Up
 

Page created in 0.017 seconds with 19 queries.