beginTransaction(); $connection->exec($rejectSql); $_SESSION["friendshipreqs"]=$friends->numFriendshipRequests($person,$connection); $incomingRequests = $friends->incomingRequests($person,$connection); $connection->commit(); echo "You rejected ". $friend."'s friendship request.\n"; echo "friendship requests (".$_SESSION["friendshipreqs"].")\n"; echo $incomingRequests ; ?>