[wp-hackers] Hook locations

Jeremy Clarke jer at simianuprising.com
Wed Apr 18 13:52:51 UTC 2012


On Sat, Apr 7, 2012 at 8:54 AM, Doug Stewart <zamoose at gmail.com> wrote:

> I know I've seen plenty of hook lists in the wild before but I don't
> think I've ever seen documentation as to when each of them fires. I'm
> interested in figuring out
>
> 1) the first hook that produces actual output
> 2) the last hook that fires in the head
> 3) the last hook that fires before end-of-rendering
>
>
A limited but incredibly useful list of actions sorted by the order they
first fire is on the Codex Action Reference:

http://codex.wordpress.org/Plugin_API/Action_Reference#Actions_Run_During_a_Typical_Request

For diagnostic info you're probably best-off putting it in the footer then
using jQuery to show it at the top. Better yet, why not investigate the
Debug Bar plugin's API for adding panels and use that. I haven't tried it
but it's probably pretty simple and there are other plugins that use it:

http://wordpress.org/extend/plugins/debug-bar/

http://wordpress.org/extend/plugins/debug-bar-extender/

-- 
Jeremy Clarke • jeremyclarke.org
Code and Design • globalvoicesonline.org


More information about the wp-hackers mailing list