I am using Qualtrics survey software and experiencing issues with bots. Their own bot detection tools are not sufficient.
I want to detect if a bot is completing the form. To do so, I thought I would change the colors of one field to be all white (same color as the background). The following CSS is not working to do so:
#ID > * {
background-color: white !important;
color: white ! important;
}
The following JavaScript is also not working:
var nodes = document.getElementById('ID').childNodes;
for(var i = 0; i < nodes.length; i++){
if(nodes[i].nodeName.toLowerCase() == 'div'){
nodes[i].style.backgroundColor = 'white !important';
nodes[i].style.color = 'white !important';
}
}
How do I target an element and all its child elements and make them invisible to the human eye, but not a computer?
MWE on Qualtrics
https://uwartsandsciences.sjc1.qualtrics.com/jfe/form/SV_5sYhuvDNJcRpdS6
The first question (ID == QID1
) I want hidden from the human eye. The second can remain visible.