Site logo

Archived topic

How to increase the number of words in titles?

7 replies · Started by Stephane on May 19, 2020

Viewing posts 1–8 of 8

Hi there,

Some titles are cut. How can the word (or character) limit in titles be increased?

eg. https://imgur.com/a/KP3CdPa

Regards

Hi there,

the Dispatch site trims the titles using CSS.
Go to Customizer > Additional CSS - and DELETE this block of code:

.generate-columns-container article .entry-header .entry-title,
.wp-show-posts article .wp-show-posts-entry-title {
    line-height: 2.5ex;
    height: 5ex;
    overflow: hidden;
    text-overflow: ellipsis;
}

Thx David :)
It works well!

You're welcome

Hi David, can I just jump on Stephane's question and ask if there's code you can add to instead have "..." on the titles if the titles are longer than what they display?

I think showing the full title on all of them looks too long (for my site anyway) and some titles are only really longer for google search. Having some way to indicate it's not the full title and they just need to click on to read the full title would therefore be the perfect solution.

Let me know if this is possible please. Thanks!

Give this a shot:

.generate-columns-container article .entry-header .entry-title::after,
.wp-show-posts article .wp-show-posts-entry-title::after {
    content: "...";
}

Please open a new topic if this doesn't help.

Thanks!

Thanks for getting back to me! That's adding dots after the titles that fit in instead of the ones that don't. What shall I tweak it with to swap it the other way around please? :)

Can you open a new topic and link me to the page in question?

It's not possible to do it conditionally I don't think.

This archived topic is closed to new replies.