title: Add item to favorites and save it in a Cookie
body: <p>I have this item:</p>
  
  <pre><code>&lt;li&gt;&lt;a style="display: none"&gt;Movie&lt;/a&gt;&lt;div id="movie-item" class="filterDiv thriller science-fiction action horror war 2018"&gt;&lt;/div&gt;&lt;/li&gt;
  </code></pre>
  
  <p>And a button that allows you to save that item in Favorites:</p>
  
  <pre><code>&lt;button onclick="document.getElementById('movie-item').item.classList.add('favorites');"&gt;Mark as favorite&lt;/button&gt;
  </code></pre>
  
  <p>That works perfect, because when I click on 'Favorites' section, the item appears correctly! 
  But the problem is: I want to create a Cookie that saves that the item was marked as favorite.</p>
  
  <p>Example: <a href="https://codepen.io/anon/pen/GzOmNe#anon-login" rel="nofollow noreferrer">https://codepen.io/anon/pen/GzOmNe#anon-login</a></p>
  
  <p>Someone can help me? Thanks</p>