1<?php 2 3 4namespace ComboStrap; 5 6 7class Html 8{ 9 10 11 /** 12 * @param string $name 13 * @throws ExceptionComboRuntime 14 * Garbage In / Garbage Out design 15 */ 16 public static function validNameGuard(string $name) 17 { 18 /** 19 * If the name is not in lowercase, 20 * the shorthand css selector does not work 21 */ 22 $validName = strtolower($name); 23 if ($validName != $name) { 24 throw new ExceptionComboRuntime("The name ($name) is not a valid name"); 25 } 26 } 27} 28