The content entity object has a .getExcerpt method which grabs the first x bytes...
The content entity object has a .getExcerpt method which grabs the first x bytes of a page (about 50 chars iirc) this method is used by 3.0 if an excerpt is not available when generating the meta description tag.
it should be possible to modify the {excerpt} macro to fall back to this method, however that would require a modification to your confluence source code or intervention by atlassian.
I'm surprised that the excerpt-include macro doesn't already do that.
Related: ...
I'm surprised that the excerpt-include macro doesn't already do that.
Related: Confluence 2.6.1 and above seem to be much better at making cleaner automatic excerpts. Things like macros, image markup and other unsightly things seem to be getting removed now, leaving behind more easily readable excerpt text.
Comments (4)
Jan 07, 2008
Alain Moran says:
The content entity object has a .getExcerpt method which grabs the first x bytes...The content entity object has a .getExcerpt method which grabs the first x bytes of a page (about 50 chars iirc) this method is used by 3.0 if an excerpt is not available when generating the meta description tag.
it should be possible to modify the {excerpt} macro to fall back to this method, however that would require a modification to your confluence source code or intervention by atlassian.
Jan 07, 2008
Guy Fraser says:
I'm surprised that the excerpt-include macro doesn't already do that. Related: ...I'm surprised that the excerpt-include macro doesn't already do that.
Related: Confluence 2.6.1 and above seem to be much better at making cleaner automatic excerpts. Things like macros, image markup and other unsightly things seem to be getting removed now, leaving behind more easily readable excerpt text.
Jan 08, 2008
Simon Wheatley says:
Yes. It's one of those things that you'd hope a CMS-ish system might "just do". ...Yes. It's one of those things that you'd hope a CMS-ish system might "just do". Good to hear that the excerpts are clean though.
Thanks.
Jan 07, 2008
Simon Wheatley says:
Thanks Alain.Thanks Alain.