Working code to toggle red, green, and blue over the web