Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2007-12-17 08:29:45

parlour
Member
From: Germany
Registered: 2006-09-01
Posts: 20

… cut off article titles after a certain number of characters

I’m using the <txp:title /> tag in order to display a dynamic menu. Problem is: the titles are usually very long and the space is limited. I really don’t like multi line menu entries.

Is there any way (other than maybe utilizing custom fields) to cut off the titles after a certain number of characters?

Offline

#2 2007-12-17 08:45:39

wet
Developer Emeritus
From: Schoerfling, Austria
Registered: 2005-06-06
Posts: 3,330
Website Mastodon

Re: … cut off article titles after a certain number of characters

sab_substr. docs, download

Offline

#3 2007-12-17 09:42:39

parlour
Member
From: Germany
Registered: 2006-09-01
Posts: 20

Re: … cut off article titles after a certain number of characters

Thank you! Works like a charm. (But I would so like to add some typographic niceties. Damn perfectionism!)

Offline

#4 2007-12-17 16:52:41

Bloke
Developer
From: Leeds, UK
Registered: 2006-01-29
Posts: 11,449
Website GitHub

Re: … cut off article titles after a certain number of characters

parlour wrote:

But I would so like to add some typographic niceties. Damn perfectionism!

Does this update help?

Last edited by Bloke (2007-12-17 16:52:55)


The smd plugin menagerie — for when you need one more gribble of power from Textpattern. Bleeding-edge code available on GitHub.

Txp Builders – finely-crafted code, design and Txp

Offline

#5 2007-12-18 10:48:58

parlour
Member
From: Germany
Registered: 2006-09-01
Posts: 20

Re: … cut off article titles after a certain number of characters

Helps, yes. Very cool.

Offline

Board footer

Powered by FluxBB