@GitHub-Henry So for example, if I write in the CSS section of CodePen:
It doesn't do it, the background and text color are still default. But if I go to the HTML section and write
then it works, and the background is black and the text is white.
I don't need auto preview, I'm clicking run and that's worked fine for everything else.
:warning: melekn already gave fortmaximus points
Ok, so, one more question for everyone. I've been trying to make this work for a while so I'm not just asking to be spoon fed. How do I make the CSS work on html that's been generated from the JS section? Like for example,
var temp = 'Temperature: ' + Math.round(weatherData.main.temp) + '<a class="like-link" onclick="convertToC(' + weatherData.main.temp + ')">℉</a>'; $("#temperature").html(temp);
works fine EXCEPT for the fact that class="like-link" doesn't work. The problem isn't the class, because it worked fine on text that started out in the HTML section.