404.php 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. <?php
  2. require_once "../core/class/blacklist.class.php";
  3. new blacklist;
  4. if(blacklist::isValidIPv4()){
  5. $result = blacklist::execute();
  6. } else {
  7. $result = ["error" => 404, "text" => "La page que vous cherchez n'existe pas."];
  8. }
  9. http_response_code($result["error"]);
  10. ?>
  11. <!DOCTYPE html>
  12. <html lang="fr">
  13. <head>
  14. <meta charset="UTF-8">
  15. <title>CSE Invent :. Erreur <?= $result["error"] ?></title>
  16. <style>
  17. body {
  18. font-family: Arial, sans-serif;
  19. background-color: #f2f2f2;
  20. text-align: center;
  21. padding: 50px;
  22. }
  23. .container {
  24. background-color: #fff;
  25. padding: 40px;
  26. border-radius: 10px;
  27. display: inline-block;
  28. box-shadow: 0 0 10px rgba(0,0,0,0.1);
  29. }
  30. h1 {
  31. font-size: 48px;
  32. color: #e74c3c;
  33. }
  34. p {
  35. font-size: 18px;
  36. color: #333;
  37. }
  38. a {
  39. color: #3498db;
  40. text-decoration: none;
  41. font-weight: bold;
  42. }
  43. a:hover {
  44. text-decoration: underline;
  45. }
  46. </style>
  47. </head>
  48. <body>
  49. <div class="container">
  50. <img src="img/logo.png" id="icon" alt="CSE Invent" width="300px">
  51. <h1><?= $result["error"] ?></h1>
  52. <p><?= $result["text"] ?></p>
  53. </body>
  54. </html>