anonymous No title
No License PHP
2020年10月22日
Copy
<!DOCTYPE html>
<html lang="ja">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>課題1ー4</title>
</head>
<body>
  <h1>課題1ー4 フォームの作成</h1>
  <form action = "kadai_1-4.php" method = "post">
  <input type = "text" name = "comment"><br>
  <input type = "submit" name = "送信">
  </form>

  <?php
    if(isset($_POST["comment"])) {
      $comment = $_POST["comment"];
      echo $comment;
    }
  ?>
  
</body>
</html>
<!DOCTYPE html>
<html lang="ja">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>課題1ー4</title>
</head>
<body>
  <h1>課題1ー4 フォームの作成</h1>
  <form action = "kadai_1-4.php" method = "post">
  <input type = "text" name = "comment"><br>
  <input type = "submit" name = "送信">
  </form>

  <?php
    if(isset($_POST["comment"])) {
      $comment = $_POST["comment"];
      echo $comment;
    }
  ?>
  
</body>
</html>

Output

Run
年末年始は機械学習・深層学習を勉強しませんか?
No one still commented. Please first comment.
年末年始は機械学習・深層学習を勉強しませんか?
広告
未経験から最短でエンジニアへの転職を目指すなら