TRABAJO 5
Enviado por 987cinthya123456 • 17 de Noviembre de 2021 • Práctica o problema • 5.950 Palabras (24 Páginas) • 45 Visitas
TRABAJO 5
PagRuta.php
<html>
<head>
<meta charset="UTF-8">
<link href="../css/bootstrap.css" rel="stylesheet" type="text/css"/>
<title>Rutas</title>
</head>
<body style="background-color: lightskyblue">
<?php
include_once './fragmento/Header.php';
include_once '../controlador/Negocio.php';
$obj = new Negocio();
?>
<div class="container">
<table class="table table-striped table-bordered" style="background-color: white">
<thead>
<tr>
<th style="text-align: center">CÓDIGO</th>
<th style="text-align: center">RUTA</th>
<th style="text-align: center">IMAGEN</th>
<th style="text-align: center">VER</th>
</tr>
</thead>
<tbody style="text-align: center">
<?php
foreach ($obj->ListaRutas() as $k => $d) {
echo "<tr><td>$d[0]<td>$d[1] ";
echo "<td><img src='../turismo/$d[1].jpg' width='220px;' height='120px;'>";
?>
<td>
<form action="../controlador/Control.php" method="post">
<input type="hidden" value="<?= $d[0] ?>" name="code" >
<input type="hidden" value="<?= $d[1] ?>" name="picture" >
<input type="hidden" name="accion" value="guardar_ruta">
<center><button class="btn btn-success" style="background-color: black">VIAJES</button></center>
</form>
<?php
}
?>
</tbody>
</table>
</div>
</body>
</html>
[pic 1][pic 2]
PagDetalleRuta.php
<html>
<head>
<meta charset="UTF-8">
<link href="../css/bootstrap.css" rel="stylesheet" type="text/css"/>
<title>Detalle</title>
</head>
<body style="background-color: scrollbar">
<?php
include_once './fragmento/Header.php';
include_once '../controlador/Negocio.php';
$obj = new Negocio();
session_start();
?>
<div class="container">
<h3>LUGAR DE DESTINO : <?= $_SESSION["img"] ?></h3>
<div class="container">
<center>
<img src="../turismo/<?= $_SESSION["img"] ?>.jpg" class="responsive-img">
<br><br>
<a href="PagRuta.php" class="btn" style="color: blue">REGRESAR</a>
</center>
</div>
<table class="table table-striped table-bordered" style="background-color: white">
<thead>
<tr>
<th style="text-align: center">VIAJE</th>
<th style="text-align: center">FECHA</th>
<th style="text-align: center">HORA</th>
<th style="text-align: center">COSTO</th>
<th style="text-align: center">PASAJEROS</th>
</tr>
</thead>
<tbody>
<?php
foreach ($obj->ListaViajes($_SESSION["code"]) as $k => $d) {
echo "<tr><td>$d[0]<td>$d[1]<td>$d[2]<td>$d[3] ";
?>
<td>
<form action="../controlador/Control.php" method="post">
<input type="hidden" name="nro" value="<?= $d[0] ?>">
<input type="hidden" name="costo" value="<?= $d[3] ?>">
<input type="hidden" name="accion" value="guardar_pasajero">
<center><button class="btn btn-success">VER</button></center>
</form>
</td>
</tr>
<?php
}
?>
</tbody>
</table>
</body>
</html>
[pic 3][pic 4]
PagPasajero.php
<html>
<head>
<meta charset="UTF-8">
<link href="../css/bootstrap.css" rel="stylesheet" type="text/css"/>
<title>Pasajero</title>
</head>
<body style="background-color: lightsalmon">
<?php
...