title: Changing color of <a> in HTML and JS
body: <p>I need a help in changing color of  element by input. I changed a normal text yet but I dont know how to change this type by html Input. Any solutions?</p>
  <p>HTML + JS</p>
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>function changeColor() {
    let color=document.getElementById('barvaStranky').value;
    document.body.style.backgroundColor=color;
  }
  
  function changeColor2() {
    let color=document.getElementById('barvaTextu').value;
    let color2=document.getElementById('proklikKviz').value;
    document.body.style.color=color;
    document.color2.color=color;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;label for="barvaStranky"&gt;Barva stránky:&lt;/label&gt;
  &lt;input type="color" id="barvaStranky" value="#43A78B"&gt;
  &lt;input type="button" id="colorButton" value="Změň barvu" onclick="changeColor()"&gt;
  &lt;br&gt;&lt;br&gt;
  &lt;label for="barvaTextu"&gt;Barva textu:&lt;/label&gt;
  &lt;input type="color" id="barvaTextu" value="#FFFFFF"&gt;
  &lt;input type="button" id="colorButton2" value="Změň barvu" onclick="changeColor2()"&gt;
  &lt;br&gt;&lt;br&gt;
  &lt;ul style="list-style-type: none; font-size: 25px;"&gt;
    &lt;li&gt;
      &lt;a href="index.html" id="proklikKviz"&gt;Testovací kvíz&lt;/a&gt;
    &lt;/li&gt;
  &lt;/ul&gt;
  &lt;script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"&gt;&lt;/script&gt;</code></pre>
  </div>
  </div>
  </p>