CoCalc -- Collaborative Calculation in the Cloud
SharedPersonal / Grandpa's Memoir / Format_Stories.phpOpen in CoCalc
<!DOCTYPE html>
<html>
  <head>
    <link href="favicon.ico" rel="icon" type="image/x-icon">
    <link crossorigin="anonymous" href=
    "https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css"
    integrity=
    "sha384-ggOyR0iXCbMQv3Xipma34MD+dH/1fQ784/j6cY/iJTQUOhcWr7x9JvoRxT2MZw1T"
    rel="stylesheet">
    <meta content="width=device-width, initial-scale=1.0" name="viewport">
    <title>
      Submit Story
    </title>
  </head>
  <body>
    <div id="main" style="text-align:center; position: relative;">
      <h1>
        Submit Story
      </h1>
      <br>
      <div id="form_container" style="width:350px; text-align:center; padding:10px;  margin-left: auto ; margin-right: auto ;">
        <form action = "Format_Storiies.php" method = "post">
          <input name="title" type="text" placeholder="Title" style="width:100%;">
          <br>
          <input name="date" type="text" placeholder="Date" style="width:100%;">
          <br>
          <textarea name="Story" type="text" placeholder="Story" style="width:100%; height:300px"></textarea>
          <br>
          <br>
          <button id="submit" type="submit" onClick="submit()" style="width:100%;">Submit</button>
          <button id="clear" onClick="this.form.reset()" style="width:100%;">Clear</button>
        </form>
          <?php
//       $fileLocation = getenv("DOCUMENT_ROOT") . "/new_stories.txt";
//       $file = fopen($fileLocation,"w");

      echo $_POST['title']
//       $date = $_POST['date'];
//       $story = $_POST['story'];

//       $content = "\story{" + $title + "}{" + $date + "}{" + $story + "}";
//       fwrite($file,$content);
//       fclose($file);
    ?>
      </div>
    </div>

  </body>

</html>