Linux 软件免费装

Conditional Statements

开发者 aliakro
更新时间 2019年7月10日 15:44
捐献地址: 去捐款
PHP版本: 5.5 及以上
WordPress版本: 5.2.2
版权: GPLv2 or later
版权网址: 版权信息

标签

conditional in if statement statements else elseif and logged

下载

1.0

详情介绍:

Conditional Statements allows you to add logic into your pages. The plugin supports various conditions allowing you to apply IF statements. For example: "IF the user is logged in display X ELSE display Y" would look like: [cs-if conditions="is-logged-in"] Welcome Back! [gallery] [else] You must be logged in to view the gallery. [/cs-if] You can also nest conditions e.g. [cs-if conditions="is-logged-in"] The user is logged in. [cs-if-1 conditions="firstname"] The user has entered a first name! [else-1] The user must enter a first name! [/cs-if-1] [cs-if-1 conditions="lastname"] The user has entered a last name! [else-1] The user must enter a last name! [/cs-if-1] [/cs-if] Simply add a hyphen and the depth (up to a maximum of 5) e.g. [cs-if-1], [cs-if-2], [cs-if-3] and so on. Examples Please look at these examples on how to use the Conditional Statements shortcode: Examples of how to use Conditional Statements Features [cs-if conditions="post-type" operator="equals" compare-value="article"] Post Type is Article [else] [cs-if-1 conditions="post-type" operator="equals" compare-value="post"] Post Type is Post [else-1] Post type is not Article or Post. [/cs-if-1] [/cs-if] Supported Conditions To suggest new conditions, email me at: email@yeken.uk Coming Soon

安装:

  1. Login into Wordpress Admin Panel
  2. Navigate to Plugins > Add New
  3. Search for "Conditional Statements"
  4. Click Install now and activate plugin

常见问题:

What is the best way to suggest a new condition?

Drop me an email: email@yeken.uk

更新日志:

1.0