This is what we posted last year. Please confirm it today. You can also share it with us. Microsoft Office SharePoint Server 2007 file directory structure After MOSS2007 is installed, all SharePoint-related Files are stored in the local directory C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12. The following describes some major file directories. 1. ISAPI directory The Web Services provided by SharePoint are stored in this directory. You can also customize Web Services to be encapsulated in SharePoint. For the Custom Web Services method, see Writing Custom Web Services for SharePoint Products and Technologies. 2. Resources Directory SharePoint has two resource folders in the directory C: \ Program Files \ Common Files \ MicrosoftShared \ web server extensions \ 12 \ CONFIG \ Resources and C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ Resources. Localization mainly involves compiling Files in Resourses, if the title or description displayed on the website does not meet our requirements, you can modify <Data Name = "Modify element"> <Value> content displayed on the website </Value> </Data> The content in the resource file to be referenced generally starts with $ Resources. Example: <% $ Resources: sps, LayoutPageZone_TopZone %> Sps indicates the resource file name, which corresponds to sps. zh-CN.resx. LayoutPageZone_TopZone indicates <Data Name = "LayoutPageZone_TopZone"> <Value> top area </Value> </Data> Node. Note: It is generally not recommended to modify all Files in the C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 directory, because this will cause problems to the version upgrade. To add custom content, add the file to the corresponding directory. For example, we can add a resource file to put the elements we want to modify in it. 3. TEMPLATE directory This is a major directory. Sub-directories are described as follows: (1) SiteTemplates directory Place various website definition templates. Each website definition TEMPLATE has an ONET. XML file located in C: \ Program Files \ Common Files \ Microsoft Shared \ Web Server Extensions \ 12 \ TEMPLATE \ SiteTemplates \ Site_Definition_Name \ XML folder ONET. XML has five sections: 1. NavBars: Specifies the top navigation and left navigation of the home page. 2. ListTemplates: Lists (custom list, document library, Image Library, etc.) that can be created by the site) 3. DocumentTemplates: Specifies the document templates (Microsoft Office Word documents, Microsoft Office FrontPage webpages, Microsoft Office Excel workbooks, etc.) that can be created when a document library is created) 4. Deployments: Lists and modules generated by default when a site is created. 5. Modules: Specifies the default Web part library contained in the site. Note: After modifying ONET. XML, you must restart IIS to make the modification take effect. Instance: Creates a site template based on an existing template. Steps: 1. Open the C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ SiteTemplates directory 2. copy and paste an SPS folder and rename it GASSPS 3. Find the C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ 2052 \ XML directory. 4. Create a file named WEBTEMPGASSPS. XML in the directory and paste the following XML into the file. <? Xml version = "1.0" encoding = "UTF-8"?> <! -- _ Lcid = "2052" _ version = "12.0.4518" _ dal = "1" --> <! -- _ LocalBinding --> <Templates xmlns: ows = "Microsoft SharePoint"> <Template Name = "GASSPS" ID = "10001"> <Configuration ID = "0" Title = "Zhejiang Natural Gas template" Hidden = "FALSE" ImageUrl = "" Description = "this template is used to initialize the Zhejiang Natural Gas website. "> </Configuration> </Template> </Templates> 5. Restart IIS (iisreset) 6. Open the site creation page and add a "Custom" option in the "select template" section. below is the "Zhejiang Natural Gas template" We just added ". (2) THEMES directory Place various website themes. Instance: create a custom topic Steps: 1. First find the Theme folder Location C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ THEMES 2. Copy a Theme folder, such as CLASSIC, and change it to your desired name, such as GASTHEME. 3. In the folder, change CLASSIC. INF to the same name as your folder, such as GASTHEME. INF. 4. Open GASTHEME. INF and change the title to the same name as your folder and file name, for example, GASTHEME. 5. Find C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ LAYOUTS \ 2052 \ SPTHEMES. XML file, copy and paste a <Templates> element, and modify the content as follows: <Templates> <TemplateID> GASTHEME </TemplateID> <DisplayName> natural gas topic </DisplayName> <Description> the natural gas topic will be applied. </Description> <Thumbnail> images/thwheat.gif </Thumbnail> <Preview> images/thwheat.gif </Preview> </Templates> The above two images refer to the image of the Wheat topic. You can also change them to your own image. The image storage location is C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ IMAGES folder 6. Open "website Settings" and "website themes" to find the GASTHEME subject we just added. (3) LAYOUTS directory All the page functions of the website (the pages with _ layouts following the URL) are under this directory (except the Default. aspx in the template and the pages related to a certain type of List ). You can add your own function page: (4) ADMIN directory The page functions of the Management Center are under this directory. (5) CONTROLTEMPLATES directory Place various server controls. (6). IMAGES directory Place the main images used by the website, such as the website Logo. (7) FEATURES directory Put a variety of Feature. In MOSS 2007, the feature is far more powerful than imagined. It can be said that most of the enhancements to the functionality of an existing website will be achieved through Feature. Including master pages, content pages, and document libraries are all implemented through Feature. Instance 1: use Feature to customize the parent page. Steps: 1. Open the Feature directory C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ FEATURES. 2. Create a New GASMASTERPAGES folder. 3. In the GASMASTERPAGES folder, create a new Feature. xml file and paste the following content into the file. <! -- _ Lcid = "1033" _ version = "12.0.4518" _ dal = "1" --> <! -- _ LocalBinding --> <Feature Id = "cbdddc58-c0e1-4d64-99bc-071379a910f3" Title = "Gas Master" Description = "" Version = "12.0.0.0" Scope = "Site" Hidden = "False" DefaultResourceFile = "core" Xmlns = "http://schemas.microsoft.com/sharepoint/"> <ElementManifests> <ElementManifest Location = "ProvisionedFiles. xml"/> </ElementManifests> </Feature> In this XML file, the following metadata about Featrue is contained in the Featrue element. (For more information, see Feature. xml Files) ID: a guid used to uniquely identify the Feature. It can be generated through. Title: The name of Feature, which can be seen on the Site Featrues page on the website. Description: description of Description. Version: The Feature Version; Scope: The value can be Web or Site. It indicates whether the Feature is applied to the entire Site Collection or only for a separate subsite. Hidden: The value can be True or False. This setting specifies whether the Feature is displayed on the Site Feature page. DefaultResourceFile: name of the resource file. Feature depends on it to provide additional configuration information. The <ElementManifests> element in the Feature. xml file contains the location of another XML file. The <Elemnets> content contained in this file is implemented by Feature. The <ElementManifest> element indicates that you want to use a file named ProvisionedFiles. xml. The following is the content of the <Elements> element of the file. 4. In the GASMASTERPAGES folder, create a ProvisionedFiles. xml file and paste the following content into the file. <! -- _ Lcid = "1033" _ version = "12.0.4518" _ dal = "1" --> <! -- _ LocalBinding --> <Elements xmlns = "http://schemas.microsoft.com/sharepoint/"> <Module Name = "OSGMasterPages" Url = "_ catalogs/masterpage" Path = "MasterPages" RootWebOnly = "TRUE"> <File Url = "Gasmaster. master" Type = "GhostableInLibrary"> <Property Name = "ContentType" Value = ""/> <Property Name = "PublishingPreviewImage" Value = "~ SiteCollection/_ catalogs/masterpage/$ Resources: core, Culture;/Preview Images/Gas.png ,~ SiteCollection/_ catalogs/masterpage/$ Resources: core, Culture;/Preview Images/Gas.png "/> <Property Name = "MasterPageDescription" Value = ""/> </File> </Module> <Module Name = "PublishingLayoutsPreviewImages" Url = "_ catalogs/masterpage" IncludeFolders = "?? -?? "Path =" "RootWebOnly =" TRUE "> <File Url = "Gas.png" Name = "Preview Images/Gas.png" Type = "GhostableInLibrary"> </File> </Module> </Elements> 5. Renewal 6. Restart IIS (iisreset) 7. Run cmd.exe on the pointpointserver, Enter the command to switch to the directory: cd C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ BIN Run the following command to install Feature: stsadm-o installfeature-filename GASMASTERPAGES. Run the following command to activate Feature: stsadm-o activatefeature-filename GASMASTERPAGES \ feature. xml-url http: // portal: 8000 8. Open "master page" in "website Settings" and you will be able to see the newly added Gasmaster. master. Reference connection: Create a Feature: Add Custom Master Pages to your Site Collections Instance 2: Use Feature to define menu items in the site The first CustomAction created a custom Link under the "appearance" title on the "website Settings" page. the second CustomAction adds a custom menu item under the "website operations" menu on the page. the third CustomAction creates a custom menu item under the "new" drop-down menu of the document library. the fourth CustomAction creates a custom menu item under the "operations" drop-down menu of the document library. Steps: 1. Create a Feature. xml file Create a directory such as MyMenu under the Features directory and create a Feature. xml file. The file content is as follows: <? Xml version = "1.0" encoding = "UTF-8"?> <! -- _ Lcid = "1033" _ version = "12.0.4017" _ dal = "1" --> <! -- _ LocalBinding --> <Feature Id = "6098EC11-8128-409A-8D2C-414E93F67DD4" Title = "$ Resources: GasMenu, MenuTitle ;" Description = "$ Resources: GasMenu, MenuDescription ;" Version = "12.0.0.0" Scope = "Web" Hidden = "FALSE" DefaultResourceFile = "customDocumentLibrary" Xmlns = "http://schemas.microsoft.com/sharepoint/"> <ElementManifests> <ElementManifest Location = "LightUp. xml"/> </ElementManifests> </Feature> 2. Create the GasMenu. zh-CN.resx file in the C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ Resources folder and enter the following content <? Xml version = "1.0" encoding = "UTF-8"?> <! -- _ Lcid = "2052" _ version = "12.0.4518.1016" _ dal = "1" --> <! -- _ LocalBinding --> <Root> <Data Name = "MenuTitle"> <Value> natural gas menu item </Value> </Data> <Data Name = "MenuDescription"> <Value> four menu items are added, create a custom Link under the "appearance" title on the "website Settings" Page, add a user-defined menu item under the "website operations" menu on the page A custom menu item is created under the "new" drop-down menu of the document library and a custom menu item is created under the "operations" drop-down menu of the document library. </Value> </Data> </Root> 3. Create the description file LightUp. xml of Feature. The document content is as follows: <? Xml version = "1.0" encoding = "UTF-8"?> <Elements xmlns = "http://schemas.microsoft.com/sharepoint/"> <! -- Create command link site setting page --> <CustomAction Id = "SiteSettings" GroupId = "Customization" Location = "Microsoft. SharePoint. SiteSettings" Sequence = "106" Title = "Custom Site Setting Command"> <UrlAction Url = ""/> </CustomAction> <! -- Add command to site action dropdow --> <CustomAction Id = "SiteActionsToolbar" GroupId = "SiteActions" Location = "Microsoft. SharePoint. StandardMenu" Sequence = "1000" Title = "Custom Action" Description = "custom site action" ImageUrl = "/_ layouts/images/ACG16.GIF"> <UrlAction Url = ""/> </CustomAction> <! -- Document Library Toolbar New Menu DropDown --> <CustomAction Id = "DocLibNewToolbar" RegistrationType = "List" RegistrationId = "101" GroupId = "NewMenu" Rights = "ManagePermissions" Location = "Microsoft. SharePoint. StandardMenu" Sequence = "1000" Title = "Custom New Command" Description = "custom new command" ImageUrl = "/_ layouts/images/ACG16.GIF"> <UrlAction Url = ""/> </CustomAction> <! -- Document library Toolbar Actions Menu Dropdown --> <CustomAction Id = "DocLibActionsToolbar" RegistrationType = "List" RegistrationId = "101" GroupId = "ActionsMenu" Rights = "ManagePermissions" Location = "Microsoft. SharePoint. StandardMenu" Sequence = "1000" Title = "Command on Document Library" Description = "command on document library" ImageUrl = "/_ layouts/images/ACG16.GIF"> <UrlAction Url = ""/> </CustomAction> </Elements> 4. Restart IIS (iisreset) 5. Run cmd.exe on the pointpointserver, Enter the command to switch to the directory: cd C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ BIN Run the following command to install Feature: stsadm-o installfeature-filename MyMenu. Run the following command to activate Feature: stsadm-o activatefeature-filename MyMenu \ feature. xml-url http: // portal: 8000 Question: In Feature. xml, although the encoding method is changed to encoding = "GB2312", Chinese characters cannot be identified. However, in the LightUp. xml file The method is encoding = "UTF-8", but the use of Chinese characters can be identified, it is very strange. Instance 3: Use Feature to create a user control. See the DelegateControl of KaneBoy: A "user control package" built in SharePoint Server 2007" Example 4: Use Feature to create a custom document library. See how Song zhenqian created a custom Document Library Feature in MOSS2007. Microsoft Office SharePoint Server 2007 (MOSS2007) master page All Pages in MOSS2007 are composed of Master Pages and Content Pages. The Master Page in MOSS 2007 is the same as the Master Page used in ASP.net. they define the basic layout of the website page. the concept of Page layout is similar to the Content Page in ASP.net 2.0. It points to a Master Page and implements Content Placeholders. the following is an introduction to ASP. NET 2.0 master page structure is a good entry. Master Your Site Design with Visual Inheritance and Page Templates The master page allows multi-level nesting. By default, all sites in sharepoint use the default. master page. This file is located in C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 \ TEMPLATE \ GLOBAL directory. The default. master page is a global master page. Any modification to this page will affect all sharepoint sites and the Management Center site. The sharepoint master page defines many placeholders (content placeholder ). These placeholders define different areas of the page. developers can customize the most Content displayed to the user. Most of the placeholders defined in SharePoint do not allow users to override their content. Most sharepoint pages include the placeholder PlaceHolderMain, which controls the main content of the page. In typical cases, The placeholder will include multiple web Part areas to drag the webpart. But for developers, it can be used to place anything they want. All placeholders defined in the sharepoint master page are listed below: (for detailed locations, refer to default. master) 1. <asp: ContentPlaceHolder ID = "PlaceHolderGlobalNavigationSiteMap" runat = "server"/> Place super connections connected to top-level sites 2. <asp: ContentPlaceHolder ID = "PlaceHolderGlobalNavigation" runat = "server"/> Place the content in the top line. 3. <asp: ContentPlaceHolder ID = "PlaceHolderSiteName" runat = "server"/> Placement site name 4. <asp: ContentPlaceHolder ID = "PlaceHolderSearchArea" runat = "server"/> Place search box 5. <asp: ContentPlaceHolder ID = "PlaceHolderHorizontalNav" runat = "server"/> Placement horizontal navigation bar 6. <asp: ContentPlaceHolder ID = "PlaceHolderTopNavBar" runat = "server"/> Place a row in the horizontal navigation bar. 7. <asp: ContentPlaceHolder ID = "WSSDesignConsole" runat = "server"/> Page editing control, used when the Page enters the editing Page mode (after clicking Site Actions and Edit Page) 8. <asp: ContentPlaceHolder ID = "SPNavigation" runat = "server"/> Windows SharePoint Services is empty by default. It is used for additional page editing controls. 9. <asp: ContentPlaceHolder ID = "PlaceHolderPageImage" runat = "server"/> Picture on the left 10. <asp: ContentPlaceHolder ID = "PlaceHolderTitleLeftBorder" runat = "server"/> Border on the left of the Title Area 11. <asp: ContentPlaceHolder ID = "PlaceHolderTitleBreadcrumb" runat = "server"/> TitleBreadcrumb page navigation area 12. <asp: ContentPlaceHolder ID = "PlaceHolderPageTitleInTitleArea" runat = "server"/> Title under Breadcrumb 13. <asp: ContentPlaceHolder ID = "PlaceHolderMiniConsole" runat = "server"/> A place where Page-level commands are placed, such as Edit Page, History, and Incoming Links on the WIKI site. 14. <asp: ContentPlaceHolder ID = "PlaceHolderTitleRightMargin" runat = "server"/> White space on the right of the Title Area 15. <asp: ContentPlaceHolder ID = "PlaceHolderTitleAreaSeparator" runat = "server"/> TitleAreaSeparator Area 16. <asp: ContentPlaceHolder ID = "PlaceHolderLeftNavBarDataSource" runat = "server"/> Data Source in the left navigation area 17. <asp: ContentPlaceHolder ID = "PlaceHolderCalendarNavigator" runat = "server"/> A date selection box is displayed for a calendar in the page. 18. <asp: ContentPlaceHolder ID = "PlaceHolderLeftNavBarTop" runat = "server"/> Navigation area on the left navigation area 19. <asp: ContentPlaceHolder ID = "PlaceHolderLeftNavBar" runat = "server"/> Left Navigation 20. <asp: ContentPlaceHolder ID = "PlaceHolderLeftActions" runat = "server"/> Action Area under the left navigation area 21. <asp: ContentPlaceHolder ID = "PlaceHolderNavSpacer" runat = "server"/> Width of the left navigation area 22. <asp: ContentPlaceHolder ID = "PlaceHolderLeftNavBarBorder" runat = "server"/> Border element in the left navigation area 23. <asp: ContentPlaceHolder ID = "PlaceHolderBodyLeftBorder" runat = "server"/> Border element of the page body 24. <asp: ContentPlaceHolder id = "PlaceHolderPageDescription" runat = "server"/> Page Description Area 25. <asp: ContentPlaceHolder id = "PlaceHolderMain" runat = "server"/> Page subject 26. <asp: ContentPlaceHolder ID = "PlaceHolderBodyRightMargin" runat = "server"/> Blank on the right of the page body 27. <asp: ContentPlaceHolder ID = "PlaceHolderFormDigest" runat = "server"/> This is a required "form digest" security component on the page. 28. <asp: ContentPlaceHolder ID = "PlaceHolderUtilityContent" runat = "server"/> A special piece of content required at the bottom of the page 29. <asp: ContentPlaceHolder ID = "PlaceHolderBodyAreaClass" runat = "server"/> Style appended to the body at the top of the page 30. <asp: ContentPlaceHolder ID = "PlaceHolderTitleAreaClass" runat = "server"/> Style appended to TitleArea 31. <asp: ContentPlaceHolder id = "PlaceHolderAdditionalPageHead" runat = "server"/> Add all content that can be placed in the Microsoft Office SharePoint Server 2007 CSS Application Application sequence of css on the SharePoint page 1. CORE. CSS 2, Http://www.heathersolomon.com/blog/archive/2006/10/27/sp07cssoptions.aspx You can use the SharePoint Designer (SPD) to open the entire site and modify the page. You can also use other text editors to directly modify physical files. Change. When we open a Sharepoint page, Sharepoint will first determine whether the page (master page and content page) has been damaged (modified by SPD or other tools) The modified part will be saved in the Sharepoint database). If it is found in the database, the page will be displayed. If not, the Sharepoint service In the C: \ Program Files \ Common Files \ Microsoft Shared \ web server extensions \ 12 directory, find the corresponding physical file to display the page, Introduction to default. master and defaultlayout. aspx Appendix: Other related content connections. Create a simplified master page About the Content Types of MOSS 2007 About MOSS 2007 and WSS 3.0 Master Page How to add a Document Library to the site definition in MOSS 2007 MOSS project development steps Website definition and template |