Thanks for pointing me in that direction. I actually had not over written anything, but discovered that I had placed the "to be inserted code" inside a <tr> rather than outside of it.
So far everything seems to be working now.
I'll keep you posted of any further problems.
Thanks for all your help Ivan, Scott and Alex.