Blogs widget

Overview

You use the Blogs widget to display blogs on your website pages. You select what content to display and then specify how blogs are listed and displayed individually.

The Blogs widget can be used along with Blog post widget. You can configure the widgets to work together and once you click on а blog title to see all blog posts for the currently selected blogs (listed in the Blog posts widget). To achieve this, configure the Blogs widget Open single item in... and select a page with a Blog post widget. Then configure the Blog post widget to show posts From currently opened blog.

PREREQUISITES: You created at least one blog item. For more information, see Create blogs.

Choose what content to display

  1. In the upper-right corner of the Blogs widget, click Edit
  2. In the Content tab page, choose which blogs you want to display. Choose between the following options:
    • All published blogs
      All created blogs are displayed.
    • Selected blogs...
      A custom selection of blog items is displayed. To select one or more blog items you want to display, click the Select button.
    • Blogs with more than...posts
      Only blogs that have more than specified number of posts is displayed.
    • Only blogs that have posts not older than...months
      Only blogs that have posts recent than the specified period is displayed.
  3. When finished, click Done selecting.

List settings

List settings define how blogs are listed by the Blogs widget. Choose one of the following options:

  • Use paging
    Divides the blogs into pages. In the input field, specify how many blogs per page to display.

  • Use limit
    Displays only a limited number of blogs. In the input field, specify how many blogs to display.

  • No limit and paging
    Displays all blogs that meet the requirements and filters you set in the Content tab.

  • Sort blogs
    By default, last published blog items are listed on top. You can select a different sorting criterion:

    • Last published
    • Last modified
    • By Title (A-Z)
    • By Title (Z-A)
    • As set manually
      This option is available only when you selected specific blogs in the Content tab using Selected blogs…. If you select As set manually, blogs are displayed in the same order as in the Content tab.
    • As set in Advanced mode
      To sort the list of blog items by property that is not defined in the sort dropdown menu, you must add a new sorting expression in the designer’s Advanced mode. For example, to sort blogs using the Content property of blogs, navigate to Advanced » Model and, for SortExpression, add Content ASC. As a result, in the sort dropdown menu, the As set in Advanced mode option is selected by default.
  • List template
    Select the template you want to use to list blogs on the webpage.

  • CSS classes
    Expand More options section to specify CSS file names and apply additional CSS classes to the Blogs widget.

Single item settings

Single item settings define how individual blogs are displayed. Choose one of the following options:

  • Open single item in...
    Select one of the following options:

    • Auto-generated page
      When you click a blog, it is displayed in an automatically generated page with the same layout as the list page.

    • Selected existing page…
      From the list of existing pages, select the specific page in which blogs are displayed.

    • Default page for blog
      The default page set in the backend when creating or editing a blog item will be used.

NOTE: To display a blog in a page, the page must have a Blogs widget added in advance.

  • Detail template
    Select the template you want to use to display blogs on the webpage.

  • CSS classes
    Expand More options section to specify CSS file names and apply additional CSS classes to the Blogs widget.

Advanced settings

In Advanced settings, you specify individual properties of the widget:

  • DetailPageMode
    Defines the location where you should be redirected when you click a blog title. Available options are:

    • PerItem
      This is the default option. If this option is selected, the individual settings of the blog item are used. You can set different page when you create or edit the blog post.
    • SamePage
      The same page is used to display details of the blog when you click the blog title.
    • SelectedExistingPage
      The details of the blog are opened in the page with ID DetailsPageId in case there is a Blogs widget dropped there.
  • DetailsPageId
    Gets the ID of the page you selected in the Selected existing page.. option in the Single item settings tab page.

  • DetailTemplateName
    Gets the template you selected in the Detail template dropdown menu in the Single item settings tab page.

  • ListTemplateName
    Gets the template you chose in the List template dropdown menu in the List settings tab page.

Model settings

Model settings display all properties directly bound to the Blogs widget model. Access these properties by clicking the Model button in Advanced settings.

  • ContentViewDisplayMode
    By default, a single content item is displayed in Detail view. This property enables you to configure whether single content items are displayed in Detail or in List view by entering Detail or List, respectively.

  • DetailCssClass
    Gets and sets an additional CSS class to the detail view of a blog item.

  • DisplayMode
    Gets the value you selected in the Simple List settings tab page:

    • Paging
      This is the default option.
    • Limit
    • All
  • FilteredSelectionMode
    Defines whether to filter blog items depending on the blog posts they contain. Choose one of the following options:

    • MinPostsCount
    • MaxPostsAge
  • ItemsPerPage
    Defines the number of blogs per page when paging is enabled. The default value is 20.
  • ListCssClass
    Gets and sets an additional CSS class to the list view.
  • MaxPostsAge
    Defines period when the post for a blog should be created in order this blog to be displayed option Only blogs that have posts not older than… months is selected.
  • MinPostsCount
    Defines minimum posts count that a blog should have in order to be displayed when option Blogs with more than … posts is selected.
  • ProviderName
    If you have more than one providers added, you can use a blogs providers different than the default one. To do this, specify the name of this provider.

    NOTE: If you leave this property value empty, the default blogs provider is used.

  • SelectionMode
    Gets the option that you chose in the Content tab page. The possible values you can chose from are:
    • AllItems
    • SelectedItems
    • FilteredItems
  • SerializedSelectedItemsIds
    In case you specifically select some blogs, the IDs of the selected blogs are serialized and populated in that field. For example: ["3f47d0b8-2d22-6e58-888c-ff0000bfc4e0"]
  • SortExpression
    Adds additional sorting expression for the blogs. The default value is PublicationDate DESC.

Additional resources

ARTICLES

Increase your Sitefinity skills by signing up for our free trainings. Get Sitefinity-certified at Progress Education Community to boost your credentials.

Get started with Integration Hub | Sitefinity Cloud | Sitefinity SaaS

This free lesson teaches administrators, marketers, and other business professionals how to use the Integration hub service to create automated workflows between Sitefinity and other business systems.

Web Security for Sitefinity Administrators

This free lesson teaches administrators the basics about protecting yor Sitefinity instance and its sites from external threats. Configure HTTPS, SSL, allow lists for trusted sites, and cookie security, among others.

Foundations of Sitefinity ASP.NET Core Development

The free on-demand video course teaches developers how to use Sitefinity .NET Core and leverage its decoupled architecture and new way of coding against the platform.

Tags

Was this article helpful?

Next article

Blog posts widget