I have a div with a fixed height and want to display a view field. When the content overflows the div, I'd like an elipsis to click for more.

CSS can handle overflow and hide it (and overflow-text can handle a single line) but I have to estimate everyting for number of lines since words can be an arbitrary length. Sure views with or without the smart trim module can handle words or characters, but I need to estimate the number of lines or, ideally, I'd like the trim based on the max-height of a div.

The Smart Trim maintainer suggested a CSS library which may help but does not solve the problem.

I imagine that views text overflow based on height is a common problem.

1 Answer 1


There is no way to handle this with Drupal modules, I suggest you use Ellipsis in your Style( style the result rows items with Ellipsis .

You can read below help content :



  • All roads seem to lead back to the css library but even so, as far as i can tell, they will not let you make the ellipsis into an anchor to link back to the content or other view. How do most people handle a variable amount of summary text in a fixed height div? I feel like I must be missing something big :) Commented Sep 9, 2015 at 19:52
  • @Sonicthoughts you can handle it with link2 help,you just need add this css properties to your view item :)
    – Yuseferi
    Commented Sep 9, 2015 at 19:55

Your Answer

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

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