Title: COD Control
Author: Kyriakos
Published: <strong>2025 年 11 月 4 日</strong>
Last modified: 2025 年 11 月 4 日

---

搜索插件

![](https://s.w.org/plugins/geopattern-icon/cod-control.svg)

# COD Control

 作者：[Kyriakos](https://profiles.wordpress.org/changlee/)

[下载](https://downloads.wordpress.org/plugin/cod-control.1.0.4.zip)

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

 [支持](https://wordpress.org/support/plugin/cod-control/)

## 描述

 * Admin menu: **COD Customers** with columns Name, Email, City, Received COD (Yes/
   No).
 * If **Received COD = No**, the **cod** gateway is removed at checkout for that
   customer.
 * Applies when users are logged in OR when they simply enter their email address
   on the checkout form.
 * Lightweight, no database tables required (uses user meta).

## 安装

 1. Upload the ZIP via **Plugins  Add New  Upload Plugin**.
 2. Activate **COD Control**.
 3. Go to **COD Control** in the admin menu to manage flags.

## 常见问题

### Does this work for guests?

If the guest uses an email that belongs to an existing WordPress user (customer/
subscriber) that has **Received COD = No**, COD will be disabled.

## 评价

此插件暂无评价。

## 贡献者及开发者

「COD Control」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ Kyriakos ](https://profiles.wordpress.org/changlee/)

[帮助将「COD Control」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/cod-control)

### 对开发感兴趣吗?

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

## 更新日志

#### 1.0.0

 * First release.

#### 1.0.1

 * wordpress.org changes recommended.
 * Fixed `readme.txt` Contributors line to use WordPress.org username `changlee`.
 * Moved inline `<style>` and `<script>` from PHP into `assets/css/codco-style.css`
   and `assets/js/codco-script.js`.
 * Added proper asset loading via `wp_enqueue_scripts` with `wp_register_style/script`,
   and `wp_localize_script` for `ajaxurl` + `nonce`.
 * Prefixed actions and methods (`codco_*`) and renamed class to `CODCO_Control`
   to avoid collisions.
 * Added nonce checks with `check_ajax_referer( 'codco_email_nonce', 'security' )`
   in AJAX handler.
 * Hardened `wp_verify_nonce()` inputs with `sanitize_text_field( wp_unslash( ...))`.
 * Escaped output late using `esc_url`, `esc_js` for dynamic values.
 * Added placeholder `ajax-loader.gif` if missing.

#### 1.0.2

 * wordpress.org changes recommended.
 * Fixed security issues with nonces and sanitization
 * Added proper permission checks (`current_user_can`)
 * Replaced inline CSS/JS with proper `wp_enqueue_*` methods
 * Updated version numbers for release

#### 1.0.3

 * wordpress.org changes recommended.
 * Fixed security issues with nonces and sanitization
 * Added proper permission checks (`current_user_can`)

#### 1.0.4

 * wordpress.org changes recommended.
 * plugin prefix gets Updated

## 额外信息

 *  版本 **1.0.4**
 *  最后更新：**7 月前**
 *  活跃安装数量 **不到10**
 *  WordPress 版本 ** 6.0 或更高版本 **
 *  已测试的最高版本为 **6.8.5**
 *  PHP 版本 ** 7.4 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/cod-control/)
 * 标签
 * [checkout](https://cn.wordpress.org/plugins/tags/checkout/)[cod](https://cn.wordpress.org/plugins/tags/cod/)
   [customers](https://cn.wordpress.org/plugins/tags/customers/)[payment](https://cn.wordpress.org/plugins/tags/payment/)
   [woocommerce](https://cn.wordpress.org/plugins/tags/woocommerce/)
 *  [高级视图](https://cn.wordpress.org/plugins/cod-control/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/cod-control/reviews/#new-post)

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

## 贡献者

 *   [ Kyriakos ](https://profiles.wordpress.org/changlee/)

## 支持

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

 [查看支持论坛](https://wordpress.org/support/plugin/cod-control/)