Daniel15.Data.Entities.Blog.PostModel.Intro C# (CSharp) Method

Intro() public method

Gets the introduction to this blog post - That is, the content up to the "read more" section.
public Intro ( bool &showMoreLink ) : string
showMoreLink bool
return string
        public string Intro(out bool showMoreLink)
        {
            var content = Content();

            // No "Read more" section, so just return the whole post
            if (!content.Contains(READ_MORE_HTML_MARKER))
            {
                showMoreLink = false;
                return content;
            }

            showMoreLink = true;
            return content.Substring(0, content.IndexOf(READ_MORE_HTML_MARKER, StringComparison.Ordinal));
        }