Page 1 of 1

Specify the Upload Directory for Image Fields

Posted: 2015-07-02 12:37
by gmusgrave
I have a database of Children's Art with three tables. Each row in each of these tables contains an image, plus data associated with the image (Artist, Age, Date, etc.).

Each of the three tables contains a few hundred images, and growing.

Because each table is a separate collection, I'd really like the images associated with each table to be uploaded and stored in a separate directory.

Right now, all images from all tables are uploaded to, and stored in, a single directory called "images".

At this moment, it seems the only way to do this is by modifying some AppGini files with some custom code. These appear to be lib.php, defaultLang.php, and each tablenam_dml.php (thanks peebee!).

The disadvantage, as always, with custom mods to the AppGini code is that AppGini updates clobber the custom code, and it needs to be reinstated in the new version. Also there's no guarantee that the changes in the update won't break your code.

Personally, I'd like to see the upload directory as an option in AppGini on the "Media" tab where you set the field to be an "Image." The "Configure..." button brings up a number of options for this field, and this is where I think it should be able to be specified.

Maybe this can be included in a future update.

Re: Specify the Upload Directory for Image Fields

Posted: 2015-07-02 12:56
by gmusgrave
Just wanted to add one more reason for wanting this feature: for reasons beyond my control, some of the image filenames in one collection will be the same as those in another.

So there's a naming conflict, which is most easily resolved by uploading them to separate directories.

Re: Specify the Upload Directory for Image Fields

Posted: 2015-07-10 21:35
by a.gneady
This is indeed on our backlog for future releases. Stay tuned!