I'm at my wits end. I'm beginning a project that may involve using an action hook in WP that is not well-documented: edit_{$taxonomy}
I'm trying to determine exactly when this hook runs, so I just wrote a basic function with an echo for testing. Then, I added it to functions.php in a child theme. Invariably, the line with the echo causes a "Headers already sent" error. If I comment out the echo, it's fine. I thought it might have something to do with the order in which php files are loaded when using child themes, so I went head and pasted it into the bottom of the parent theme functions.php. Same issue.
Here's the code:
add_action('edit_expedited-status', 'category_status_email');
function category_status_email() {
echo "Testing";
}
Any thoughts or ideas appreciated.
Update
Note: Update not from author
On /wp-includes/taxonomy.php, you'll find (v3.3) on line 1586 the following filter under the context/action edit
:
$value = apply_filters("edit_{$taxonomy}_{$field}", $value, $term_id);
'edit_{WHATEVER}-status'
in core. Could you please point at the file + file number?echo "Testing";die();
you won't get that error. I'm a little unclear about what your question is -- do you want to know whenedit_$taxonomy
runs?