Open orchardbot opened 14 years ago
rpaquay commented:
Bertrand, can you figure out what this means? It this a new feature, what feature exactly?
@bleroy commented:
The feature is something that exists in WordPress and other blog engines and something that LiveWriter can handle. You insert a special marker in your blog post's text and the system understands that what is before the marker is the summary version, and the full version is everything that's before and after the marker. http://codex.wordpress.org/Customizing_the_Read_More
@heskew commented:
We discussed a while back an implementation that would involve in part using to mark the cutoff for the excerpt.
http://orchard.codeplex.com/workitem/15727?ProjectName=orchard
rpaquay commented:
This is a new feature we won't have time to implement for V1.0. A patch would be welcome though :)
@bleroy commented:
A theme can implement that by including the following Views/Parts.Common.Body.Summary.cshtml:
@{ Orchard.ContentManagement.ContentItem contentItem = Model.ContentPart.ContentItem; var bodyHtml = Model.Html.ToString(); var more = bodyHtml.IndexOf(""); if (more != -1) { bodyHtml = bodyHtml.Substring(0, more); } else { var firstP = bodyHtml.IndexOf("
"); var firstSlashP = bodyHtml.IndexOf("
"); if (firstP >= 0 && firstSlashP > firstP) { bodyHtml = bodyHtml.Substring(firstP, firstSlashP + 4 - firstP); } } var body = new HtmlString(bodyHtml); }@body
@Html.ItemDisplayLink(T("Read more...").ToString(), contentItem)
\ Closed by BertrandLeRoy 03/25/2011 3:34PM
@bleroy commented:
Could be nice to implement in TinyMCE as a button, and as a capability for LiveWriter.
igeek created: https://orchard.codeplex.com/workitem/16554
It would be good to see cutting tag, that divide full news and short news
some text