Hi all.
This is my first question here in Drupal Ireland (I haven't answered any question so far either).
I am a bit stuck with a landing page of image galleries I am trying to create. I thought it would be very easy, but...
WHAT I HAVE DONE
1.- The client of one website requested a "week in pictures" section.
2.- I created a content type with two fields (a) a "Date" (b) and an "Image" with unlimited number of values, so the client can upload as many images as she pleases
3.- So we have a node per week (eg: http://test2.go2kingshossite.web.ie/april-pictures). The way I have done this is by having a view with a contextual filter (Content:Nid) and displaying the Field:Image three times (one for the image itself, one for the title and one for the alt text that shows as a description) - see attachment
4.- Then I have to create a landing page with the last one, so it automatically updates every time the client adds a new node (this is supposed to be once a week, but not necessarily). Trying to do this as a similar view but this time somehow filtering to display just the images of the last published node.
THE PROBLEM
I can't figure out how to do it.
I have been trying a pager with an specified number of items set to "1"
but that only brings one image.
I have trying to find a "filter criteria" or a "contextual filter" but I can't find anything that looks like "last node".
THE SOLUTION
Hopefully somebody out there in the community can help.
Many thanks in advance.
Ricardo
Attachment | Size |
---|---|
kh-week-pictures-view.png | 76.44 KB |
Comments
Hi Ricardo, Welcome to the
Hi Ricardo,
Welcome to the group!
Would adding a sort to the view of 'Node: Updated' and select Descending work and limit it to 1? Alternatively you could order by the date desc, which might be better in case they go back and edit older nodes.
Thanks so much,
Thanks so much, Stella.
Having order by date (desc) and Use Pager: Display a specified number of items = 1 brings just one image (just one value of the few images under the same field).
I think the problem is on the fields. I have three times the same field (one for the img, one for the title, one for the alt) and I had nothing clicked under"multiple field settings".
If I click now on "display all values in the same row" I get the four images of the last gallery (so so far so good) but the order is the 4 imgs first, then the 4 titles and finally the 4 alt... in that order... rather than img+title+alt of each on the images.
Will keep playing with it... there must be a way to group these 3 fields
Thanks very much for your help, Stella