I have searched through the Forum and Handbooks, but cannot seem to find this particular 'recipe'. I have a feeling it needs to be a code snippet in a template (or view_tpl or node_tpl) type of file, but I am stuck. I have basic understanding of using View module and CCK, but this has me stymied.
I am actually using the Insert View module to insert my View in a node, so that I can easily link to it from a menu link. (This particular project is for a Press Release page).
I want the most recent post to display at the top of the page (or in other words, at the top of the 'View') as a Teaser paragraph, with a read more link, etc. Then all other post listed below in alternating Tables (A Table list view, I already have this part figured out).
Then, to take it to the next level, I would also build Views for each Press Release category in the same fashion (such as 'Events', 'Regional News', 'Local Info' etc).
But what I really need help with right now is just that pesky first most recent post as a Teaser - perhaps this is very easy to do but I just don't seem to get it - I am developing on 5.x.
Any help is greatly appreciated- Thanks!
Comments
Any ideas?
Anyone have any ideas?
Interested in doing this as well
I think this might be possible by modifying the code generated from the views theme wizard, which you are basically over-riding the gathering and rendering of data for output via your template.php file. The function basically builds a big ol' variable for output, using drupal theme functions.
So... my plan would be to catch the first item in the array of view items ($item[0]), theme it with the theme teaser function, then process the rest through the views list theme function, concat the two output, then return your output.
In theory anyways...
If there is an easier way (a module already written to do this?), I'm all ears. Still doing research on Drupal.org and plan to try the above later. Will report back, cap'n.
pat