How to: Customize Themes
You can add new themes or customize existing ones for application to Web sites in Microsoft Windows SharePoint Services 3.0. This programming task shows how to customize an existing theme.
To customize an existing theme
-
Copy one of the theme folders in Local_Drive
:\Program Files\Common Files\Microsoft Shared\web server extensions\12\TEMPLATE\THEMESand give the folder a unique name. In this example, the name is MyTheme. This folder contains cascading style sheets (CSS) files, image files, and other files that define the styles, formatting, and color for the various user interface (UI) elements that are used in the theme. -
Find the .inf file in the copied folder, and rename it with the name given to the folder.
-
Open the .inf file and assign the same name to the title in the [info] and [titles] sections of the file.
-
Customize the styles defined in the .css files of the copied folder as needed.
For information about the classes used in Windows SharePoint Services, see Cascading Style Sheets Class Definitions for Windows SharePoint Services.
The following example from THEME.CSS changes the color that is used for sections of the navigation area.
.ms-navframe{ background:#009999; } .ms-navline{ border-bottom:1px solid #8D4D03; } .ms-nav .ms-navwatermark{ color:#008999; } -
Modify the image files in the copied folder by using the business graphics software of your choice.
-
Add a file for thumbnail and preview images for your custom theme to the Local_Drive:
\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\IMAGESdirectory. In this example, the file is called myPreview.gif. -
Add a theme template definition to SPTHEMES.XML, which is the file that determines which themes are available as options on the Site Theme page. This XML file is located in the Local_Drive
:\Program Files\Common Files\Microsoft Shared\Web Server Extensions\12\TEMPLATE\LAYOUTS\1033 directory.The following example specifies a template for the custom theme.
-
Reset Internet Information Services (IIS) by typing
iisresetat the command prompt so that your custom theme appears in the list of options on the Site Theme page and can be applied to SharePoint sites.
Robust Programming
Warning Changes that you make to SPTHEMES.XML might be overwritten when you install updates or service packs for Windows SharePoint Services, or when you upgrade an installation to the next version.
to know more making your own sharepoint theme with ur design, jus ve a look at this, it ll be very useful
http://santhoz-teaches.blogspot.com/2009/02/sharepoint-themes-unveiled.html
And to download 50+ quality sharepoint themes, go on to www.buytemplates.net
Regards,
Santhosh
- 5/1/2007
- ccatron
- 6/28/2009
- Santhoz_31
- 2/19/2009
- Marc Miles
Use the "View CSS Information" option in that same tool to determine what CSS element you are modifying. If you need a list of the CSS classes with pictures of what element is affected by a class, try Heather Solomon's blog here:
http://www.heathersolomon.com/content/sp07cssreference.htm
- 4/3/2008
- Aegis72
- 12/20/2007
- perrone-brazil
may be the iisreset ist the right way, but thats not practical at all. CSS-Theming goes step by step, so you change a little bit, test it, correct it and so on.
So, in real life, forget the iisreset. We do it by saving pages as html on the hard disk, do the changes there, and adapt the css files finally.
- 10/25/2007
- Daniel Greitens
- 6/19/2007
- Linda Chapman - Microsoft Consultant
- 6/19/2007
- Linda Chapman - Microsoft Consultant
An iisreset is not require for styling and testing!
When you change the theme for a site, you can open the site in SharePoint Designer. Then you see in the folder list: _themes\<theme name> the files which SharePoint has copied to the site. There you see the style sheet theme.css, but editing this file shows no results. But there is also an other css file, named: <part of theme name><nr>-<nr>.css This is the file you can edit. When you change some colors, you will see this after a browser refresh! Changing some images will return also the new images after a browser refresh.
When your site theme is completed you need a tool such as ExamDiff, for comparing the original CSS file and your CSS file. Your CSS file has a lot of more style rules then the original style sheet file. You can copy your CSS content and replace it into the original CSS on the file server. The code which will not be able in the original CSS file is the content of the file: mossExtension.css
When you have done this, an IISReset is required for apply the style for other users.
- 5/31/2007
- L. Baudewijns