Title: Conditional Display for Mobile &#8211; Mobile Detect Plugin
Author: WonderPlugin
Published: <strong>2016 年 6 月 15 日</strong>
Last modified: 2023 年 12 月 5 日

---

搜索插件

![](https://ps.w.org/wonderplugin-conditional-display/assets/banner-772x250.jpg?
rev=1436835)

**该插件尚未通过WordPress的最新3个主要版本进行测试**。 当与较新版本的WordPress一起
使用时，可能不再受到维护或支持，并且可能会存在兼容性问题。

![](https://ps.w.org/wonderplugin-conditional-display/assets/icon-128x128.png?rev
=1436835)

# Conditional Display for Mobile – Mobile Detect Plugin

 作者：[WonderPlugin](https://profiles.wordpress.org/wonderplugin/)

[下载](https://downloads.wordpress.org/plugin/wonderplugin-conditional-display.zip)

 * [详情](https://cn.wordpress.org/plugins/wonderplugin-conditional-display/#description)
 * [评价](https://cn.wordpress.org/plugins/wonderplugin-conditional-display/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/wonderplugin-conditional-display/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/wonderplugin-conditional-display/#developers)

 [支持](https://wordpress.org/support/plugin/wonderplugin-conditional-display/)

## 描述

**WordPress Mobile Detect Plugin**

Conditional Display for Mobile is a mobile detect plugin that can be used to control
what content is displayed depending on the visitor’s device or web browser. For 
example, you might want to display some content only on iPhone and iPad, or you 
want to hide the content on mobile and tablet devices. The plugin also supports 
add start time and end time to shedule the content so it will only be displayed 
in the specified date and time.

**Features**

 * Include or exclude devices
 * Detect iPhone, iPad, iPod, Android, Mobile, Windows, Linux and Mac
 * Include or exclude web browsers
 * Detect Mozilla Firefox, Google Chrome, Safari, Opera, Internet Explorer 6/7/8/
   9/10/11 and Microsoft Edge
 * Add start time and end time to schedule the content so it will only be displayed
   in the specified date and time
 * Support shortcode in the content
 * Use the conditional display shortcode in text widget
 * PHP functions to detect mobile and browser

**How to Use**

Please view the online tutorial: [https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#tutorial](https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#tutorial)

## 安装

**Install the plugin in WordPress backend**

 1. In WordPress backend, go to menu Plugins -> Add New
 2. Search Conditional Display for Mobile by WonderPlugin
 3. Install the plugin

**Install the plugin with downloaded plugin zip file**

 1. In WordPress backend, go to menu Plugins -> Add New
 2. Click the link Upload Plugin
 3. Select the plugin zip file, then click Install Now

**Uninstall the plugin**

 1. In WordPress backend, go to menu Plugins -> Installed Plugins
 2. Deactivate the plugin
 3. After the plugin is deactivated, Delete the plugin

## 常见问题

### What shortcode is supported and how to use the plugin?

Please view the online tutorial: [https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#tutorial](https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#tutorial)

### Is the plugin compatible with cache plugins?

Caching means WordPress will serve static cached content.

Usually cache plugins have an option to enable different caches for mobile/tablets.
You can enable the option then the device detection will work.

If the cache plugin doesn’t have such an option, it means it will serve the same
static cached content regardless of the current device and web browser, then the
detection will not work.

### Does the plugin support any PHP API?

Yes. Please view the online tutorial: [https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#api](https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/#api)

## 评价

![](https://secure.gravatar.com/avatar/f35f93ae052b2f5b87df05f5ec7de4d0d05c292007f9d8b57e4e2b45f0534bb4?
s=60&d=retro&r=g)

### 󠀁[Seems to work well](https://wordpress.org/support/topic/seems-to-work-well-35/)󠁿

 [Webprom Design](https://profiles.wordpress.org/webprom/) 2020 年 8 月 24 日

Hope the author will continue updating. I also fear we’ll have issues with cache…

![](https://secure.gravatar.com/avatar/b7921ceda76e5cb56d44adbba820a35ed8051dc58e1c9cf768d27b562bce8678?
s=60&d=retro&r=g)

### 󠀁[This is a best plugin.](https://wordpress.org/support/topic/this-is-a-best-plugin/)󠁿

 [Numan Hussain](https://profiles.wordpress.org/ahnuman13/) 2019 年 12 月 28 日

I have fixed an issue with this plugin. My wants to add apps icon for a separate
device and the plugin done by a few minutes. I appreciate it and best of luck for
the developer of this plugin.

![](https://secure.gravatar.com/avatar/061c848e974da3aa43a7d1ebb0e45403270959137e05f77fe46dea1c537927bb?
s=60&d=retro&r=g)

### 󠀁[Great, really useful!](https://wordpress.org/support/topic/great-really-useful-2/)󠁿

 [vshura](https://profiles.wordpress.org/vshura/) 2019 年 8 月 7 日

After trying to figure out how to conditionally display stuff online for ages, this
has been a life saver. Took me a little while to figure out how it works, but then
it was great.

![](https://secure.gravatar.com/avatar/bae84d8ef0968d7b2b94ddd3246e95387f435e379bbc83c74d249a86a16a4974?
s=60&d=retro&r=g)

### 󠀁[PERFECT! Just what we needed.](https://wordpress.org/support/topic/perfect-just-what-we-needed-2/)󠁿

 [AldebaranJill](https://profiles.wordpress.org/aldebaranjill/) 2017 年 7 月 27 
日

This is exactly what we were looking for, a way to display a message in PHP, for
mobile and tablet users. It’s working perfectly. Thanks to authors!

![](https://secure.gravatar.com/avatar/588995ea68eeee148e62eff8b287b33bbe37d70fc01e650d4f0f360e7aa6b70b?
s=60&d=retro&r=g)

### 󠀁[THANK YOU!](https://wordpress.org/support/topic/thank-you-1297/)󠁿

 [greglfb](https://profiles.wordpress.org/greglfb/) 2017 年 3 月 22 日

Glad I found this plugin when I did. I was thinking “This concept is too good to
be true” but when I tested it on my mobile it worked exactly as described. VERY 
PLEASED.

![](https://secure.gravatar.com/avatar/df9f6998cbd383edc4b8b9ef26741df3a9a1f63e21f1be5b5751d1a0b9f069a3?
s=60&d=retro&r=g)

### 󠀁[Great plugin](https://wordpress.org/support/topic/great-plugin-11361/)󠁿

 [newbee_sue](https://profiles.wordpress.org/newbee_sue/) 2016 年 12 月 11 日

So far so good. The code does exactly what I need thanks!

 [ 阅读所有7条评价 ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/)

## 贡献者及开发者

「Conditional Display for Mobile – Mobile Detect Plugin」是开源软件。 以下人员对
此插件做出了贡献。

贡献者

 *   [ WonderPlugin ](https://profiles.wordpress.org/wonderplugin/)

[帮助将「Conditional Display for Mobile – Mobile Detect Plugin」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/wonderplugin-conditional-display)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/wonderplugin-conditional-display/)，
查看[SVN仓库](https://plugins.svn.wordpress.org/wonderplugin-conditional-display/)，
或通过[RSS](https://plugins.trac.wordpress.org/log/wonderplugin-conditional-display/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/wonderplugin-conditional-display/)。

## 更新日志

#### 1.2

 * Fix the bug of detecting Opera, Firefox and new Edge

#### 1.1

 * Add start time and end time to shedule the content so it will only be displayed
   in the specified date and time

#### 1.0

 * First version released

## 额外信息

 *  版本 **1.2**
 *  最后更新：**3 年前**
 *  活跃安装数量 **2,000+**
 *  WordPress 版本 ** 3.6 或更高版本 **
 *  已测试的最高版本为 **6.4.8**
 *  语言
 * [English (US)](https://wordpress.org/plugins/wonderplugin-conditional-display/)
 * 标签
 * [browser detect](https://cn.wordpress.org/plugins/tags/browser-detect/)[conditional display](https://cn.wordpress.org/plugins/tags/conditional-display/)
   [mobile detect](https://cn.wordpress.org/plugins/tags/mobile-detect/)
 *  [高级视图](https://cn.wordpress.org/plugins/wonderplugin-conditional-display/advanced/)

## 评级

 5 星（最高 5 星）。

 *  [  7 条 5 星评价     ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/?filter=5)
 *  [  0 条 4 星评价     ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/?filter=4)
 *  [  0 条 3 星评价     ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/?filter=3)
 *  [  0 条 2 星评价     ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/?filter=2)
 *  [  0 条 1 星评价     ](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/?filter=1)

[Your review](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/wonderplugin-conditional-display/reviews/)

## 贡献者

 *   [ WonderPlugin ](https://profiles.wordpress.org/wonderplugin/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/wonderplugin-conditional-display/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://www.wonderplugin.com/wordpress-conditional-display-for-mobile/)