跳到内容

PCF Christmas Countdown

v2.2

PC Futures · 2015年9月7日 上架

A simple plugin that creates an easy to use Christmas countdown for your WordPress sites.

正在使用
10+
评分
3.0 / 5
累计下载
2,150
最近更新
2015年10月6日
1 条评价需要 WordPress 4.0+已测试到 4.3.34

贡献者

截图

'Days and Weeks' Countdown
'Days and Weeks' Countdown
'Days' Countdown
'Days' Countdown
'Weeks' Countdown
'Weeks' Countdown
'Sleeps' Countdown
'Sleeps' Countdown

Basic Instructions

This plugin works out-of-the-box, so once the plugin is installed, you can place a shortcode wherever you want.

Use the shortcode [pcf_xmas_countdown] to output the countdown.

The countdown will output in days by default (e.g ‘105 days until Christmas!’).

Changing output type

The shortcode can be given a ‘type’ attribute, like so:

[pcf_xmas_countdown type="days|weeks|sleeps"]

This enables you to change the output type.

There are 3 types to choose from:

  • Days
  • Weeks
  • Sleeps

If you do not specify the type attribute, or specify an invalid type, it will default to ‘days’.

Example:

[pcf_xmas_countdown type="weeks"]

will output as

It's `x` weeks and `y` days until Christmas!

Styling the output

Styling the output is an advanced setting, that involves writing custom CSS.

The shortcode can be given an ‘id’ attribute, which can then be used to style the output using CSS.

For example,

[pcf_xmas_countdown id="my-id"]

would output in HTML as

<p id="my-id">...</p>

You can then add custom CSS through Appearance > Editor. If your theme supports custom CSS, you may be able to add your styles in Theme Options. If there is a custom css file in Editor, it is advised to use that for custom styles.

Here is an example of some custom styles:

#my-id{
    color: red;
    font-size: 16px;
    text-decoration: underline;
}

This will set the output to be red, underlined, and to have a font size of 16px.

Plums

按场景查找 WordPress 插件。安装量、评分和兼容版本来自官方目录。

导航

说明

WordPress 是 WordPress Foundation 的商标。本站与 WordPress Foundation、Automattic 没有隶属关系。这里不托管插件文件,下载和安装以 WordPress.org 上的页面为准。

© 2026 Plums