質問編集履歴
4
誤字修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -368,7 +368,7 @@
|
|
368
368
|
|
369
369
|
問題なく動作していましたが、
|
370
370
|
|
371
|
-
この2箇所のコードを記述すると
|
371
|
+
この2箇所のコードを記述するとエラーが表示され、データベースには何も反映されません。
|
372
372
|
|
373
373
|
|
374
374
|
|
3
書式の改善
test
CHANGED
File without changes
|
test
CHANGED
@@ -14,11 +14,13 @@
|
|
14
14
|
|
15
15
|
###発生している問題・エラーメッセージ
|
16
16
|
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
|
21
|
-
|
17
|
+
Fatal error: Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) in /Applications/MAMP/htdocs/phpkiso/thanks.php:13 Stack trace: #0 /Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
18
|
+
|
19
|
+
|
20
|
+
|
21
|
+
### php_error.logの表示
|
22
|
+
|
23
|
+
/Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
22
24
|
|
23
25
|
|
24
26
|
|
@@ -377,17 +379,3 @@
|
|
377
379
|
● データベースに以下のテーブルを作成
|
378
380
|
|
379
381
|
![イメージ説明](7f975eebdef49d6a09ee6ba4fd7f4206.png)
|
380
|
-
|
381
|
-
|
382
|
-
|
383
|
-
|
384
|
-
|
385
|
-
###エラー表示
|
386
|
-
|
387
|
-
Fatal error: Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) in /Applications/MAMP/htdocs/phpkiso/thanks.php:13 Stack trace: #0 /Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
388
|
-
|
389
|
-
|
390
|
-
|
391
|
-
### php_error.logの表示
|
392
|
-
|
393
|
-
/Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
2
誤字の修正
test
CHANGED
File without changes
|
test
CHANGED
@@ -388,6 +388,6 @@
|
|
388
388
|
|
389
389
|
|
390
390
|
|
391
|
-
### php_error.log
|
391
|
+
### php_error.logの表示
|
392
|
-
|
392
|
+
|
393
|
-
|
393
|
+
/Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
1
エラー表示
test
CHANGED
File without changes
|
test
CHANGED
@@ -377,3 +377,17 @@
|
|
377
377
|
● データベースに以下のテーブルを作成
|
378
378
|
|
379
379
|
![イメージ説明](7f975eebdef49d6a09ee6ba4fd7f4206.png)
|
380
|
+
|
381
|
+
|
382
|
+
|
383
|
+
|
384
|
+
|
385
|
+
###エラー表示
|
386
|
+
|
387
|
+
Fatal error: Uncaught PDOException: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) in /Applications/MAMP/htdocs/phpkiso/thanks.php:13 Stack trace: #0 /Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|
388
|
+
|
389
|
+
|
390
|
+
|
391
|
+
### php_error.log
|
392
|
+
|
393
|
+
#0 /Applications/MAMP/htdocs/phpkiso/thanks.php(13): PDO->__construct('mysql:dbname=ph...', 'root', '') #1 {main} thrown in /Applications/MAMP/htdocs/phpkiso/thanks.php on line 13
|