jeffarrubla / wp-nonce
此包最新版本(dev-master)没有提供许可证信息。
一个类,用于以面向对象的方式使用 wp_nonce_*() 函数。
dev-master
2018-02-23 18:41 UTC
Requires
- php: >=5.4
Requires (Dev)
- antecedent/patchwork: 2.1.7
- phpunit/phpunit: ^5
This package is not auto-updated.
Last update: 2024-09-22 15:06:06 UTC
README
一个类,用于以面向对象的方式使用 wp_nonce_*() 函数。
这些函数包括
- wp_nonce_ays()
- wp_nonce_field()
- wp_nonce_url()
- wp_verify_nonce()
- wp_create_nonce()
- check_admin_referer()
- check_ajax_referer()
- wp_referer_field()
入门指南
以下说明将帮助您在本地机器上创建项目副本并运行,以便进行开发和测试。有关如何在实时系统上部署项目的说明,请参阅部署部分。
先决条件
安装
克隆项目
git clone https://github.com/jeffarrubla/wp_nonce.git
下载zip文件或使用composer
{
"require": {
"jeffarrubla/wp-nonce": "dev-master",
"php": ">=5.4"
}
}
运行测试
为了测试能否从类中调用 wp_nonce_*() 函数。要使用composer进行测试安装,需要
要运行测试,请执行
phpunit --bootstrap tests/bootstrap.php tests/WPNonceTest
或
phpunit --bootstrap tests/bootstrap.php tests/WPNonceTest --testdox