0

I have three different content types like news, events, meetings. Using views i need to display only one post (the latest one) from each of this content type.

Created a view, filter criteria for all four content types selected....and stuck.

3 Answers 3

0

or you can create 3 blocks view nd use menu tabs.

u have 3 content types, create a view with 3 blocks overridenn, each one display latest content of one of those content types, nd display the three blocks into one block from the theme blocks by choosing display as menu tabs from views setting. or u can use Quicktabs modules to do this, its very easy.

2
  • it's for a views slideshow or views showcase... A slideshow with one recent content from each of the four different content types.
    – jack
    Mar 3, 2013 at 14:50
  • by using viewfield module, u can try this :1) Create a different view for each content type that lists the node titles in the way that you want. 2) Create a content type called content type slide 3) Add a view field to that content type. 4) Save it 5) Add a new slide 6) Choose one of the content types views 7) Keep on creating content type slides until you have reached the number of content types you want. 8) Create a slideshow view of the slide content type. source : drupal.org/node/1050236
    – Mahdi
    Mar 3, 2013 at 23:42
0

This would probably best be fixed by creating view blocks and creating a separate view for each of the content types. Then display the blocks in the region as needed. Or you can create a custom page template and embed the views inside that

0

Another solution, you can create only one view (for 1st content type) then create Attachment for second Content type and attach it to your main view block or page. And 3rd attachment for 3rd c.type(do the same thing). You can chose Attachment position also.

Here is video - you can see how to use views + attachments.

Also u can do next thing - you can create one view with 3 block - like attachments - one block for each content type. Then create a template for field output - something like this views-view-field--YOURVIEWNAME--page--YOURFIELDNAME.tpl.php and use views_embed_view function to output results of two block u created before. - like this

<?php print $output; ?>
<?php print views_embed_view('YOURVIEW_NAME', 'block_name1', $row->YOURFIELDNAME); ?>
<?php print views_embed_view('YOURVIEW_NAME', 'block_name2', $row->YOURFIELDNAME); ?>
2
  • This will work, Thanks...but if my display format is views showcase will it still work???? Lemme try and let you know.
    – jack
    Feb 25, 2013 at 16:25
  • never worked with showcase, i cant say for sure Feb 25, 2013 at 16:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.