I can not figure out how to update the record with a a decimal. For example. For room width, I need to add 4.2 but it rounds to 4. Please help
if ((isset($_POST["MM_update"])) && ($_POST["MM_update"] == $form_number)) { $updateSQL = sprintf("UPDATE pano_table817 SET room_name=%s, room_width=%s, room_length=%s, delete_image=%s, is_pano=%s, outside_image=%s, floor_level=%s WHERE pano_id=%s", GetSQLValueString($_POST['room_name'], "text"), GetSQLValueString($_POST['room_width'],"numeric"), GetSQLValueString($_POST['room_length'],"numeric"), GetSQLValueString($_POST['delete_image'],"int"), GetSQLValueString($_POST['is_pano'],"int"), GetSQLValueString($_POST['outside_image'],"int"), GetSQLValueString($_POST['floor_level'],"int"), GetSQLValueString($_POST['pano_id'], "int")); mysql_select_db($database_ndctour, $ndctour); $Result1 = mysql_query($updateSQL, $ndctour) or die(mysql_error()); HTML Form:
<input type="text" name="room_width" class="input-text-integer" value="<?php echo $row_uploaded_images['room_width']?>">ft</td><td> <input type="text" name="room_length" class="input-text-integer" value="<? php echo $row_uploaded_images['room_length']?>">ft</td><td>
DESCRIBE PANO_TABLE817;would be helpful... especially the data type ofroom_widthGetSQLValueStringis from macromedia DW, nothing from then should be in production today.mysql_should not be being used. Use PDO or mysqli. They support placeholders which will be similiar to your current usage.