We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Had to add the empty array param for the query to work:
The text was updated successfully, but these errors were encountered:
You can add session user id and take notes accordingly
Authenticator.php
public function login($user): void { Session::put('user',[ 'email' => $user['email'], 'id' => $user['id'], ]); session_regenerate_id(true); }
notes/index.php
$userID = $_SESSION['user']['id']; $notes = $db->query("SELECT * FROM notes WHERE user_id = {$userID}")->get(); view("notes/index.view.php", [ 'heading' => 'My Notes', 'notes' => $notes ]);
Sorry, something went wrong.
No branches or pull requests
Had to add the empty array param for the query to work:
query('SELECT * FROM notes WHERE user_id = 1'_, []_)** ->fetchAll();The text was updated successfully, but these errors were encountered: