Riemann integrable and continuous almost everywhere.

I want a proof for this theorem:

Let $f$ be a function on $[a,b]$. Then $f$ is Riemann integrable if and only if $f$ is bounded and continuous almost everywhere.


This is known as the Lebesgue criterion for Riemann integrability. You can Google it or see a similar question and the wiki article for proof.