[Solved] Copy current record to another table with php and mysql


Do you mean something like this?

$sql = "INSERT INTO prueba (nombre) VALUES ($nombre) WHERE id = '$id'";

1)use mysqli instead of mysql

2) instead of $row[0] use $row[nombre_ID] (if thats what its called)

3) do the same for $row[1] to like $row[nombre]

4) change mysql_fetch_row($query) to mysqli_fetch_array($query,MYSQLI_ASSOC)

6

solved Copy current record to another table with php and mysql