Use these functions and be quicker in development

Launch Insert
//$table= table name where you want to insert posted values
function linsert($table){
$f = ”;
$v = ”;
foreach($_POST as $field=>$value)
{
if($value!=”)
{
$f .= “$field,”;
$v .= “‘$value’,”;
}
}
$f = substr($f,0,strlen($f)-1);
$v = substr($v,0,strlen($v)-1);
$query=” insert into $table($f) values($v)”;
if(!mysql_query($query))
echo $query;
}
Launch Update
//$table=table name what you want to update
//$pk= primary key of that table
//$id= what row you want to update
function lupdate($table,$pk,$id){
$f = ”;
$v = ”;
foreach($_POST as [...]