mirror of https://github.com/itsmrval/subway
parent
9d36d93ad6
commit
db71adc9f2
|
|
@ -8,11 +8,12 @@ function getStopName($stopId) {
|
|||
|
||||
return reset($result)['fields']['nom_zda'];
|
||||
}
|
||||
|
||||
function getFavorites($lineId) {
|
||||
global $conn;
|
||||
try {
|
||||
$query = $conn->prepare("SELECT stopId FROM favorites WHERE lineId = ? AND userId = ?");
|
||||
$query->execute([$lineId, $_SESSION['user_id']]);
|
||||
$query = $conn->prepare("SELECT stopId FROM favorites WHERE lineId = ?");
|
||||
$query->execute([$lineId]);
|
||||
$result = $query->fetchAll(PDO::FETCH_ASSOC);
|
||||
|
||||
return $result;
|
||||
|
|
|
|||
|
|
@ -3,7 +3,8 @@
|
|||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Subway schedules</title>
|
||||
<title>Subway</title>
|
||||
<link rel="icon" href="assets/logo/favicon.png">
|
||||
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-1BmE4kWBq78iYhFldvKuhfTAU6auU8tT94WrHftjDbrCEXSU1oBoqyl2QvZ6jIW3" crossorigin="anonymous">
|
||||
<?php
|
||||
if (!isset($_SESSION['user_id'])) {
|
||||
|
|
|
|||
Binary file not shown.
|
After Width: | Height: | Size: 42 KiB |
Binary file not shown.
|
Before Width: | Height: | Size: 20 KiB |
Loading…
Reference in New Issue