Simple plugin written during one evening.
As I was making sites for my client I restricted their access to 'Themes' tab by wonderful Multi user plugin. This ensured that themes template files won't be corrupted by ordinary users. I used 'components' in 'Themes' tab to place there small phrases and slogans from page titles or sidebars (and they've been translated by i18n plugin, thanks to Mvlcek). As this slogans contained some user info (such as emails, telephone numbers etc) I decided to write a slogan-plugin, that would be editable by users in 'Pages' tab.
Usage
Usage doesn't differs from 'component' usage.
- without any spaces between (% and slogan name, for usage in page content
- for usage in theme template files
The result is the same as with components - the phrase for current language will be returned or for default language (if the first one is empty).
Requirements
As I was making sites for my client I restricted their access to 'Themes' tab by wonderful Multi user plugin. This ensured that themes template files won't be corrupted by ordinary users. I used 'components' in 'Themes' tab to place there small phrases and slogans from page titles or sidebars (and they've been translated by i18n plugin, thanks to Mvlcek). As this slogans contained some user info (such as emails, telephone numbers etc) I decided to write a slogan-plugin, that would be editable by users in 'Pages' tab.
Usage
Usage doesn't differs from 'component' usage.
Code:
(%slogan-name-goes-here%)
Code:
<?php get_slogan('slogan-name');?>
The result is the same as with components - the phrase for current language will be returned or for default language (if the first one is empty).
Requirements
- i18n plugin by Mvlcek
- GS 3.1, BUT it may work on GS 3.0, I didn't test it