title: how to set cookie from iframe and reach it from js
body: <p>I want to load an iframe <code>cdnsite.com</code> to a site called <code>differentsite.com</code></p>
  
  <p>I want to set some credentials to a cookie called <code>CDN_CREDENTS</code> in my <code>cdnsite.com</code> iframe</p>
  
  <p>Also <code>differentsite.com</code> will implement my script <code>cdnsite.com/cdn.js</code>,</p>
  
  <ol>
  <li><p>What I want to know is that, because the cookie is set in <code>cdnsite.com</code> can I read <code>CDN_CREDENTS</code> cookies from headers when loading <code>cdnsite.com/cdn.js</code> from headers.</p></li>
  <li><p>Also can I set cookies when <code>cdnsite.com/cdn.js</code> is loading from my backend via headers, with <code>cdnsite.com</code> domain</p></li>
  </ol>
  
  <p>thanks</p>