http://www.perlmonks.org?node_id=281667

RobertX has asked for the wisdom of the Perl Monks concerning the following question:

I am new to Perl/DBI/CGI. I can grok pretty much how to get the text into the database.

My question is I want it to look exactly like it was in the form with formatting and all.

Basically for the gist, I am creating a back end to a site for the user to edit the content.

I await enlightenment oh masters!

Replies are listed 'Best First'.
Re: Text from a form to MySQL
by skyknight (Hermit) on Aug 07, 2003 at 01:15 UTC
    It doesn't sound like you've really thought this through at all. I can't even say "RTFM" because I don't know to what the "T" would be referring. Do some of your own homework, and then come back when you have more specific questions and we'll be happy to help.
Re: Text from a form to MySQL
by tedrek (Pilgrim) on Aug 07, 2003 at 01:30 UTC
    print "<pre>$text_from_db</pre>";

    Should give you the same formating as the original. Of course I am making the assumption that this is for a web page.

Re: Text from a form to MySQL
by blue_cowdawg (Monsignor) on Aug 07, 2003 at 01:21 UTC

    Two words: Problem Definition

    From what little information you have provided I would say that you have more control over the formatting and MySQL nor Perl has anything to do with it.

    Have you thought of storing markup with your text into the database?


    Peter @ Berghold . Net

    Sieze the cow! Bite the day!

    Test the code? We don't need to test no stinkin' code! All code posted here is as is where is unless otherwise stated.

    Brewer of Belgian style Ales