public static Html::getUniqueId($id)
Prepares a string for use as a valid HTML ID and guarantees uniqueness.
This function ensures that each passed HTML ID value only exists once on the page. By tracking the already returned ids, this function enables forms, blocks, and other content to be output multiple times on the same page, without breaking (X)HTML validation.
For already existing IDs, a counter is appended to the ID string. Therefore, JavaScript and CSS code should not rely on any value t