Fellow Estemmed Monks

I bleieve the title is correct

Given a input:

Hello, my name is barry I am 20 I am webmaster of lsrfm.com its a student radio station

What I want to to is, remove the return carriages and repalce them with <br&rt; or </p&rt;<p&rt;

So could a fellow monk advise on how to search a ref. and replace, and also what should I search for as, I am not sure what the return carriage character is

Further more the input listed is in:

my $text = "above"

So, basic program

my $input = "Hello, my name is barry I am 20 I am webmaster of lsrfm.com its a student radio station"; 'some process replacing return chars. with &lt;/p&rt;&lt;p&tk;'

As when placing the text on a page, intially obtained from a form on a webpage, where it is a textarea, it does not format the same way as it does in the text area.
Similar to this perl monks text area, but the users dont put html tags in!

Yours

Barry Carlyon barry@barrycarlyon.co.uk

In reply to Search a perl reference and replace characters by barrycarlyon

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.