Can I sort child assets of a particular page using a Trigger?


(Stuart W) #1

Is it possible to create a trigger to sort image assets that are children of a particular page whenever a new image is added?


I have done everything to set up a trigger except choose an action - there doesn't seem to be one suitable!



Thanks,



Stu


(Aleks Bochniak) #2

Stu, do you mean sort the asset tree?


(Stuart W) #3

[quote]
Stu, do you mean sort the asset tree?

[/quote]



I do. I've set up an asset creation form so that users can upload images to a gallery. The images in the gallery could really do with being ordered by name everytime a new image is added to it.



Cheers



Stu


(Nic Hubbard) #4

[quote]
I do. I've set up an asset creation form so that users can upload images to a gallery. The images in the gallery could really do with being ordered by name everytime a new image is added to it.

[/quote]



So you are just worried about them being sorted by name in the asset map? If so, no this isn't possible with a trigger.



If you are worried about sorting on the front end using an asset listing, you just need to configure the Asset Sorting option.


(Stuart W) #5

[quote]
So you are just worried about them being sorted by name in the asset map? If so, no this isn't possible with a trigger.



If you are worried about sorting on the front end using an asset listing, you just need to configure the Asset Sorting option.

[/quote]





Oh yes, of course I do. Sometimes I can be really dim!

Thanks for pointing that out to me, Nic - very much appreciated :smiley:



Cheers



Stu


(Nic Hubbard) #6

Happy to help.