Urgent! Registered User Access only ONE album Urgent! Registered User Access only ONE album
 

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

Main Menu

Urgent! Registered User Access only ONE album

Started by cayne, April 13, 2004, 10:46:43 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

cayne

Hey folks,
I really need some help. I have a gallery with some albums - and now I need 1 album which should be only viewable with a registered user-account.

I already saw this method:

if (!USER_ID) cpg_die(ERROR, 'You need to register to access this page', __FILE__, __LINE__);

But I think that this line includes ALL albums on my gallery, but I want to restrict only one.

Big thanks in advance.

hyperion

No code editing required.

Enter admin mode.  Go to the album you want to restrict.  Click 'Properties'.  Change the viewable status to registered users only.
"Then, Fletch," that bright creature said to him, and the voice was very kind, "let's begin with level flight . . . ."

-Richard Bach, Jonathan Livingston Seagull

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fwww.mozilla.org%2Fproducts%2Ffirefox%2Fbuttons%2Fgetfirefox_small.png&hash=9f6d645801cbc882a52f0ee76cfeda02625fc537)

cayne

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fcayne.s1.cybton.com%2Fcoppermine1.jpg&hash=9fa12968e6c3e193e8f1d5d9b4ef262156d90174)

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fcayne.s1.cybton.com%2Fcoppermine2.jpg&hash=345313e8f0b250d20118bc01364a17e115ce1912)

Am I blind? Can you show me this magic option "viewable status to registered users only" ?!

Thanks.

PS: I isn't a template fault:

(https://coppermine-gallery.com/forum/proxy.php?request=http%3A%2F%2Fcayne.s1.cybton.com%2Fcoppermine3.jpg&hash=650190b471618cf5bbc93d48be190b18ebf6f64b)

Casper

No, you're not blind.

You just have not set 'users can have private albums' to YES in config.
This doen't mean anyone can have a personnal album, just those set in the groups page.
It has been a long time now since I did my little bit here, and have done no coding or any other such stuff since. I'm back to being a noob here