I'm struggling getting the wp_insert_post_data filter to work as I would like. Can anyone see anything that I'm doing fundamentally wrong in this code?
Within a researcher class I have:
add_description is called earlier in the class that is then called by a method of another function which is called on the save_post action.Code:function add_description($post_id) { if(!empty($_POST['researcher_content'])) { add_filter('wp_insert_post_data', array(&$this, 'add_description_filter_handler'), 99); } } function add_description_filter_handler($data, $postarr) { $data['post_content'] = $_POST['researcher_content']; return $data; }
I feel like I'm simply missing the point on something. Can anyone slap me back into the correct direction?
Thanks!


LinkBack URL
About LinkBacks
Reply With Quote
