HELP! update content even with a dash
Posted: Wed Nov 05, 2008 10:56 pm
hi there! i've created a php website and everytime i update it, it doesnt update if the data has '
below is my sample code :
any help would be useful 
below is my sample code :
Code: Select all
[color=#800000]<?php
$content_num_x = $_POST['frm_content_num'];
$content_heading_x = $_POST['frm_content_heading'];
mysql_query("UPDATE listings SET content_heading='$content_heading_x' WHERE content_num ='$content_num_x' ");
echo "<br><br>";
echo "<div align=center><h1>content updated</h1></div>";
mysql_close($con);
?>[/color]
and also why is it that data that i added ' shows with \ for example [b]season\'s should be season's [/b]