PHPackages                             hounddd/wn-themeswitcher-plugin - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. hounddd/wn-themeswitcher-plugin

ActiveWinter-plugin[Utility &amp; Helpers](/categories/utility)

hounddd/wn-themeswitcher-plugin
===============================

Theme switcher plugin for Winter CMS

161PHP

Since Oct 3Pushed 2y ago1 watchersCompare

[ Source](https://github.com/Hounddd/wn-themeswitcher-plugin)[ Packagist](https://packagist.org/packages/hounddd/wn-themeswitcher-plugin)[ RSS](/packages/hounddd-wn-themeswitcher-plugin/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependenciesVersions (1)Used By (0)

Theme Switcher
==============

[](#theme-switcher)

[![ThemeSwitcher Plugin](https://github.com/hounddd/wn-themeswitcher-plugin/raw/main/.github/ThemeSwitcher-plugin.png?raw=true)](https://github.com/hounddd/wn-themeswitcher-plugin/blob/main/.github/ThemeSwitcher-plugin.png?raw=true)

Demo any theme installed in Winter CMS by visiting a defined URL.

Installation
------------

[](#installation)

*Let assume you're in the root of your wintercms installation*

### Using composer

[](#using-composer)

Just run this command

```
composer require hounddd/wn-themswitcher-plugin
```

### Clone

[](#clone)

Clone this repo into your winter plugins folder.

```
cd plugins
mkdir hounddd && cd hounddd
git clone https://github.com/Hounddd/wn-themeswitcher-plugin themeswitcher
```

> **Note**: In both cases, run `php artisan winter:up` command to run plugin's migrations or logout and login backend.

Usage
-----

[](#usage)

Visit the followinf urls

- **To demo** a theme : `/theme-switcher/use/theme-name`, where `theme-name` is one of your website themes.
- **To restore** default theme : `/theme-switcher/restore`

Config
------

[](#config)

By default, switching theme is limited to authenticated administrators.
To authorise all visitors to switch to another theme, create a config file `/config/hounddd/themeswitcher.php` and set `onlyBackendUsers` to false:

```
