0

Hi

Im new to this so bear with me...

If I have a backend, that allows people to add content to their site, is there a way to allow them to 'paragraph' their text, put in line breaks etc without knowing HTML code? They would be using a form which would include a textarea input...

Appreciate it massively!

Thanks

lworks

2
Contributors
3
Replies
4
Views
9 Years
Discussion Span
Last Post by nav33n
0

Yep, possible. Use nl2br ! Eg.

<?php
print nl2br($_POST['textarea']);
?>
<html>
<body>
<form method=post action=test.php>
<textarea name=textarea cols=20 rows=20></textarea>
<input type=submit name=submit value=submit>
</body>
</html>

Cheers,
Nav

0

thanks nav! you're the man! second time you've helped me out, appreciate it!

lworks

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.