I provided a searchform.php in my theme. I noticed that when I search for something that does not have any results, I get the sidebar searchform and a content searchform. Both form elements appear with the same ID (id="searchform"). This would be an incorrect HTML document: ids must be unique.
I suspect WordPress provides a generate_id function, but don’t know where to look, or there is a tip to correct this out there.
TIA!
You basically answered this yourself. The ID is set right in searchform.php. It should contain a line like so:
Make the id a class instead. Done.