Monday, August 22, 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

Diffrence b/w Team site and Publishing site

 

Team Site template :Bi –directional.--> a simple site template designed to help a group of people (a team?!?!) work together to exchange information and ideas.
Team site is a basic blank site with few extra list templates like announcements, task list etc. This is generally used for intranet application like employee portal. The team site is available both in moss and wss.
Publishing site : Uni-directional. à it is one way and more over we can use this for internet sites and it is have some extra features than team site.it is mostly developed by the custom page layouts.

Publishing site is used mostly for internet facing sites where there is need to create update delete webpages quickly. This template is available only in moss.
And if u want create sub site as publishing site the main site collection should be publishing site .

Tuesday, June 14, 2011

Working with the SharePoint 2010 Ribbon and In-place Editing


Working with the SharePoint 2010 Ribbon and In-place Editing

In this exercise you will work with the site collection created in Exercise 1. You will:
·         Experience the new paradigm for in-place editing by adding and viewing list items.
·         Work with a Web Part page so you can experience how the SharePoint 2010 user interface has changed the way users manage Web Parts.

Task 1 – Modifying the Home page content

In this task you will modify text and the default image on the home page.

1.    Ensure you are viewing the Contoso Sales Site that you created in the previous exercise.
Note that the home page is not default.aspx but rather a wiki page named Home.aspx.This is a wiki page located inside a library named SitePages.
2.    Near the top left of the page, click theSite Actions menu, and then clickEdit Page.
The site enters edit mode with the cursor indicating the current insert point.

Figure 1 - The Site Actions menu
3.    Select the text Welcome!andthen press [Delete]. Then typeContoso Sales Site.
Note the ribbon commands update to provide contextual commands editing text.


4.    Select the text Contoso Sales Siteand use the font toolbar to change the font to 36pt and Font Color Red.
5.    Click the graphic on the right-hand side of the page and press [Delete].
6.    On the ribbon, under Editing Tools, click theInsert tab.
7.    Click the Picture button.
The Add Picture dialog box appears. Note that the Add Picture dialog box enables you to select an image which will be automatically uploaded and stored in a document library named Site Asset Library.
8.    Click Browse and navigate the following file:
C:\Student\Labs\01_Roadmap\starterfiles\FrontPage.jpgthen click Open.
9.    On the Add Picture dialog, click OK.
10.  On the ribbon, under Editing Tools, click the Format Text tab.
11.  On the ribbon, click Save.

Figure 3 - The Edited Page



Task 2 – Modifying Site Settings

In this task you will explore settings available for the site from the Site Actions menu.

1.    Click the Site Actions menu, and then clickSite Settings.
This page contains links to numerous administrative features.

Figure 4 - Site Settings

2.    In the Look and Feel section, click Title, description and appearance.
The Title, Description and Appearance page appears. This page enables you to change the title and description you entered in the previous exercise.
3.    In the Logo URL and Description section, in the URL textbox, type the following:/_layouts/images/unknownperson.png
4.    Click OK.
The Site Settings page appears. The image in the ribbon has been updated.

Figure 5 - Modified Logo

Task 3 – Using the server-side ribbon

In this task you will use the server-side ribbon and review the contextual controls that appear for items that are selected.

1.    On the Quick Launch bar,in the Lists section, click Tasks.
The task list is displayed, and is currently empty. The tasks list has an associated server-side ribbon with tabs including Browse, Share & Track, Items and List.

2.    On the Ribbon, click List.
The ribbon displays contextual controls for the List task.


Figure 6 - List Ribbon
3.    On the Ribbon, click Items.
The ribbon displays contextual controls for the Items task.


Figure 7 - Items Ribbon



Task 4 – Creating a Task and a dependent Task item

In this task you will use the new dialog platform to create a task and a dependent task.

1.    Click the dropdown arrow on the New Item button, and then click Task.
The Tasks - New Item dialog box displays.


Figure 8 - Tasks - New Item Dialog
2.    In the Title textbox, type Learn how to develop on SharePoint 2010.
3.    In the Priority dropdown list, select (1) High.
4.    In the Status dropdown list, select In Progress.
5.    In the % Complete textbox, type 2.
6.    In the Assigned to textbox, typeContoso\Administrator
7.    In the Description textbox, type Find out how to develop useful solutions.
8.    In the Start Date textbox, type 12/1/2009
9.    In the Due Date textbox, type 12/4/2009
10.  On the toolbar, click Save.
The newly created task appears in the list.
11.  Click the dropdown arrow on the New Item button, and then click Task.
12.  In the Title textbox, type Develop Solutions on SharePoint 2010.
13.  In the Predecessors list box, select how to develop on SharePoint 2010 and click Add.
14.  In the Priority dropdown list, select (1) High.
15.  In the Status dropdown list, select Not Started.
16.  In the % Complete textbox, type 0.
17.  In the Assigned to textbox, typeContoso\Administrator
18.  In the Description textbox, type Begin developing solutions on SharePoint 2010.
19.  In the Start Date textbox, type 12/5/2009
20.  Leave theDue Date textbox blank.
21.  On the toolbar, click Save.
The newly created task appears in the list.


Figure 9 - List of Tasks

Task 5 – Editing a Task

In this task you will observe the in-place editing behavior as you edit a task.

1.    Point to the Learn how to develop on SharePoint 2010 task, and then click the dropdown arrow that appears.

Figure 10 - In-Place Editing
2.    Click Edit Item.
Note that no page post backs occur; the task can be edited in-place.
3.    Modify the % Complete textbox so that it reads 5
4.    Click Save.

Task 6 – Add a Web Part to a page

In this task you will add a Web Part toa Web Part page using the new user interface for managing Web Parts.

1.    In Internet Explorer type following URL:
http://intranet.contoso.com/sites/Lab01A/default.aspx This URL opens a Web Part page that does not have a direct link on a newly created site. Note the ribbon options that are available for this Web Part page.
2.    Note that the ribbon on this page has three tabs titled Browse, Page and Edit Tools. Click on each of these tabs and see how the contextual controls on the ribbon change for each of these tabs.


3.    Click on the Insert tab that takes you into the mode for adding, modifying and deleting Web Parts from the page
4.    Delete the Shared Documents Web Part in the Left Web Part Zone by clicking on the Delete command inside their Web Part menu.


Figure 11 - Deleting a Web Part
5.    Click the OK button on the Message from webpage dialog.
6.    Place your cursor below the Welcome message
7.    On the ribbon, in the Page Tools section, click Insert.
8.    Click on the Web Part button which is shown below.


Figure 12 - Deleting a Web Part

9.    At this point you should see the new SharePoint 2010 UI for adding new Web Parts to a page. Select Lists and Libraries in the left-hand section and then select Tasks in the right-hand section. Once you have select the Tasks list, make sure the drop-down box on the far right bottom (shown below) has the Left Web Part zone selected, then click the Add button to add the Web Part instance to the page.


Figure 13- Web Part Interface

10.  Save your changes by selecting the Save button on the ribbon. Now that you have completed this exercise, you should have a page that looks like the one shown below.


Figure 14- Tasks web part on the site