Jump to content

Lani-Skyy

New Members
  • Posts

    2
  • Joined

  • Last visited

Lani-Skyy's Achievements

Newbie

Newbie (1/5)

0

Reputation

1

Community Answers

  1. There was a missing underscore in the third if statement, I'm literally so blind
  2. When I click the button "baru", it sends me to the page create_pertandingan.php, however, when I click the button "lama", nothing happens. I'm clearing the post array so the user can give another input after reloading. <?php session_start(); include("sambungan.php"); if ($_POST) { if (isset($_POST["baru"])) { $_POST = array(); header("Location:./create_pertandingan.php"); } if (isset($POST["lama"])) { $_POST = array(); header("Location:./main.php"); } } ?> <!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous"> <link href="styles.css" rel="stylesheet"> <title>SPPC</title> </head> <body> <div> <form action="load_pertandingan.php" method="post"> <p>Load Pertandingan:</p> <input type="submit" name="baru" value="Baru"> <input type="submit" name="lama" value="Lama"> </form> </div> </body> </html>
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.