If one wanted to have a review section on there website how do you go about saving the information so that anybody who comes across the site can see the review of the product?
Example:
<form method="post" action="postToThisPage.php">
<input type="text" name="review" id="productreview">
<input type="submit" id="submitbtn value="Submit Review">
</form>
<h1>Product Review</h1>
<p id="review_2></p>
var button = document.getElementById("submitbtn"),
review = document.getElementById("productreview").innerHTML;
button.addEventListener("click",function(){
var review = document.getElementById("productreview").innerHTML;
document.getElementByID("review_2").innerHTML = review;
})
I would like to be able to save the information that will be put into the so that if anybody came across the site they could see it. How do I save the information that is posted?
I think the answer lies in PHP but I am still not sure how to go about it.