Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt. Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?
Experience Sitecore! | The quickest acceess to Layout Details dialog of Presentaion Details

Experience Sitecore!

Martin Miles on Sitecore

The quickest acceess to Layout Details dialog of Presentaion Details

This post going to be a quicke one. One of the most frequent screens I have to deal with in Sitecore is Layout Details dialog of Presentation Details:

I thought once, why not just to have the link to it from item's Context Menu? Sounds good, but, foirst of all, what is context menu?

Context Menu is just a set of Sitecore items under /sitecore/content/Applications/Content Editor/Context Menues/Default folder within core database. Each child item (except dividers) is derived from Menu Item template. The most interesting field there is Message - its value stores is nothing but just a Sitecore command with a parameter of current item (as all that happens in item's context).

Just want to remind - Sitecore commands are defined at <web_root>\App_config\Commands.config file, you may freely use any of them that start with item: (but not limited to that).

So, the only thing we need to do is to create an item under /sitecore/content/Applications/Content Editor/Context Menues/Default folder, and set its message to item:setlayoutdetails and that's it. Also you may configure Display name and the Icon to be shown next to that label within context menu (something like Applications/32x32/document_gear.png)

As soon as you return to master database, you'll get new context menu shortcut working:

This trick works on all versions of Sitecore. For lazy guys - here's a package for download that will do exactly the same - create Set presentation item for you within core database.

Hope this helps!

blog comments powered by Disqus