Go Premium for a chance to win a PS4. Enter to Win

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 584
  • Last Modified:

Skip To Next Line In A textarea?

How Can I Send A "Skip To New Line" Command In A textarea.
For Example:
document.testbox.text.value = document.testbox.text.value + "next line command" + newtext;
Please Let Me Know If And How This Can Be Done Or How Come This Can't Be Done.
otto

0
refr
Asked:
refr
  • 2
1 Solution
 
cyberwizzCommented:
You can use

\n   -   New line
\t    -   Tab

document.testbox.text.value = document.testbox.text.value + "\n" + newtext;
0
 
refrAuthor Commented:
I THought I Tried That But Aperently I Must Have Been Using /n Instead.
Thanks
0
 
cyberwizzCommented:
It's a common mistake to do the other slash. In fact when I submitted the answer I almost put the wrong one down. :-)
0

Featured Post

New feature and membership benefit!

New feature! Upgrade and increase expert visibility of your issues with Priority Questions.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now