I have a text box that updates/edits my database, after thousands of errors trying to get it to actually work I am now at [hopefully] the final stage!
At the moment without these edit pages, how my website is working is that I have a block of text in the database for example
[p]This is sample text[/p]
[p]This is some more sample text that will be in the next paragraph[/p]
And when it echoes out into the site the html tags disappear and the text perfectly formatted exactly how I want it to be.
However, when I add a new page or edit the existing text I end up with exactly what I wrote in the text box echoing out into the website.
What can I do to stop this happening?
Here is the code
<form id="form" name="form" method="post" action="page_edit_parse.php" onsubmit="return validate_form ( );">
<textarea name="pagebody" id="pagebody" cols="88" rows="16"><?php echo $pagebody; ?></textarea>
<input name="pid" type="hidden" value="<?php echo $pid; ?>" />
<input type="submit" name="button" id="button" value="Submit Page Edit" />
</form>