And for the date it also says "blob". All values in these fields are correct.
According to phpnet(about the mysql_field_type function): The returned field type will be one of "int", "real", "string", "blob", and others as detailed in the » MySQL documentation.
http://dev.mysql.com/doc/refman/5.0/en/data-types.html
Date is a valid data-type so ...
Anybody knows what the problem might be?
Code: Select all
<?php
/*
Connection to database and stuff
*/
$body .= '<form name="register" action="/pages/process_reg.php" method="post"><table>';
for($n=0;$n<=$i;$n++){
$column = $col[$n];
if (!(in_array($column, $auto))){ // Create input fields for columns not in the $auto-array
$type= mysql_field_type($result, $n);
$body .= "<tr><td>$column: $type </td> <td><input type=\"text\" name=\"$column\" id=\"$column\"/></td> </tr>";
if (in_array($column, $confirm)){ // Create confirmation-fields for columns in the $confirm-array
$body .= "<tr><td>$column (again): </td> <td><input type=\"text\" name=\"$column"."2"."\" /> (confirm the above)</td> </tr>";
}
}
}
$body .= "<tr><td><input type=\"submit\" value=\"register\" /></td><td></td></tr></table></form>";
?>