Forum Moderators: coopster
My Question is how would I make the news the user typed in still inside the text area when the user clicks on "PREVIEW" becuase it doesn't.
would I do this:
<textaea value="<?php echo $news;?>"> or something
Hope tis helps!
electricocean
My solution to the keeping content on the page has been to make an array of items, throw them into SESSION, and then unset the SESSION I created when the next page loads. Then populate the fields.
It's clean and I don't think there is anything wrong with doing things this way.
<textaea value="<?php echo $news;?>"> or something
Close. Try:
<textarea name="news" cols="55" rows="15"><? echo $_POST[news];?></textarea>
You could also echo $news to a hidden field and just not show the text box. Then submit would post the hidden field to the DB, and edit would bring up the tex box again, where you would simply echo $news as I showed above.
WBF
(Don't forget to validate $news before you do anything with it.)