Grow your CSS skills. Land your dream job.

Formatting text within text area

  • # February 21, 2013 at 9:57 am

    I’m trying to create a form which has a text area which, when the user copy pastes a resume within the text area, the original formatting is kept intact, when the output is received by the guys handling the admin. Is it possible?

    # February 21, 2013 at 10:09 am

    what kind of formatting? Do you mean whitespace?

    Whitespace *is* preserved in form submissions, but it’s ignored (not displayed) in HTML. If that’s what your problem is, you can either output the submission inside a `

    ` element, or convert the whitespace to ` ` and/or `
    `, as appropriate.
    # February 21, 2013 at 10:50 am

    This post may be useful for you if you want the user to see the formatting when they paste it in: http://css-tricks.com/forums/discussion/comment/93184#Comment_93184.

    # February 22, 2013 at 4:35 am

    The

     tag seems to capture the formatting almost accurately. Thanks. I'll have to test the output though(when the admin guys receive the form input). Will post my results asap.

    Thanks.
Viewing 4 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic.

*May or may not contain any actual "CSS" or "Tricks".