Subscribe:

Labels

Wednesday, June 1, 2011

Feature Stapling


Using Feature stapling, you can activate default/custom features when a new site/web will be created.
The requirement of feature stapling roots to the problem of having certain features automatically activated when a new site(through site definition) is created. So we have 2 options to do this types of requirements.


1)Modifying the site definition(onet.xml)(Not a good practice)
2)Feature stapling(Feature inside feature).

Feature stapling means its nothing but nested features.

To create a staple you actually create another Feature that does the staple.

Feature stapling is implemented through a Feature that is specifically designed to staple other Features to one or more site definitions. Feature stapling allows a Feature to be stapled to any new sites created from any site definition or from specific site definitions based on the template name identified in the appropriate WEBTEMP.xml file.



No comments:

Post a Comment