Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 2 of 2
  1. #1
    Regular Coder
    Join Date
    Jun 2002
    Posts
    166
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Replace spaces with a line feed

    What does one insert in the quotes to have a new line (or a return) replace any three or more occurrences of a white space? or is this even possible...

    Everything I tried failed \r, \n, variables, etc...

    xxx.replace(/\s{3,}/g, " ")

    Thanxx

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Posts
    166
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I feel silly...

    replace(/\s{3,}/g,"<br>")


    Paulette


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •