title: How to create localStorage for the same domain with www. at the same time or at the next visit?
body: <p>I have created a JS file that I place in some webpages other than mine.
  So mine is domain-1.com and I place this to domain-2.com and domain-3.com</p>
  
  <p>This JS contains jsonp and I save some data from their pages to my database successfully. Also, I create some cookies and I save a value to the localstorage. the problem is that when a visitor goes to domain-2.com and tomorrow to www.domain-2.com they will have a different value because os the www.</p>
  
  <p>I want this value to be the same across www. or not, maybe at the same time, I do not know an applicable idea. It is better for me to pass the value the same time for www. and without www.</p>
  
  <p>How to do this?
  I only provide them with a JS external link. It is ok If I place an iframe also.</p>