这可能是一个简单的问题,但我已经尝试了几个小时而没有得到任何结果:
我正在定制一个开源 WordPress 插件。当我发布我的自定义 PHP 文件和变量时var_dump()
,$_POST
我得到以下信息:
array(7) {
["hellomail"] => array(3) {
["email"] => array(7) {
["subject"] => string(4) "asda"
["from_name"] => string(14) "Myplugin"
["from_email"] => string(12) "myplugin@myplugin.com"
["replyto_name"] => string(14) "Test"
["replyto_email"] => string(12) "myplugin@myplugin.com"
["params"] => array(1) {
["schedule"] => array(2) {
["day"] => string(10) "2013/03/21"
["time"] => string(8) "00:00:00"
}
}
["email_id"] => string(2) "25"
}
["campaign_list"] => array(1) {
["list_id"] => array(1) {
[0] => string(1) "4"
}
}
["campaign"] => array(1) {
["campaign_id"] => string(2) "24"
}
}
["receiver-preview"] => string(10) "myplugin@myplugin.com"
["_wpnonce"] => string(10) "999938595d"
["_wp_http_referer"] => string(66) "/wp-admin/admin.php?page=testpage&action=editDetails&id=25"
["action"] => string(8) "savelast"
["roll_redir"] => string(0) ""
["submit-send"] => string(6) "Senden"
}
我需要的是["campaign_id"]
和["list_id"]
。我真的不知道如何获得这些值,有没有简单的方法来访问它们?