Actions

Foreground features

One this page you see the default values set for the Foreground skin and the example of the array to change the defaults. Add the following array after invoking the skin in your "LocalSettings.php" file with the following line:

wfLoadSkin( 'foreground' );

Default Features Array

This is the defaults of the features available using the Pivot Skin. If you are happy with the defaults, you do not need to add them to your "LocalSettings.php" file. If you want to change them to suit your wiki's needs, then you will have to add the feature choices you wish to change.

$wgForegroundFeatures = [      
 	'showActionsForAnon' => true,
 	'NavWrapperType' => 'divonly',
 	'showHelpUnderTools' => true,
 	'showRecentChangesUnderTools' => true,
 	'enableTabs' => false,
 	'wikiName' => $wgSitename,
 	'navbarIcon' => false,
 	'IeEdgeCode' => 1,
 	'showFooterIcons' => 0,
 	'addThisFollowPUBID' => ''
];

Explanations of Feature Choices

Use following configuration parameter options with $wgForegroundFeatures in your "LocalSettings.php" file to change the behavior:

  • 'showActionsForAnon' => true
    displays page "Actions" button for non-logged-in visitors, "false" will hide them.
  • 'NavWrapperType' => 'divonly'
    only a div with id navwrapper will be created. '0' sets that no div will be created (old behavior), other values will be used as class.
  • 'showHelpUnderTools' => true
    displays a link to "Help" in the "Tools" section of the sidebar, "false" will prevent this.
  • 'showRecentChangesUnderTool's => true
    displays a Link to "Recent changes" in the "Tools" section of the sidebar, "false" will prevent this.
  • 'enableTabs' => false
    will allow to use tabs within pages.
  • 'wikiName' => $wgSitename
    defaults to the value of "$wgSitename", use a 'string' to display a shorter wiki name. This does not change the real name of the wiki.
  • 'navbarIcon' => false
    default false will prevent an icon to be shown in mobile view, "true" is used to set the global logopath image of the wiki.
  • 'IeEdgeCode' => 1
    will produce a meta tag with "X-UA-Compatible" content="IE=edge", "2" will sent a header and with "0" nothing will be done
  • 'showFooterIcons' => false
    will show text in place of footer icons, "true" will output the icons as they are set globally in LocalSettings.php.
  • addThisPUBID =>
  • empty string will not fire the AddThis script, 'ra-##-#######' publisher ID will allow the run the AddThis script in async on content pages only.
  • useAddThisShare =>
    default empty string, do not use AddThis share, your_addthis_specific_div_class_string will insert the share toolbox div directly under page title, but before the tagline with your custom div class.
  • useAddThisFollow =>
    default empty string, do not use AddThis follow, your_addthis_specific_div_class_string will insert the follow toolbox div in the footer area before icon or text output with your custom div class.

Changing the Defaults

There is no need to add all the features of the array if you only want to change the default of a few features. For example, you wish to use ForegroundTabs. Your array would look like this:

$wgForegroundFeatures = [
	'enableTabs' => true
];

That's all you need to do, just make sure your last feature does not contain a comma ( , ) at the end of the last line of the array.

Settings Used on This Wiki

This is how the Foreground skin is configured on this very wiki:

### Skin settings
## Enabled skins
# Foreground
wfLoadSkin( 'foreground' );
$wgForegroundFeatures = [      
 	'showActionsForAnon' => true,
 	'NavWrapperType' => 'divonly',
 	'showHelpUnderTools' => true,
 	'showRecentChangesUnderTools' => true,
 	'enableTabs' => true,
 	'wikiName' => $wgSitename,
 	'navbarIcon' => false,
 	'IeEdgeCode' => 1,
 	'showFooterIcons' => 0,
 	'addThisFollowPUBID' => ''
];

## Default skin
$wgDefaultSkin = 'foreground';

## Skin adaption
$wgAllowSiteCSSOnRestrictedPages = true;
$wgAllowUserCss = true;

## Skin preferences
$wgHiddenPrefs[] = 'skin';


Note that only the Foreground skin is installed on this wiki so alternative skins do not have to be set to be skipped with. e.g.

# Skin preferences continued
$wgSkipSkins = [
 	'cologneblue',
	'modern',
	'monobook',
	'vector'
];
Cookies help us deliver our services. By using our services, you agree to our use of cookies.