admin管理员组文章数量:1430726
I tried debug plugins for WordPress, but they only show the current page SQL queries. How to debug if update_option
returns false?
I am updating an object decoded from AJAX request with json_decode
although I doubt it has anything to do with it.
I tried debug plugins for WordPress, but they only show the current page SQL queries. How to debug if update_option
returns false?
I am updating an object decoded from AJAX request with json_decode
although I doubt it has anything to do with it.
- 3 it would be helpful to see code, something we can test, or anything.... – Milo Commented Jan 13, 2019 at 16:18
- 1 Can you add the code where you register your ajax request handlers, the ajax function code and also the script where you actually call the action function. – Cyclonecode Commented Jan 13, 2019 at 17:49
1 Answer
Reset to default 0I found out that my settings where filtered by validation function registered by register_setting
. Somehow I thought that it would only affect settings that where going through wordpress's own settings fields and not a custom AJAX function (the way I have it setup).
To the point of the question: I used php
exit
to debug the AJAX. update_option
returned false because the options fields where the same after validation (I was missing out one particular setting)
本文标签: mysqlupdateoption returns false in AJAXhow to debug
版权声明:本文标题:mysql - update_option returns false in AJAX, how to debug? 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1745564613a2663682.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论