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 3 of 3
  1. #1
    Regular Coder
    Join Date
    Mar 2006
    Posts
    200
    Thanks
    27
    Thanked 2 Times in 2 Posts

    replacing /n with <br>

    Hello,

    I usually code in php, but I've been asked to do some work in asp. I'm looking for the asp code to replace /n with <br>.

    Thanks,

    Nicky

  • #2
    Regular Coder
    Join Date
    Mar 2007
    Posts
    505
    Thanks
    1
    Thanked 19 Times in 19 Posts
    May I safely assume that you mean '\n' or NewLine?

    If you want to do that in ASP, it's

    replace(string_to_search,text-to-remove,text-to-insert)

    So, for you: replace(string_to_search,"\n","<br />")

    You can also use: replace(string_to_search,vbCrLf,"<br />") where vbCrLf means "Visual Basic Carriage Return Line Feed".
    To say my fate is not tied to your fate is like saying, 'Your end of the boat is sinking.' -- Hugh Downs
    Please, if you found my post helpful, pay it forward. Go and help someone else today.

  • #3
    Regular Coder
    Join Date
    Mar 2006
    Posts
    200
    Thanks
    27
    Thanked 2 Times in 2 Posts
    Thanks for your help. That was what I meant.

    I tried to use the mySQL replace command but I think I was doing something wrong as it kept erroring!

    Thanks for your help. I'll let you know how it goes.

    Nicky


  •  

    Posting Permissions

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