[wp-hackers] Setting A Cookie
Jamie Talbot
wphackers at jamietalbot.com
Thu Feb 2 17:56:05 GMT 2006
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Hi,
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).
Cheers,
Jamie.
- --
http://jamietalbot.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (MingW32)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org
iD8DBQFD4ke1rovxfShShFARAh/GAJ9trpF7UNtdZMWdG4FBzGkuxdlV7ACfYcCs
3qRKmVnUbmf593T2TCCw9Ns=
=Nf2P
-----END PGP SIGNATURE-----
More information about the wp-hackers
mailing list