I should begin by defining Text Parts, since they're Old School and many of you probably are unfamiliar with them. Text Parts are BBCode-like, bracketed text strings with specific properties that when displayed on a page are converted into something else. Text Parts are traditionally used with blog posts, which is the extent of their initial functionality in Sueetie. In the future I hope to incorporate Text Parts in other applications like Sueetie CMS and Marketplace as well.
Here's the syntax of a text part.
[sueetie:myTextPart]
"sueetie" denotes that the bracketed content is a Sueetie Text Part and "myTextPart" is the specific Text Part to be displayed on the page.
A Text Part Example
Here is a working example of a text part for you. I just launched a new series on the Sueetie Business of Community blog titled "In the Enterprise." One of the purposes of the series is to remind readers of Sueetie v4.0's chops in the Enterprise Software space, so on each blog post I am adding a statement about Sueetie's Enterprise Network capabilities. Here is what that statement currently looks like.
The issue here and motivation in creating Text Parts is that I wanted the statement to reflect the current version and status of Sueetie as it related to the Enterprise, whether now or 6 months from now. A Text Part gives me full control over the statement's display for posts regardless of the date they were published.
What the Example Text Part Looks Like In the Editor
As I mentioned earlier, a text part is bracketed text which begins with "[sueetie:" and contains a text part name. The text part name of our "In the Enterprise" callout statement is "EnterpriseCallout," so our text part looks like this.
That's all we have to do to generate the boxed HTML content shown on the "In the Enterprise" post screenshot above. And as I said, the HTML content generated can be changed at any time.
Parameters, too!
Sueetie Text Parts support parameters. For instance, you may need to modify the content based on certain criteria. Here's what a text part with parameters looks like.
Parameters are delimited with commas and a separated from the Text Part Name by a colon. I should mention that while parameters are displayed as entered, the Text Part Name is case insensitive.
Managing Text Parts
Text Parts are managed in the Sueetie Administration Addon Pack area. Here is what the administration form of the text part with parameters looks like. Notice when you are using parameters, you'll use {#} to bookmark them in the Content Html.
Finally, here's what the parametized text part looks like when displayed on the page.
Where Text Parts are Displayed and Not Displayed
The tricky thing about using Text Parts is to display them only where and when you want them. For instance, you will probably not want your text part expanding on a blog post list where the abbreviated post is displayed. You also probably don't want the text part expanded in an RSS Feed or, say, in search results. And you certainly do not want the bracketed text to appear in any location.
For those reasons, Text Parts are expanded on single Blog Posts and Blog Pages only. They are not displayed on Post List pages or on Sueetie Blog Post List Views outside of the blogging application. Text Parts are removed from blog posts before indexed by Sueetie Global Search. They are also removed from RSS Feeds.
As we mentioned, Text Parts are only used on blog posts for the Sueetie v4.0 release. In future releases we plan on supporting Text Parts on other applications as well.