in reply to Scoping Variables

I dont think the problem is the Scope of $date in your while loop.
Check how


-= Ozzy =-