Page 1 of 1

[SOLVED] CTL Module Maker | Upload thumbnails in another (sub) directory

Posted: Mon Dec 06, 2010 8:51 pm
by cmaunoury
Hi everyone,

I am using CTL Module Maker with an image upload field that generate a thumbnail. Thing is, I am using the uploaded images with the simple rotate tag to display these images on the homepage. the tag reads the content of the directory where the images are uploaded, which is easy and fine.

My problem is that the thumbnails are uploaded in the same directory and so the tag reads both the full res image and the thumbnail. I have been trying to edit directly the way thumbs are handled in the php classes (action.addfile.php / action.assignfiles.php / action.browsefiles.php), but with no success so far.

Of course, I am concerned my altering the code would bring problems with the way the module retrieves the thumbnails for display.

the point is: I would like to upload the images in one directory and the thumbs either in another directory at the same level or inside a subdirectory of this upload dir.

Any idea?

thanks for your attention and your help,

Best,

Colin

Re: CTL Module Maker | Upload thumbnails in another (sub) directory

Posted: Mon Dec 06, 2010 9:39 pm
by mw
if your using the rotate plugin I believe it has an "exclude thumbnail" function which does not include the naming convention of ctlmodule thumbs which I think are named "pl_something.jpeg" ?
I would think you could simply add that exclusion

[SOLVED] CTL Module Maker | Upload thumbnails in another (sub) directory

Posted: Tue Dec 07, 2010 9:55 pm
by cmaunoury
Thanks a lot for the answer. That worked fine!

I was looking for complex thing and it was indeed just the matter of adding "pl" to line 93 of the function.rotate.php.

Hope it'll be useful for others. Of course, there could also be another condition added for those not using only CTL Module Maker thumbnails, but this should be quite easy.

Thanks a lot,

Colin