Jahia Template Forum > getting value from...

0 (0 Good)
0 (0 Bad)

getting value from list based on creation Date?

by  peters »  2011/06/07 20:00

Hi All

i have imagelist which consist n number of images,but i want to display only the first image ,but i am not able to get the oldest image .it is displaying only the latest uploaded images.

below is the code.

how can i use the metadata creation date to sort the same.

lt;template:containerList id=

  (peters)

Number of messages  35
Registration date
0 (0 Good)
0 (0 Bad)

Re: getting value from list based on creation Date?

by  pap@commaro.com »  2011/06/07 20:00

You could try:

lt;template:containerList id=

Benjamin Papez (pap@commaro.com)

Number of messages  220
Registration date
0 (0 Good)
0 (0 Bad)

Re: getting value from list based on creation Date?

by  peters »  2011/06/07 20:00

Hi Benjamin

i tried the code given by you.

i m getting the following error.

sortByMetadata is not a valid attribute for containerlist according to tld.

the code i used is:

lt;template:containerList id=

  (peters)

Number of messages  35
Registration date
0 (0 Good)
0 (0 Bad)

Re: getting value from list based on creation Date?

by  peters »  2011/06/07 20:00

Thanks Benjamin , i have used querytag to fetch the desired result .thanks a lot.[:)]

  (peters)

Number of messages  35
Registration date
0 (0 Good)
0 (0 Bad)

Re: getting value from list based on creation Date?

by  pap@commaro.com »  2011/06/07 20:00

Hello,

sorry, it was a typo. The attribute is called sortByMetaData (with a big D). This way you wouldn't have to use the query tags.

Regards,
Benjamin

Benjamin Papez (pap@commaro.com)

Number of messages  220
Registration date
Contact
Share
Feedback

Get in touch

Whether you are a current user or if you are just evaluating Jahia, we are here to help.

Contact us

Share this page