I have set up a content admin for my site which uses a form to enter and edit info. The problem I am running into is that when the user enters quotation marks in the field, it gets inserted into the db just fine, but when i want to edit the entry, it brings it back into the text box only up to the first quotation mark... i'm assuming the quotation mark is closing the form element tag... how do i get it to read back in with the quotation marks?
i know there is an addslashes() function, but i'm not sure if it can be applied here, or if it can, i wouldn't really know how to use it, since i am fairly new at this.
here's some of the code that may be relevant..
the insert sql:
$sql = "INSERT INTO gallery (g_image,g_name,g_dim,g_mat,date,g_desc,g_gal,g_sub,order_id,status) VALUES ('$g_image','$g_name','$g_dim','$g_mat','$date','$g_desc','$g_gal','$g_sub','$order_id','$status')";
the form element:
<input size="80" type="Text" name="g_dim" value="<?php echo $g_dim ?>">
THANKS!