Coming from #935522: Ability to select trimmed version of the body in custom build modes.

The node row style is currently not flexible enough to display node teasers for build modes other than "teaser". This patch introduces a trigger in the template preprocess function that displays node teasers, for now it is just $vars['teaser'].

I was hoping to get some feedback from the maintainers as to whether or not this makes sense.

CommentFileSizeAuthor
views-DRUPAL-6--2_build_mode_teasers.patch990 bytesdboulet

Comments

merlinofchaos’s picture

Status: Needs review » Closed (works as designed)

I believe you're supposed to test $node->build_mode not look at the $teaser value.

dboulet’s picture

The problem that I was trying to solve was that it is currently not possible to trigger node_view() with the $teaser argument value being TRUE if the build mode is not 'teaser'.

I think I'm just going to let this go, it seems like D6 core was just not conceived to be flexible to allow this type of change and views is just following that.

There's no difficulty in D7 as the node body is now a proper field and its display can be changed in the UI.