0

I tried to implement cross domain local storage by copying the code from the below link,

http://www.nczonline.net/blog/2010/09/07/learning-from-xauth-cross-domain-localstorage/

But it is returning 'null'.

I did the following

  1. From the page in A.com - stored the value for local storage
  2. In the application running in localhost created server.htm as per the code provided in the link
  3. created cross_domain_storage.js also as per the link
  4. created index.html in localhost application and tried to access the key written at Step 1

But the value returned is 'null'

What is wrong with my code ?

user3122606
  • 57
  • 1
  • 3
  • 11
  • Does this answer your question? [cross domain localstorage with javascript](https://stackoverflow.com/questions/33957477/cross-domain-localstorage-with-javascript) – Anderson Green Jun 09 '21 at 23:13

1 Answers1

1

I'm not familiar with that specific solution but I did write a library that implement cross domain local storage using a shared iframe.

you are welcome to check it out on github. It comes with angularjs support as well :)

Ofir D
  • 808
  • 6
  • 15