title: How to toggle elements with javascript
body: <p>I'm working in wordpress with the woocommerce plugin where I wan't to show two different prices on my products.</p>
  
  <p>One as default that is shown as the user gets to the page and one that's shown when the user clicks a button. If he clicks the same button again the previous price should show again. And so on.</p>
  
  <p>So some type of check of what is shown on the page, which could be done in JQuery I guess, but is there any other way? I tried a bit with JQuery but have a bit of problems using it with woocommerce. </p>
  
  <pre><code>&lt;?php
  $incl = $product-&gt;get_price_including_tax();?&gt;
  
  &lt;p id="excl" class="price"&gt;&lt;?php echo $product-&gt;get_price_excluding_tax();?&gt; excl.&lt;/p&gt;
  
  &lt;button type="button" onclick="document.getElementById('excl').innerHTML = &lt;?php echo $incl;?&gt;"&gt;Click Me!&lt;/button&gt;
  </code></pre>
  
  <p>That does the one way around but needs the previous mentioned check in order to be used the other way around again.</p>
  
  <p>And a extra question: those incl and excl tax call ruin the settings done in the admin end with the formatting of prices. So 6.000,00 for instant becomes 6000. I tried woocommerce_price which works but is deprecated. Is there a similar function to do that? Can't find anything in the documentation.</p>