Images in Multiple Albums - Page 2 Images in Multiple Albums - Page 2
 

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

Images in Multiple Albums

Started by OmegaGOD, April 14, 2004, 08:07:02 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

DeadKenny

So, same question but for 1.3.1. Is this in 1.3.1?

If not, can we get it somehow as I'd really like this feature?


I'd basically like to have a "best of" gallery that features on the home page of Coppermine so I can show off the best pics, and have the full albums in sub-categories for those who want to browse them. I don't want to have to upload pics twice to do that though or risk deleting the source pic if I delete it from one album when it's also in another.

Joachim Müller

It's not in cpg1.3.x, it's only in the version which is currently under development (and the feature isn't mature yet, needs tweaking). You're free to check the devel version out, using anonymous cvs, but remember that there's no support for devel versions.

GauGau

TC

If I understand you correctly then it picks up which albums an image should be added into based on keywords?
Wouldn't it be better to make this a feature of the database structure?
Right now there are 2 tables, albums and pictures which are linked together using the aid field in the pictures table pointing at the correct album.
To give the most flexibility it would be even better to remove the aid field from pictures and create a new table called album_pictures. This would have at least 2 fields, aid for the album and pid for the image. Using this structure you can easily specify that a picture belongs to more than one album.

To make this work there are two main changes required to the code. Any queries right now which use "where aid =" would have to change to add an extra join to use the new table to get that info.

The biggest change is an interface change to allow images to easily be added to more than 1 album. The idea of using keywords does make it easy to add an image to another album, but you have to type in the correct keywords each time. By doing it with the method I describe it would be easy to set up a drop down box which allows you to select another album to add this image to.
You could even change the upload mechanism to allow multiple albums to be selected.

Finally the keywords idea for associating images with multiple albums is a really good one. Maybe you have an automatic system which takes keywords out of the exif comments in an uploaded image and automatically adds the image to the correct album based on keywords?

Sorry to say that your solution isn't the best but it looks like a mod rather than something built into the system which maybe this should be.

Tarique Sani

Good idea TC - volunteering to code it?
SANIsoft PHP applications for E Biz

TC

Quote from: Tarique Sani on August 05, 2004, 12:50:44 PM
Good idea TC - volunteering to code it?
I do write this kind of thing for a living so yes I would definitely like to get involved. My only concern would be that it involves such a big change to the code that it can't be handled as a mod.
I did a quick grep to find where the pictures are accessed using the aid field:
find . -name "*.php" -exec grep TABLE_PICTURES.*aid {} \;
(that doesn't catch all of them but it was enough to start with)
That shows there is a LOT of work required to be able to change the underlying database structure to handle the idea of a 1 to many relationship for photograqphs and albums.

I've already posted another thread about smart albums which might mean that these changes aren't necessary to give coppermine this kind of fucntionality.
Have a look at it here and let me know what you think:
http://forum.coppermine-gallery.net/index.php?topic=8575.0

Casper

I wish I'd read this thread first, as I just replied to your smart album thread without knowing about this chat. :D
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

Tarique Sani

Quote from: TC on August 05, 2004, 01:07:04 PM
That shows there is a LOT of work required to be able to change the underlying database structure to handle the idea of a 1 to many relationship for photograqphs and albums.
Now you will also understand why I am opting for an easy way out :) The idea you suggest is good BUT the amount of work involved and then the possibility of bugs being introduced due to these changes which turn up in wierd places! The code is already a mess and we also have to keep  it backward compatible for easy upgrades.

We are  planning a tentative version 2.0 things there will b very different...
SANIsoft PHP applications for E Biz

Tarique Sani

Also your idea implies that the albums will have to be selected for placing pictures - you are over looking installs where there are 100s of albums. having 10s dropdowns with all those albums will make the pages a couple of 100 kb (like it has happened to Oasis) - with key word all you have to ensure that the keyword is spelled correctly - for that I have created a key word dictionary which accumulates all the keywords that have been previously placed for pictures and a key word inserter which allows putting keywords from a pop-up list....



SANIsoft PHP applications for E Biz

TC

There are javascript tricks you could use to only have the list once as a javascript array and then populate all the drop down menus from that. That would allow you to load it just once per page.
It was just an idea for adding images to multiple albums, but I do prefer the idea of keywords. I would have the keywords already in the exif comments as it gives a lot of freedom for people to setup their own workflows for doing this rather than having to type in the keywords for every image they upload.

There are a few threads going on which could link together to make the organisation of images much easier, basically the ideas of multiple albums for each image and automatic organisation based on image meta data (including EXIF time data and keywords).

Tarique Sani

@TC - perhaps you would like to do a checkout of the devel from CVS and see what already works, basically it is the metablums and stats which need to be tweaked for same image in multiple albums
SANIsoft PHP applications for E Biz

STRiDOR

Hey Tarique, any update on an ETA for the mod?  I'm still waiting patiently..    ::)
STRiDOR

Casper

This is in the development version ( 1.4 ).  It will not be released as a mod prior to that.

A non-public beta will be released soon to testers, but don't know how long before a public release.

You can get the dev version from the cvs, but please understand, there is absolutely no support for it until the public release, as it is meant only for experienced users.
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

ignasi_salvador

I would like to add something new to this whole story.

We developed some years ago a gallery called K-OS catserver.ingenieriasinfronteras.org/k-os .

We did that because we wanted to have several pictures classified per different parameters; for exampleL: water supply, b/w, nicaragua.

Besides this we wanted to be able to get all pictures in Water(including those which have water supply, water tratment, pumps, etc).

What we did is the following:
- Table 1: Pictures. All information of pictures: date, size, contributor, etc
- Table 2: Words. To make a tree of words so you could have Water/Supply/Pump/Manual, for example; or Location/Central America/Nicaragua/Chontales.
- Table 3L: Words_Pictures. With all relations between words and pictures.

In this way we could easyly list all pictures we were looking for.

Furthermore, if you are an administrator, you can add/delete words and assign a word to several pictures at the same time.

The idea is that if you search for pictures of Manual Pumps, you search the pictures, and once you find them, you can add the word Manual in the Tree and assign that word to those pictures.

I think something similar to this would be really really really helpful for many people.

Our problem is that we are not very good programmers and the final K-OS is quite a mess. We programed it because we didn't find this functionality in any gallery available in the web.

Finally I would just like to add that we did this under GNU license so, if you are interested, I can send you the code.

Ignasi