O'Reilly logo

SharePoint 2013 WCM Advanced Cookbook by John Chapman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Creating a site feature to apply branding

SharePoint features provide a mechanism to add our custom branding elements to the SharePoint farm at four different scopes. Features can be scoped to the farm level, web application level, site collection level, or site (web) level. In addition to adding content, they can run custom code when activated, upgraded, deactivated, and so on in feature event receivers.

In this recipe, we will create a site (web) scoped feature that adds and configures our branding elements on the site.

How to do it...

Follow these steps to create a feature event receiver:

  1. Open the SiteBranding feature that was created when creating for our MasterPages and PageLayouts modules.
  2. Verify that both the modules are listed in the Items ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required