PDO equivalents of old mysql functions like fetch assoc : <p>I have some old code I want to be able to begin using again but it's in mysql and I'm not sure how to change the equivalent of this into PDO.</p>

<pre><code>if(mysql_num_rows($result) &gt; 0) {
        while($row = mysql_fetch_assoc($result)) {
            trackstart($row['ID']);
        }
    }       
</code></pre>

<p>How can I reach the same outcome with PDO? Or use while row = result for that matter</p>
