I want to use javascript and php to make black dots appear on the screen. So far, I have the following code, which isn't working. What am I doing wrong?
function dots() {
var dot = document.createElement("div");
dot.style = "position: relative; background-color: #000; height: 10px; width: 10px;";
document.body.appendChild(dot);
}