coppermine-gallery.com/forum

Support => Older/other versions => cpg1.2 Standalone Support => Topic started by: turtleboy on April 05, 2004, 12:47:32 PM

Title: Prefixing filenames?
Post by: turtleboy on April 05, 2004, 12:47:32 PM
How do you prefix the file names of the images being uploaded with  the current users username? I thought this was supposed to be default, but it won't work under any user.
Title: Prefixing filenames?
Post by: Joachim Müller on April 05, 2004, 05:06:03 PM
no, this is not default. Coppermine uses a database to keep track of files - no need to rename files, as the database "knows" who uploaded the file.
Such a feature doesn't exist. What coppermine does is creating a new folder within "userpics" for each user (not with the username, but a number corresponding to the user) this user's uploads go to (except if the server runs in safe mode).

GauGau
Title: Prefixing filenames?
Post by: turtleboy on April 05, 2004, 10:12:03 PM
I think my server is running in safe mode, because all of the photos go into the same directory (userpics). Is there anyway that I can prefix the file names? The only reason being conflicts between different users with the same filename.

I have some code that does this on a different uploader, but Im not sure how to implement it into Coppermine.
Title: Prefixing filenames?
Post by: Joachim Müller on April 05, 2004, 10:53:07 PM
Coppermine will solve such conflicts: if a filename already exists, coppermine will rename the file. Please post a link and a test user account to check.

GauGau