[wp-hackers] is there a hook firing right after the </html>?

Haluk Karamete halukkaramete at gmail.com
Mon Feb 2 21:21:51 UTC 2015


>
> Output buffer callbacks are automatically called at the conclusion of the
> script.
>


Automatically called bhy WordPress? I'm interested in seeing where that
happens Nacin. I'm not sure what happens in that section of the code...

For my sake, I think I can pretty much rely on shutdown hook. To me, that
fires as much as get_footer hook would fire.
Since my old implementation was running right after the get_footer() call,
and I was fine with that, I should be fine with the shutdown as well.

Looks like 'shutdown' is the only hook left - after the final breath is
given with the </html>.



Interesting...  so to tap into that area, what do you do? modify the core?
But for a generic solution, I want my plug in cache the page at the end. In
this case,  'shutdown' is the only option to



On Mon, Feb 2, 2015 at 12:50 PM, Andrew Nacin <wp at andrewnacin.com> wrote:

> Output buffer callbacks are automatically called at the conclusion of the
> script.
>
> There is a 'shutdown' hook that fires on a shutdown handler that you can
> also use.
>
> On Mon, Feb 2, 2015 at 12:09 AM, Haluk Karamete <halukkaramete at gmail.com>
> wrote:
>
> > I need to run ob_get_clean() as soon as the get_footer() is done running
> -
> > meaning as soon as the </html> is outputted.
> >
> > What hook can I use for that?
> >
> > more insight on why do I need that?
> > the goal is to put the generated html ( from <doctype to </html> ) into a
> > transient.
> > and for this goal, I set the "ob_buffer" using the get_header() action
> > hook.
> > but that's only half of the deal...
> > I still need to catch the buffer when i am done with the full page -
> > meaning when I am done wirth outputting the </html>
> >
> > is there a hook such as "after_get_footer" ?
> > _______________________________________________
> > wp-hackers mailing list
> > wp-hackers at lists.automattic.com
> > http://lists.automattic.com/mailman/listinfo/wp-hackers
> >
> _______________________________________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.com
> http://lists.automattic.com/mailman/listinfo/wp-hackers
>


More information about the wp-hackers mailing list