I know how to use alert boxes. I just want to know how to place a message with multiple lines in an alert box. I have tried using \n and \r between the lines but it only creates an error in the browser.
Just to tack on to what link9 already said, you can also concatenate several strings together like so:
Code:
var myMsg = "This is a message\n";
myMsg += "This is the second line\n";
myMsg += "This is the third line\n";
myMsg += "End of message.";
alert(myMsg);
But the concept is still the same. Have fun! Kevin
slanek@ssd.fsi.com
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.