Set Auto Publish on Item
Sitecore provide feature to Auto publish the
content with few configuration changes. With this content will publish
automatically based on time line set in Sitecore.Tasks.PublishAgent of
Sitecore.config file. To set auto publishing on content it’s require to make changes
in Publishing Agent which looks like.
<agent type="Sitecore.Tasks.PublishAgent"
method="Run" interval="00:00:00">
<param desc="source database">master</param>
<param desc="target database">web</param>
<param desc="mode (full or smart or
incremental)">incremental</param>
<param desc="languages">en, da</param>
</agent>
I am trying to giving a simple example with
home page which comes content root by default after fresh installation of
sitecore. Initially a default content is coming in Title field Sitecore
Experience Platform”.
Output of this content page looks like.
Now I am going to change the content of Title
filed of Home content. Before changing the content I had change few Params in
Publishing Agent as displayed in bold.
<agent type="Sitecore.Tasks.PublishAgent"
method="Run" interval="00:00:10">
<param desc="source database">master</param>
<param desc="target database">web</param>
<param desc="mode (full or smart or incremental)">incremental</param>
<param desc="languages">en, da</param>
</agent>
After making above changes in Sitecore.config
. Go to Sitecore instance and click on change icon then a publishing settings window will popup. Make changes in
Publishable From and to accordingly.
Once Publishing settings set as per our
requirement then change the content of item. I change the content of Title
filed and save the content.
I just wait for 15 seconds and got the
automatic content change on Home page.
Once page is refresh then content on the web
page get changed.
Other than default auto publishing approach we
can use few components from market place of Sitecore. These components gives
more flexibility for automatic publishing of content based on different
features. I am sharing some components URL from market place which I generally
use for Auto publishing.
After installing any above component you will
get more options for publishing like in below screen shot.
In this way you can set auto publish on content items. You can use above components as well to apply auto publishing on specific item with different conditions.
Happy Learning!!!
Comments
Post a Comment