[wp-hackers] Setting A Cookie
wphackers at jamietalbot.com
Thu Feb 2 17:56:05 GMT 2006
-----BEGIN PGP SIGNED MESSAGE-----
I want to set a cookie dependent on whether a specific query var has been set. ie, set the cookie
to be 'jamie' if author=jamie appears in the query. As far as I can tell this can't be done at the
moment. You can't send a cookie after the headers go out in send_headers(). But, you can't get at
the query_var until parse_request() has been called. There doesn't seem to be an action in between
that would allow the cookie to be set.
Can anyone think of a way around this? If not, a new action hook would be nice: 'pre_send_headers'
or 'post_parse_request'. (That second one might be a little confusing).
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
-----END PGP SIGNATURE-----
More information about the wp-hackers