/    Sign up×
Community /Pin to ProfileBookmark

Cookie works in firefox locally but not live

I’ve got a cookie set on my website to remember the background image when someone leaves the site. The cookie is getting set just fine, i can find it in my firefox cookies list, but it’s not setting the background at all.

my site is [url]http://home.mesastate.edu/~wpatters[/url]

here’s the code for retrieving the cookie:

if(document.cookie != “”){
changeBack(document.cookie.split(“=”)[1]);
}else{
randomBack();
}

the changeBack function just sets the background style to the cookie’s content. This works fine in firefox locally AND in explorer live, but in firefox live, it gives NO background, so it’s clearly finding the cookie fine… I’ve been wracking my brain on this, it’s driving me insane.

to post a comment
JavaScript

0Be the first to comment 😎

×

Success!

Help @wpatter6 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.18,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...