Format sample in HTML