plugin-icon

wpSpoiler

作者:Felix Triller·
A plugin designed to protect the reader against spoilers.
评级
4/5
版本
1.2
活跃安装
400
最后更新
May 31, 2008

wpSpoiler is a plugin for WordPress, designed to protect the reader against spoilers, for example in book or filmreviews. The spoiler text is hidden by default and shows up if wished.

To mark a text as spoiler, enclose the passage with [spoiler] and [/spoiler].

Features

  • Very fast, less code
  • Customizeable with CSS

A german version of this page can be found here. Eine deutsche Version dieser Seite ist hier zu finden.

Usage

To mark a text as spoiler, enclose the passage with [spoiler] and [/spoiler]. Example: Spoiler: [spoiler]Bruce Willis is a ghost![/spoiler]

The result is shown in the screenshot section.

Customize

The language of the link text has to be changed in the pluginfile itself: wpSpoiler.php.

CSS can be used to style the spoiler box and the links. The spoiler-div is identified by the classname spoiler_div. The link’s class is spoiler_link_show or spoiler_link_hide, depending on the current state.

An example stylesheet code snippet:

/* wpSpoiler */ a.spoiler_link_show, a.spoiler_link_hide { background-repeat: no-repeat; background-position: left center; padding-left: 18px; } a.spoiler_link_show { background-image: url(images/add.png); } a.spoiler_link_hide { background-image: url(images/delete.png); } div.spoiler_div { background-color: #ddd; margin-top: -10px; padding: 2px; }
免费使用Business套餐
通过安装,您同意 WordPress.com 服务条款第三方插件条款
目前已测试版本
WordPress 2.5.1
这个插件是可用的下载,适用于您的站点。