Sep 14, 2005 #1 pet41 Programmer Joined Sep 13, 2005 Messages 16 Location NO I maby stupid, but I can't figure out how to put a linefeed in an alert string. I am use to VB and its easy with crlf. How to do this in Javascript? Regards Rune
I maby stupid, but I can't figure out how to put a linefeed in an alert string. I am use to VB and its easy with crlf. How to do this in Javascript? Regards Rune
Sep 14, 2005 #2 4345487 Programmer Joined Dec 31, 2002 Messages 132 Location US \nl Upvote 0 Downvote
Sep 14, 2005 #3 BabyJeffy Programmer Joined Sep 10, 2003 Messages 4,189 Location GB Maybe an example would help? Code: alert('Hello[b]\n[/b]World'); // Hello World seperated by a new line Cheers, Jeff [tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch http://www.codecouch.com/jeff/[/tt] Upvote 0 Downvote
Maybe an example would help? Code: alert('Hello[b]\n[/b]World'); // Hello World seperated by a new line Cheers, Jeff [tt]Jeff's Page [/tt][tt]@[/tt][tt] Code Couch http://www.codecouch.com/jeff/[/tt]
Sep 15, 2005 #4 deputydoofy Programmer Joined Aug 30, 2005 Messages 63 Location US \n is correct and you can use it in a string. So... var myString="Hello\nWorld"; alert(myString); ...is perfectly acceptable. http://mywebpages.comcast.net/doofymusic Upvote 0 Downvote
\n is correct and you can use it in a string. So... var myString="Hello\nWorld"; alert(myString); ...is perfectly acceptable. http://mywebpages.comcast.net/doofymusic
Sep 16, 2005 Thread starter #5 pet41 Programmer Joined Sep 13, 2005 Messages 16 Location NO Thanks Upvote 0 Downvote