A man with cerebral palsy who was told that he might never be able to walk has secured a world record after completing a half marathon.