Skip to content

Commit bfff014

Browse files
committed
x
1 parent 1aa611e commit bfff014

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

samples.php

+5-4
Original file line numberDiff line numberDiff line change
@@ -53,16 +53,17 @@
5353
if (empty($mistakes)) {
5454
include("db.php");
5555

56-
$req = $bd->prepare('INSERT INTO samples (sampleName,genre,instrument,creatorID,bpm) VALUES (:sampleName,:genre,:instrument,:creatorID,:bpm)');
57-
$req->bindValue(':sampleName', $sampleName, PDO::PARAM_STR);
56+
57+
$req = $bd->prepare('INSERT INTO samples (sampleName,genre,instrument,creatorID,bpm) VALUES (:sampleName,:genre,:instrument,:creatorID,:bpm)');
58+
$req->bindValue(":sampleName", $sampleName, PDO::PARAM_STR);
5859
$req->bindValue(':genre', $genre, PDO::PARAM_STR);
5960
$req->bindValue(':instrument', $instrument, PDO::PARAM_STR);
6061
$req->bindValue(':creatorID', $creatorID, PDO::PARAM_STR);
6162
$req->bindValue(':bpm', $bpm, PDO::PARAM_STR);
62-
echo '<pre>' . print_r($_SESSION, TRUE) . '</pre>';
63+
//echo '<pre>' . print_r($_SESSION, TRUE) . '</pre>';
6364
$req->execute();
6465
$req->closeCursor();
65-
header("Location:samples.php");
66+
header("Location: samples.php");
6667
exit();
6768
} else {
6869
print_r($mistakes);

signin.php

+2-1
Original file line numberDiff line numberDiff line change
@@ -48,14 +48,15 @@
4848
{
4949
include("db.php");
5050

51+
5152
$req=$bd->prepare('INSERT INTO users (username,email,password) VALUES (:username,:email,:password)');
5253
$req->bindValue(':username', $username, PDO::PARAM_STR);
5354
$req->bindValue(':email', $email, PDO::PARAM_STR);
5455
$req->bindValue(':password', $passhash, PDO::PARAM_STR);
5556

5657
$req->execute();
5758
$req->closeCursor();
58-
header("Location:profile.php");
59+
header("Location: login.php");
5960
exit();
6061

6162
}

0 commit comments

Comments
 (0)