Remote js and cookies

I have some js on domain A applying updates to my html page on domain B using jsonp.
All functioning great, however, I need to set and retrieve cookies on this domain B with the js/php on domain A. How can I achieve this? Really hoping this is possible!

Mostly fixed, it seems js can in fact read and write remote cookies! Didn’t think this would be normal behaviour…expected a complicated workaround for corss-domains!