OK Stackoverflowians, Here’s the riddle for the day.
I have a weather sidebar widget on a WordPress site that snags all of its data from the Google Weather API. I would like to set a gradient from RED to BLUE and then, by the magic of the javascript gods, to look at the value of the temperature.
Higher number = closer to RED
Lower Number = closer to BLUE
Is there anything out there that can do this? Or would I have to start from scratch?
You could express the color using two dimensions like this:
Then your CSS color would become:
No idea if it will look nice though 😉