我正在尝试向我的表中插入一些值,但我不断收到以下通知:
Notice: Array to string conversion in C:\Program Files\wamp\www\process_invitation.php on line 10
第 10 行是以下代码中的插入行:
if ((isset($_POST['inviter'], $_POST['opponent'])) && ($_POST['inviter'] != '' && $_POST['opponent'] != '' )) {
$inviter = $_POST['inviter'];
$opponent = $_POST['opponent'];
$now = time();
if ($mysqli->query("INSERT INTO invitations (inviter_user_id, invited_user_id, time) VALUES ('$inviter','$opponent','$now')")) {
return;
}
}