PHP class to validate and convert ISBNs and EANs