Step1: Run the given sql Query.
Reference URL: http://blogs.technet.com/corybu/
Copy Follwoing Code:
Use MSDB
Drop table orphanlist
CREATE TABLE [dbo].[orphanlist](
[farm] [varchar](250) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[databasename] [varchar](250) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[SiteID] [uniqueidentifier] NULL,
[sitepath] [varchar](250) COLLATE SQL_Latin1_General_CP1_CI_AS NULL,
[type] [varchar](250) COLLATE SQL_Latin1_General_CP1_CI_AS NULL
)
drop table orphan_hopper
declare
@dbname as varchar(250),
@cmdstr as varchar(2000),
@dbid as varchar(250),
@configdb as varchar(250)
/** only change the following line and nothing else, change spskills_config_db to your config db name **/
select @configdb = 'spskills_config_db'
/** Change nothing below this line **/
select @cmdstr =
'select distinct b.name as ''databasename'', b.id as ''dbid'' into orphan_hopper
from
[' + @configdb + '].dbo.sitemap as a inner join
[' + @configdb + '].dbo.objects as b on a.databaseid=b.id inner join
[' + @configdb + '].dbo.objects as c on c.id=a.applicationid inner join
[' + @configdb + '].dbo.objects as d on b.parentid=d.id inner join
[' + @configdb + '].dbo.objects as e on d.parentid=e.id '
exec (@cmdstr)
DECLARE DBCursor CURSOR For
Select databasename, dbid
From orphan_hopper
OPEN DBCursor
FETCH NEXT FROM DBCursor into @DBName, @dbid
WHILE @@FETCH_STATUS =0
BEGIN
INSERT INTO orphanlist([Type], farm, databasename,[sitepath], SiteID)
EXEC
('
select ''Potential ConfigDB orphan:'' + '''+@dbname+''' as [Type], '''+@configdb+''' as [farm], '''+@dbname+''' as [databasename],path as [sitepath], id as [SiteID] from ['+@configdb+'].dbo.sitemap where id not in (select id from ['+@dbname+'].dbo.sites) and databaseid = '''+@dbid+'''
union
select ''Potential ConfigDB orphan:'' + '''+@dbname+''' as [Type], '''+@configdb+''' as [farm], '''+@dbname+''' as [databasename],path as [sitepath], id as [SiteID] from ['+@configdb+'].dbo.sitemap where id not in (select siteid from ['+@dbname+'].dbo.webs where parentwebid is null) and databaseid = '''+@dbid+'''
union
select ''Potential ContentDB orphans:'' + '''+@dbname+''' as [Type], '''+@configdb+''' as [farm], '''+@dbname+''' as [databasename],fullurl as [sitepath], siteid as [SiteID] from ['+@dbname+'].dbo.webs where parentwebid is null and siteid not in (select id from ['+@configdb+'].dbo.sitemap where databaseid = '''+@dbid+''')
union
select ''Potential ContentDB orphan:'' + '''+@dbname+''' as [Type], '''+@configdb+''' as [farm], '''+@dbname+''' as [databasename],fullurl as [sitepath], siteid as [SiteID] from ['+@dbname+'].dbo.webs where parentwebid is null and siteid not in (select id from ['+@dbname+'].dbo.sites)
')
FETCH NEXT FROM DBCursor into @DBName, @dbid
END
CLOSE DBCursor
DEALLOCATE DBCursor
select * from orphanlist
Step2: Delete the Content DB
stsadm.exe -o deletecontentdb -url http://ServerName -databasename wss_content -databaseserver ServerName
Operation completed successfully.
Step3: Add Content DB
stsadm.exe -o addcontentdb -url http://ServerName -databasename wss_content -databaseserver ServerName
Operation completed successfully.
Monday, April 27, 2009
Friday, April 24, 2009
Exception from HRESULT: 0x80040E14
Exception from HRESULT: 0x80040E14
If any of you have come across this error "Exception from HRESULT: 0x80040E14" while trying to do a STSADM restore, it's a very simple problem. It means the SQL server has run out of space for either the logs or the data file. Simply delete some un-needed files from the HDD that the SQL server is writting to and it fixes the problem.
If any of you have come across this error "Exception from HRESULT: 0x80040E14" while trying to do a STSADM restore, it's a very simple problem. It means the SQL server has run out of space for either the logs or the data file. Simply delete some un-needed files from the HDD that the SQL server is writting to and it fixes the problem.
Tuesday, April 7, 2009
Sharepoint 2007 Custom Search
Points we need to make sure before using Search Option
Open the project "SharePoint.Search".
Go to the method "ExecuteFullTextSqlQuery" In SearchResults.ascx.cs page, where we can see query which retrieves data
"SELECT FileExtension, Rank, ContentClass, Path, Title, Abstract, IsDocument FROM SCOPE()"
Go to Central Administration,
Shared Services Administration: SharedServices1 > Search Settings > Managed Properties
Open Metadata Property Mappings page
Check All the fields which is specified in the query exist or not .
If the fields doesn't exist, go to New Managed Property at the top and add the field.
Check the checkbox "Use in Scope"
Common errors which may occur are :
Property doesn't exist or is used in a manner inconsistent with schema settings.
Possible reason : Field doesn't exist in Metadata Property Mappings
Your query is malformed. Please rephrase your query
Possible reason : Query is nor formatted properly
After doing this, again if the data is not coming, Comment the line
//sbFullTextSqlQuery.Append(" \"Scope\" = '" + _scope + "' ");
Because this may give error as "Scope in your query does not exist"
To know more about how this works, check this links
http://msdn2.microsoft.com/en-us/library/bb608305.aspx
http://www.ureader.com/msg/12294188.aspx
The code below says about how we can customize sharepoint search option
protected void btnSearch_Click(object sender, EventArgs e)
{
ResultTableCollection resultTableCollection = FetchRelevantSearchResults();
ResultTable relevantResultsResultTable = resultTableCollection[ResultType.RelevantResults];
DataTable relevantResultsDataTable = new DataTable();
relevantResultsDataTable.Load(relevantResultsResultTable, LoadOption.OverwriteChanges);
if (relevantResultsDataTable != null)
{
grdSearch.DataSource = relevantResultsDataTable;
grdSearch.DataBind();
}
}
// Fetch search result
private ResultTableCollection FetchRelevantSearchResults()
{
ResultTableCollection resultTableCollection = null;
SPSecurity.RunWithElevatedPrivileges(delegate()
{
try
{
ExecuteFullTextSqlQuery(out resultTableCollection);
}
catch (Exception ex)
{
}
});
return resultTableCollection;
}
// Call CAML query
private void ExecuteFullTextSqlQuery(out ResultTableCollection resultTableCollection)
{
// Guid _currentSiteGuid = SPContext.Current.Site.ID;
//using (SPSite _SPSite = new SPSite(_currentSiteGuid))
//http://mossdev:6076
//http://mossdev:35643/
using (SPSite _SPSite = new SPSite("http://mossdev:35643"))
{
using (FullTextSqlQuery _FullTextSqlQuery = new FullTextSqlQuery(_SPSite))
{
_FullTextSqlQuery.StartRow = 0;
_FullTextSqlQuery.RowLimit = 2;
_FullTextSqlQuery.HighlightedSentenceCount = 3;
_FullTextSqlQuery.EnableStemming = true;
_FullTextSqlQuery.TrimDuplicates = true;
_FullTextSqlQuery.Culture = CultureInfo.CurrentCulture;
_FullTextSqlQuery.KeywordInclusion = KeywordInclusion.AnyKeyword;
if (SPSecurity.AuthenticationMode != AuthenticationMode.Windows)
{
_FullTextSqlQuery.AuthenticationType = QueryAuthenticationType.PluggableAuthenticatedQuery;
}
else
{
_FullTextSqlQuery.AuthenticationType = QueryAuthenticationType.NtAuthenticatedQuery;
}
_FullTextSqlQuery.ResultTypes = ResultType.RelevantResults;
StringBuilder sbFullTextSqlQuery = new StringBuilder(string.Empty);
sbFullTextSqlQuery.Append("SELECT ");
sbFullTextSqlQuery.Append(" FileExtension, Rank, ContentClass, Path, Title, Abstract, IsDocument ");
sbFullTextSqlQuery.Append("FROM ");
sbFullTextSqlQuery.Append(" SCOPE() ");
sbFullTextSqlQuery.Append("WHERE ");
sbFullTextSqlQuery.Append(" FREETEXT(defaultproperties, 'raj') ");
sbFullTextSqlQuery.Append("AND ");
sbFullTextSqlQuery.Append(" \"Scope\" = 'Knowledge Objects' ");
sbFullTextSqlQuery.Append("AND ");
sbFullTextSqlQuery.Append(" ( ");
sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') ");
sbFullTextSqlQuery.Append(" OR ");
sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') ");
sbFullTextSqlQuery.Append(" OR ");
sbFullTextSqlQuery.Append(" (ContentClass = 'STS_Web') ");
sbFullTextSqlQuery.Append(" ) ");
sbFullTextSqlQuery.Append("ORDER BY ");
sbFullTextSqlQuery.Append(" Rank DESC ");
// sbFullTextSqlQuery = new StringBuilder();
//sbFullTextSqlQuery.Append("SELECT Title, Abstract, Rank FROM scope() WHERE scope='All Sites' ");
//sbFullTextSqlQuery.Append("SELECT Account,CreatedBy FROM scope() ");
// fields needs mapping Title,Abstract,
// sbFullTextSqlQuery.Append("SELECT FileExtension, Rank, contentclass, Path,IsDocument FROM SCOPE() WHERE FREETEXT(defaultproperties, 'company') AND Scope = 'Knowledge Objects' AND ( (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') OR (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') OR (ContentClass = 'STS_Web') ) ORDER BY Rank DESC") ;
//sbFullTextSqlQuery.Append("SELECT FileExtension,contentclass,Rank,Path,IsDocument FROM SCOPE() WHERE FREETEXT(defaultproperties, 'company')");
//sbFullTextSqlQuery.Append("AND ");
//sbFullTextSqlQuery.Append(" ( ");
//sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') ");
//sbFullTextSqlQuery.Append(" OR ");
//sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') ");
//sbFullTextSqlQuery.Append(" OR ");
//sbFullTextSqlQuery.Append(" (ContentClass = 'STS_Web') ");
//sbFullTextSqlQuery.Append(" ) ");
//sbFullTextSqlQuery.Append("ORDER BY ");
//sbFullTextSqlQuery.Append(" Rank DESC ");
//sbFullTextSqlQuery.Append("SELECT ");
//sbFullTextSqlQuery.Append("Title,Abstract, FileExtension, Rank, ContentClass, Path,IsDocument ");
//sbFullTextSqlQuery.Append("FROM ");
//sbFullTextSqlQuery.Append(" SCOPE() ");
//sbFullTextSqlQuery.Append("WHERE ");
//sbFullTextSqlQuery.Append(" FREETEXT(defaultproperties, 'company') ");
_FullTextSqlQuery.QueryText = sbFullTextSqlQuery.ToString();
resultTableCollection = _FullTextSqlQuery.Execute();
}
_SPSite.RootWeb.Dispose();
}
}
Open the project "SharePoint.Search".
Go to the method "ExecuteFullTextSqlQuery" In SearchResults.ascx.cs page, where we can see query which retrieves data
"SELECT FileExtension, Rank, ContentClass, Path, Title, Abstract, IsDocument FROM SCOPE()"
Go to Central Administration,
Shared Services Administration: SharedServices1 > Search Settings > Managed Properties
Open Metadata Property Mappings page
Check All the fields which is specified in the query exist or not .
If the fields doesn't exist, go to New Managed Property at the top and add the field.
Check the checkbox "Use in Scope"
Common errors which may occur are :
Property doesn't exist or is used in a manner inconsistent with schema settings.
Possible reason : Field doesn't exist in Metadata Property Mappings
Your query is malformed. Please rephrase your query
Possible reason : Query is nor formatted properly
After doing this, again if the data is not coming, Comment the line
//sbFullTextSqlQuery.Append(" \"Scope\" = '" + _scope + "' ");
Because this may give error as "Scope in your query does not exist"
To know more about how this works, check this links
http://msdn2.microsoft.com/en-us/library/bb608305.aspx
http://www.ureader.com/msg/12294188.aspx
The code below says about how we can customize sharepoint search option
protected void btnSearch_Click(object sender, EventArgs e)
{
ResultTableCollection resultTableCollection = FetchRelevantSearchResults();
ResultTable relevantResultsResultTable = resultTableCollection[ResultType.RelevantResults];
DataTable relevantResultsDataTable = new DataTable();
relevantResultsDataTable.Load(relevantResultsResultTable, LoadOption.OverwriteChanges);
if (relevantResultsDataTable != null)
{
grdSearch.DataSource = relevantResultsDataTable;
grdSearch.DataBind();
}
}
// Fetch search result
private ResultTableCollection FetchRelevantSearchResults()
{
ResultTableCollection resultTableCollection = null;
SPSecurity.RunWithElevatedPrivileges(delegate()
{
try
{
ExecuteFullTextSqlQuery(out resultTableCollection);
}
catch (Exception ex)
{
}
});
return resultTableCollection;
}
// Call CAML query
private void ExecuteFullTextSqlQuery(out ResultTableCollection resultTableCollection)
{
// Guid _currentSiteGuid = SPContext.Current.Site.ID;
//using (SPSite _SPSite = new SPSite(_currentSiteGuid))
//http://mossdev:6076
//http://mossdev:35643/
using (SPSite _SPSite = new SPSite("http://mossdev:35643"))
{
using (FullTextSqlQuery _FullTextSqlQuery = new FullTextSqlQuery(_SPSite))
{
_FullTextSqlQuery.StartRow = 0;
_FullTextSqlQuery.RowLimit = 2;
_FullTextSqlQuery.HighlightedSentenceCount = 3;
_FullTextSqlQuery.EnableStemming = true;
_FullTextSqlQuery.TrimDuplicates = true;
_FullTextSqlQuery.Culture = CultureInfo.CurrentCulture;
_FullTextSqlQuery.KeywordInclusion = KeywordInclusion.AnyKeyword;
if (SPSecurity.AuthenticationMode != AuthenticationMode.Windows)
{
_FullTextSqlQuery.AuthenticationType = QueryAuthenticationType.PluggableAuthenticatedQuery;
}
else
{
_FullTextSqlQuery.AuthenticationType = QueryAuthenticationType.NtAuthenticatedQuery;
}
_FullTextSqlQuery.ResultTypes = ResultType.RelevantResults;
StringBuilder sbFullTextSqlQuery = new StringBuilder(string.Empty);
sbFullTextSqlQuery.Append("SELECT ");
sbFullTextSqlQuery.Append(" FileExtension, Rank, ContentClass, Path, Title, Abstract, IsDocument ");
sbFullTextSqlQuery.Append("FROM ");
sbFullTextSqlQuery.Append(" SCOPE() ");
sbFullTextSqlQuery.Append("WHERE ");
sbFullTextSqlQuery.Append(" FREETEXT(defaultproperties, 'raj') ");
sbFullTextSqlQuery.Append("AND ");
sbFullTextSqlQuery.Append(" \"Scope\" = 'Knowledge Objects' ");
sbFullTextSqlQuery.Append("AND ");
sbFullTextSqlQuery.Append(" ( ");
sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') ");
sbFullTextSqlQuery.Append(" OR ");
sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') ");
sbFullTextSqlQuery.Append(" OR ");
sbFullTextSqlQuery.Append(" (ContentClass = 'STS_Web') ");
sbFullTextSqlQuery.Append(" ) ");
sbFullTextSqlQuery.Append("ORDER BY ");
sbFullTextSqlQuery.Append(" Rank DESC ");
// sbFullTextSqlQuery = new StringBuilder();
//sbFullTextSqlQuery.Append("SELECT Title, Abstract, Rank FROM scope() WHERE scope='All Sites' ");
//sbFullTextSqlQuery.Append("SELECT Account,CreatedBy FROM scope() ");
// fields needs mapping Title,Abstract,
// sbFullTextSqlQuery.Append("SELECT FileExtension, Rank, contentclass, Path,IsDocument FROM SCOPE() WHERE FREETEXT(defaultproperties, 'company') AND Scope = 'Knowledge Objects' AND ( (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') OR (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') OR (ContentClass = 'STS_Web') ) ORDER BY Rank DESC") ;
//sbFullTextSqlQuery.Append("SELECT FileExtension,contentclass,Rank,Path,IsDocument FROM SCOPE() WHERE FREETEXT(defaultproperties, 'company')");
//sbFullTextSqlQuery.Append("AND ");
//sbFullTextSqlQuery.Append(" ( ");
//sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_DocumentLibrary') ");
//sbFullTextSqlQuery.Append(" OR ");
//sbFullTextSqlQuery.Append(" (IsDocument = 1 AND ContentClass = 'STS_ListItem_850') ");
//sbFullTextSqlQuery.Append(" OR ");
//sbFullTextSqlQuery.Append(" (ContentClass = 'STS_Web') ");
//sbFullTextSqlQuery.Append(" ) ");
//sbFullTextSqlQuery.Append("ORDER BY ");
//sbFullTextSqlQuery.Append(" Rank DESC ");
//sbFullTextSqlQuery.Append("SELECT ");
//sbFullTextSqlQuery.Append("Title,Abstract, FileExtension, Rank, ContentClass, Path,IsDocument ");
//sbFullTextSqlQuery.Append("FROM ");
//sbFullTextSqlQuery.Append(" SCOPE() ");
//sbFullTextSqlQuery.Append("WHERE ");
//sbFullTextSqlQuery.Append(" FREETEXT(defaultproperties, 'company') ");
_FullTextSqlQuery.QueryText = sbFullTextSqlQuery.ToString();
resultTableCollection = _FullTextSqlQuery.Execute();
}
_SPSite.RootWeb.Dispose();
}
}
Wednesday, February 25, 2009
Dooly's Domain: Publishing InfoPath Forms - Updating Content Type Failed
I'm also getting the same issue. Can u help me, how to fix this issue.
Monday, January 12, 2009
Configure MOSS 2007 Site Usage Reports
Three Quick Steps to Configure Site Usage Reporting
Enable Usage Logging in Central Administration
A. On the Central Administration home page, click Operations.
B. On the Operations page, in the Logging and Reporting section, click Usage analysis processing.
C. On the Usage Analysis Processing page, in the Logging Settings section, select Enable logging.
D. Type a log file location and number of log files to create.
E. In the Processing Settings section, select Enable usage analysis processing, and then select a time to run usage processing.
Enable Usage Reporting on SSP Admin Page
A. On the SSP home page, in the Portal Usage Reporting section, click Usage reporting.
B. On the Configure Advanced Usage Analysis Processing page, in the Processing Settings section, click Enable advanced usage analysis processing.
C. In the Search Query Logging section, select Enable search query logging.
Activate the Reporting Feature for the Site Collection
A. On the Site Actions menu, click Site Settings.
B. On the Site Settings page, in the Site Collection Administration section, click Site collection features.
C. On the Site Collection Features page, click the Activate button for the Reporting feature.
After site usage reporting is enabled the site administrators and site collection administrators will be able to view reports detailing:
Requests and queries in the last day and the last 30 days
Average number of requests per day over the last 30 days
Requests per day over the last 30 days
Top page requests over the last 30 days
Top users over the last 30 days
Top referring hosts over the last 30 days
Top referring pages over the last 30 days
Top destination pages over the last 30 days
Top search queries for the last 30 days
Search results top destination pages
Number of search queries per day over the previous 30 days
Number of search queries per month over the previous 12 months
Top search queries over the previous 30 days
Search Queries per search scope over the previous 30 days
Site collection administrators will be able to view reports detailing:
Total amount of storage used by the site collection
Percent of storage space used by Web Discussions
Maximum storage space allowed
Number of users for all sites in the hierarchy
Total hits and recent bandwidth usage across all sites
Enable Usage Logging in Central Administration
A. On the Central Administration home page, click Operations.
B. On the Operations page, in the Logging and Reporting section, click Usage analysis processing.
C. On the Usage Analysis Processing page, in the Logging Settings section, select Enable logging.
D. Type a log file location and number of log files to create.
E. In the Processing Settings section, select Enable usage analysis processing, and then select a time to run usage processing.
Enable Usage Reporting on SSP Admin Page
A. On the SSP home page, in the Portal Usage Reporting section, click Usage reporting.
B. On the Configure Advanced Usage Analysis Processing page, in the Processing Settings section, click Enable advanced usage analysis processing.
C. In the Search Query Logging section, select Enable search query logging.
Activate the Reporting Feature for the Site Collection
A. On the Site Actions menu, click Site Settings.
B. On the Site Settings page, in the Site Collection Administration section, click Site collection features.
C. On the Site Collection Features page, click the Activate button for the Reporting feature.
After site usage reporting is enabled the site administrators and site collection administrators will be able to view reports detailing:
Requests and queries in the last day and the last 30 days
Average number of requests per day over the last 30 days
Requests per day over the last 30 days
Top page requests over the last 30 days
Top users over the last 30 days
Top referring hosts over the last 30 days
Top referring pages over the last 30 days
Top destination pages over the last 30 days
Top search queries for the last 30 days
Search results top destination pages
Number of search queries per day over the previous 30 days
Number of search queries per month over the previous 12 months
Top search queries over the previous 30 days
Search Queries per search scope over the previous 30 days
Site collection administrators will be able to view reports detailing:
Total amount of storage used by the site collection
Percent of storage space used by Web Discussions
Maximum storage space allowed
Number of users for all sites in the hierarchy
Total hits and recent bandwidth usage across all sites
Wednesday, January 7, 2009
Adding a 'Save site as template' Link to Site Settings in WSS v3/MOSS 2007 using a CustomAction Feature
The SaveSiteAsTemplate feature will consist of a Feature.xml and an Elements.xml file.
Feature.xml declares the Feature itself, and Elements.xml further defines the CustomAction for the Look and Feel menu on a Site Settings page.
To get started, create a folder named SaveSiteAsTemplate below the Features folder located at C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\FEATURES on your WSS v3 server. Create Feature.xml and Elements.xml from the code below and place each file in the SaveSiteAsTemplate folder you just created.
Feature.xml
Note the Scope attribute in the Feature element of Feature.xml. Scope can be set to either Farm, WebApplication, Site or Web. Also notice that the ElementManifest element points to Elements.xml.
Elements.xml
Setting the Location of the CustomAction to Microsoft.SharePoint.Settings and the GroupId to Customization is what decides where the link will be render in the UI.
Next, install the feature into WSS v3 by using the stsadm tool. Stsadm.exe is located in C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN on your WSS v3 server.
stsadm -o installfeature -name SaveSiteAsTemplate
Finally, activate the new feature on your WSS Site by going to Site Settings > Site Features and clicking the Activate button for the new Save Site As Template feature.
Feature.xml declares the Feature itself, and Elements.xml further defines the CustomAction for the Look and Feel menu on a Site Settings page.
To get started, create a folder named SaveSiteAsTemplate below the Features folder located at C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\FEATURES on your WSS v3 server. Create Feature.xml and Elements.xml from the code below and place each file in the SaveSiteAsTemplate folder you just created.
Feature.xml
Note the Scope attribute in the Feature element of Feature.xml. Scope can be set to either Farm, WebApplication, Site or Web. Also notice that the ElementManifest element points to Elements.xml.
Elements.xml
Setting the Location of the CustomAction to Microsoft.SharePoint.Settings and the GroupId to Customization is what decides where the link will be render in the UI.
Next, install the feature into WSS v3 by using the stsadm tool. Stsadm.exe is located in C:\Program Files\Common Files\Microsoft Shared\web server extensions\12\BIN on your WSS v3 server.
stsadm -o installfeature -name SaveSiteAsTemplate
Finally, activate the new feature on your WSS Site by going to Site Settings > Site Features and clicking the Activate button for the new Save Site As Template feature.
You should now see a “Save site as template” link under the Look and Feel menu of the Site Settings page.
Apply top level site UI to all the Sub sites
1. Create the Top Level Sites as per the requirement
2. Change the UI as per the requirement
3. Save the Changed UI as Custom Template
Site Action --> Site Settings --> Save “Site as Template”
A) Enter the FileName: CustomTemplate (Change the file name as per the requirement)
B) Template Name: CustomTemplate (Change the template name as per the requirement)
C) Template Description: CustomTemplate (Change the Description as per the requirement)
D) Finally click ok
4. Active on "Office SharePoint Server Publishing Infrastructure" features.
Site Action --> Site Settings --> Site Collection Administration --> Site Collection Features --> Activate "Office SharePoint Server Publishing Infrastructure" features
5. Activate "Office SharePoint Server Publishing" features
Site Action --> Site Settings --> Site Administration --> Site Features --> Activate "Office SharePoint Server Publishing" features
6. Create the Sub site and inherit the UI from Top Level Site
Site Action --> Create or Create Site
A) Title: As per the requirement
B) Description: As per the requirement
C) URL name: As per the requirement
D) Select a Template: Click the Custom Tab --> Must Select the "CustomTemplate".
E) User Permission: As per the requirement
F) Finally click "Create" option.
7. Apply Top Level site header to sub site
Go to Top Level Site --> Site Action --> Modify All Site Settings --> Look and feel --> Master Page
A) Site Master Page --> Select Default.master --> Check "Reset all sub sites to inherit this Site Master Page setting" check box
B) System Master Page --> Select Default.master --> Check "Reset all sub sites to inherit this system master page setting" check box
C) Finally click ok
2. Change the UI as per the requirement
3. Save the Changed UI as Custom Template
Site Action --> Site Settings --> Save “Site as Template”
A) Enter the FileName: CustomTemplate (Change the file name as per the requirement)
B) Template Name: CustomTemplate (Change the template name as per the requirement)
C) Template Description: CustomTemplate (Change the Description as per the requirement)
D) Finally click ok
4. Active on "Office SharePoint Server Publishing Infrastructure" features.
Site Action --> Site Settings --> Site Collection Administration --> Site Collection Features --> Activate "Office SharePoint Server Publishing Infrastructure" features
5. Activate "Office SharePoint Server Publishing" features
Site Action --> Site Settings --> Site Administration --> Site Features --> Activate "Office SharePoint Server Publishing" features
6. Create the Sub site and inherit the UI from Top Level Site
Site Action --> Create or Create Site
A) Title: As per the requirement
B) Description: As per the requirement
C) URL name: As per the requirement
D) Select a Template: Click the Custom Tab --> Must Select the "CustomTemplate".
E) User Permission: As per the requirement
F) Finally click "Create" option.
7. Apply Top Level site header to sub site
Go to Top Level Site --> Site Action --> Modify All Site Settings --> Look and feel --> Master Page
A) Site Master Page --> Select Default.master --> Check "Reset all sub sites to inherit this Site Master Page setting" check box
B) System Master Page --> Select Default.master --> Check "Reset all sub sites to inherit this system master page setting" check box
C) Finally click ok
Subscribe to:
Posts (Atom)