In my previous article, I provided detailed information about details of how Content Availability feature is implemented. Now I will give practical information for Content Authors, how to work with Content Availability feature.
The content availability feature ensures that the valid version of an item is always available in the target database at the time of publishing. In this way, you do not have to perform a publishing operation every time an item version expires and the next version should be displayed.
Sitecore Documentation
First, change the mindset.
In Sitecore interface for change publish restriction there are two terms Publishable from / Publishable to. That can be confusing. Becasue when Content Availability feature is enabled you configure when item or version should be visible not published. You should translate this terms in your mind.
Publish from means – Item or version is visible/available from
Publish to means – Item or version is Visible/Available to
You configure a publish settings for item or version and publish item once. Depends on your configuration one or more version of the item is published together and Content Availability mechanism decides what version and when should be presented to end-users.

Set up an item availability.
Item availability is responsible for set up availability for all versions of an item. To configure an item availability, you should choose a tab Item in Publish Settings. Let’s assume that an item represents a content page. It means that the page is available for end-users in a range defined in fields ‘Publishable from’ and ‘Publishable to’.

On the timeline below is presented how the page will behave, when we configure item availability. By 11:45, the user will see page 404 – Page not found. At 11:45, the correct page will be available. And again at 11:50 you will receive a 404 error.

Set up a version availability.
With version availability we can set up availability restrictions for a single version of item. With version availability settings you can control availability of each version of item.


Time Zones, Time Zones, everywhere.
I have a bad news for you, if you are not time zones expert. All settings that you configure uses a server time. You have to understand that time on server can be different then your local time.
Sitecore CMS/XP Client UI does not support local user time zone for the DateTime field control. Sitecore always renders the date/time values with a time zone specified by the ServerTimeZone setting. If the ServerTimeZonesetting value is empty, the server machine time zone is used by default.
https://kb.sitecore.net/articles/285362
What not to do?
Please do not configure ‘Publishabe To‘ when next version should be visible after previous. It is enough to define Publishable From. Content Availability feature takes into consideration only version 3.

When can this happen? For example, the content author creates a version 2 of the item and define a range of dates when this version is visible, and publish an item.
After some time the same or next content author add version 3 and set Publishable from but not clear a Publishable to from the previous version. When this item will be published, this can cause 404 error, becasue only version 3 will be published.
What next?
I plan to describe the following topics in the next few days/weeks. All of them was developed to make content authors more convenient and comfortable.
- Record a demo to show how CA feature works in practice
- Describe a Publishing Settings extension that allows content authors use a local time in date/time control.
- Describe how we implemented a ClearHTML and ClearAkamai cache
- Describe how we implemented a “Publish Info” button to show and validate CA settings.
Any questions or remarks? Please mind me on a Twitter @RobsonAutomator.
1 comment