Muut
November 1, 2014, 6:51pm
1
Grav 0.9.4
As I understand the docs, {{ page.summary }}
should return the content of my page up until a ===
delimited in that content.
But that’s not happening. The content is being truncated at some point before the ===
delimiter. I don’t want to use a fixed number of characters, so am attempting to truncate somewhat manually with ===
.
What did I miss?
Muut
November 1, 2014, 6:55pm
2
P.S. I cleared the cache, this time.
Muut
November 1, 2014, 7:03pm
3
Do you have a summary: size: 300
or something in your site.yaml
? If so try removing that. (then clear cache)
Muut
November 1, 2014, 7:02pm
4
The system config summary:size
is 300. Should I set the user config to 0? Or blank?
Muut
November 1, 2014, 7:21pm
5
Might be safer to set it to a big number.
Muut
November 1, 2014, 7:22pm
6
When I do that I just get all the content. page.summary does not seem to respect the ===
.
Muut
November 1, 2014, 7:26pm
7
I just checked the code and it’s looking for the delimiter to be separated by new lines so make sure you have:
===
Actually it should not matter what the summary size is as this is only checked if the delimiter is not found first.
Muut
November 1, 2014, 7:26pm
8
ok that’s hard to read in teh quote, but you just make sure there’s a new line above and below the ===
Muut
November 1, 2014, 7:25pm
9
That was it. I had the ===
inline with the rest of the text. Thanks!