Getting cookies

Subscribe to Getting cookies 1 post, 1 voice

Jordon Kalilich Scriptwright

I'm having a problem with my script MySpace Birthdays on Homepage. While you're on your user homepage, there's a GM_xmlhttpRequest that grabs the listing of your friends who have upcoming birthdays, and the script places that information on the homepage. I've found that the xhr now returns a login form unless the MYUSERINFO cookie is part of the request.

The browser sends the MYUSERINFO cookie whenever it requests a MySpace page, but I can't access it via document.cookie. (If I could, this would be a trivial problem to solve; I could just grab MYUSERINFO out of document.cookie without having to store it anywhere.) The only other way I can think of getting the cookie is to try to catch it while it's being set (at login), but I can't seem to do that either.

I do realize that this might be impossible because it's a security risk, but getting the user's MYUSERINFO cookie and allowing the script to work automatically would be much more convenient than having people enter their cookie information manually.

Cross
Presentational HTML allowed.
Use <code> for inline code and <pre> for code blocks. Use &lt; and &gt; for literal < and >.
We help break paragraphs and link your links.
or cancel