• Hi,

    I have following issue:
    I’m writing page with PHP and using PHP-exec.

    The page is feed-back form, so
    – have name field,
    – email field
    – multiple lines text area.

    In my script I have check and if user didn’t enter name or email, it return the form and give error.
    In this case I return text area with the already typed in text:

    <textarea rows=’10’ cols=’40’ name=’content’ id=’content’><?php echo $_POST[‘content’]; ?></textarea>

    BUT: if user typed several lines, it adds <p> or BR tags in the text area. Not user friendly at all.
    I tried to insert same text area in other places of the page (in header, in footer etc..) and there everything was fine – no tags we added. So looks like the problem on my page only.

    How this can be resolved?

    Thanks!

Viewing 1 replies (of 1 total)
  • If you don’t want WordPress formatting your user input, put your code into the content area of the page template instead. I use php includes and conditional tags to do this, but you can also use custom page templates.

Viewing 1 replies (of 1 total)
  • The topic ‘<textarea> work on page’ is closed to new replies.