%META:TOPICINFO{author="TWikiContributor" date="1130019100" format="1.1" version="4"}%
---+!! %TWIKIWEB%.PatternSkin Customization
*Questions and answers on configuring page elements.* For styling your TWiki, see PatternSkinCssCookbook.
%TOC%
---++ Logo questions
---+++ How can I change the web logo?
By default the logo at the top left of each web points to the image with name =logo.gif= that is attached to each web's WebPreferences.
The default variables that cause this behavior are defined in [[%WIKIPREFSTOPIC%]].
Redefine your custom variables in [[%LOCALSITEPREFS%]] (to keep %WIKIPREFSTOPIC% intact):
* SetThere are several ways to change the logo in a web: * Create a new image named =logo.gif= and attach it to the web's WebPreferences topic. %TWIKIWEB%.PatternSkin's stylesheet assumes the logo is 40px high. More about that later. * You can also upload the image with FTP to =/pub/YourWeb/WebPreferences/=. or: * Attach whatever image and attach it to the web's WebPreferences topic. Then add to the WebPreferences (under _Custom web preferences_):WEBLOGONAME = logo.gif * Set WEBLOGOIMG = % PUBURLPATH%/% BASEWEB%/% WEBPREFSTOPIC%/% WEBLOGONAME% * Set WEBLOGOURL = % SCRIPTURLPATH{"view"}%/% BASEWEB%/% HOMETOPIC% * Set WEBLOGOALT = Home
* Set---+++ How do I set a site-wide logo? There is a bunch of site-wide logo variables in [[%LOCALSITEPREFS%]]: =WIKILOGOIMG=, =WIKILOGOURL= and =WIKILOGOALT=. To change only the web logo image to site-wide, in [[%LOCALSITEPREFS%]] set:WEBLOGONAME = your-logo-name.gif-or-png
* Set---+++ My logo does not fit the top bar The top bar is 64 pixels high by default. If you have a bigger logo you might want to change the height of the top bar in [[%PUBURLPATH%/%TWIKIWEB%/PatternSkin/layout.css][layout.css]]:WEBLOGOIMG = % WIKILOGOIMG%
* Set WEBHEADERART = %You can also set =WEBHEADERART= per web, by defining the variable in the Web's !WebPreferences. ---+++ I want to have the web color in the top bar Redefine =WEBHEADERBGCOLOR= in [[%LOCALSITEPREFS%]] (to keep %WIKIPREFSTOPIC% intact):PUBURLPATH%/% TWIKIWEB%/PatternSkin/TWiki_header.gif * Set WEBHEADERBGCOLOR = somehexcolor
* Set WEBHEADERBGCOLOR = %---+++ I want other items in the top bar In %TWIKIWEB%.WebTopBar shows a logo, but that does not mean you cannot put other things in there. You can put a table, or divs or images.WEBBGCOLOR%
<div id="patternTopBar">
<table class="patternTopBarContents" border="0" cellpadding="0" cellspacing="0">
<tr>
<td>
<span class="patternTopBarLogo twikiLeft">
<a href="%WEBLOGOURL%"><img src="%WEBLOGOIMG%" border="0" alt="%WEBLOGOALT%"/></a>
</span>
</td>
</tr>
</table>
</div>