0

I know we can specify the specify limit for the teaser by going to content type -> manage display -> teasers. I have made the views block for teasers and I want to display only few lines for that content in particular views block and do not want to affect the stand treasure setting. So, is there any setting in Views which specify the teasers limit for the particular Views block?

1

I would use TRIM to achieve that. Go the desired field in the View, click "Rewrite results", there "Trim this field to a maximum length", and insert a number value.

  • so when you said I have made the views block for teasers and I want to display only few lines for that content in particular views block, you never meant Format: Content | Teaser. – Vishal Kumar Apr 18 '16 at 17:09
  • Actually at first place I was trying with that: "Format: Content | Teaser", But looking at answer I thought that, it can be done by "field" option only. As I had previously checked the setting of teaser in "Format: Content | Teaser", there is not any option for this. But if there is any option with that let me know, please. – CodeNext Apr 18 '16 at 19:00
  • @Vishal Kumar, any thoughts? – CodeNext Apr 19 '16 at 17:39
  • yes, adding fields of the teaser view mode instead of teaser itself seems best to fulfil your criteria. this way you can trim the body field. I have never seen a code to alter a view mode from within a view. – Vishal Kumar Apr 19 '16 at 18:01
  • @VishalKumar, Hi, I did not find the teasers view mode when dealing with Show: Fields|Setting. However, I can find it while dealing with Show: Content|Teaser. Which is the view mode teaser. Which is the same teaser which shown at the content type. If you are referring this then it is question itself, I do not need that teaser I want to customize that. Please let me know how to access the field of teaser views mode. – CodeNext Apr 20 '16 at 5:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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