How do you use the ternary operator in conjunction with echo/what's wrong with mine?
<p>I have the following PHP statement:</p>

<pre><code>echo "&lt;p&gt;&lt;strong&gt;Ratio:&lt;/strong&gt; " . ($row2["losses"] == 0) ? "&amp;infin;&lt;/p&gt;" : number_format(($row1["wins"] / $row2["losses"]), 2) . "&lt;/p&gt;";
</code></pre>

<p>What am I doing wrong? It errors every time.</p>
