How to make all albums private when users registers How to make all albums private when users registers
 

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]

Main Menu

How to make all albums private when users registers

Started by nickkader, March 28, 2013, 08:44:34 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

nickkader

Is there a way to have when a new user register it create an album when they register and only limit to one and have all users automatic private from other users? Also I cant seem to find to find the html to edit my links?

nickkader

How to make all albums private when users registers.

nickkader

I want users albums to automatically be set to private when they register cause I have it set up when they register an album is created automatically so how can I make it private when they register or make all albums private.

Αndré

Open register.php, find
    // Create a personal album if corresponding option is enabled
    if ($CONFIG['personal_album_on_registration'] == 1) {

        $catid = mysql_insert_id() + FIRST_USER_CAT;
        cpg_db_query("INSERT INTO {$CONFIG['TABLE_ALBUMS']} (`title`, `category`) VALUES ('$user_name', $catid)");
    }

and replace with
    // Create a personal album if corresponding option is enabled
    if ($CONFIG['personal_album_on_registration'] == 1) {

        $catid = mysql_insert_id() + FIRST_USER_CAT;
        cpg_db_query("INSERT INTO {$CONFIG['TABLE_ALBUMS']} (`title`, `category`, `visibility`) VALUES ('$user_name', $catid, $catid)");
    }



Additionally, you maybe want to apply the same mod to usermgr.php.

Αndré

I just found your other two threads regarding the same issue and merged them with this thread. Next time, please don't double post. Thank you.