Syntax error - PHP if statement in html td tag : <p>I get this message in my browser: Parse error: syntax error, unexpected 'if' (T_IF)</p>

<p>I have been making a HTML table showing prices on a Woocommerce product.</p>

<p>I have seen a lot of similar issues, but cannot relate to my own problem.</p>

<p>The problem should be in this code... </p>

<pre><code>            &lt;tr&gt;
                &lt;td&gt;'. $product_variation-&gt;get_name() .'&lt;/td&gt;
                &lt;td&gt;'. $product_variation-&gt;get_regular_price() .'&lt;/td&gt;
                &lt;td&gt;'
                 if($sale_price) {
                   echo $sale_price;
                    }else {
                   echo $product_variation-&gt;get_regular_price();
                    }
                '&lt;/td&gt;
            &lt;/tr&gt;';´´´
</code></pre>
