are you talking about an alert window or a new browser window? and your code doesn't seem to have anything to do with either...
If you're talking about an alert window (one that you just press ok) then I don't think you can change the color. A good site to learn all about javascript is
www.w3schools.com
Try the tutorials, that's where I learned it. As for a new browser window, I don't exactly remember how.... here's some code that might help you.
Code:
//this will make an alert popup
alert("Type your message here")
//this will open a new window
window.open("http://www.yourpage.com")