forked from IsidoroMartin/PHP
-
Notifications
You must be signed in to change notification settings - Fork 0
/
temas.php
56 lines (54 loc) · 2.1 KB
/
temas.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
<?php
session_start();
include_once 'php/sesion.php';
include_once './controller/gestorBBDD.php';
$idcat = $_GET['id'];
$temas = getTemasByCat($idcat);
?>
<!DOCTYPE html>
<!--
To change this license header, choose License Headers in Project Properties.
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<html>
<head>
<link rel="stylesheet" type="text/css" href="css/cats/lengua.css">
<meta charset="UTF-8">
<title>PAGS</title>
<script src="./js/jquery-2.1.1.js"></script>
<script src="./js/script.js"></script>
<?php include_once 'php/loginScript.php'; ?>
</head>
<body>
<?php include_once 'php/header.php'; ?>
<div id="contenedor">
<table>
<?php
while ($tema = mysqli_fetch_array($temas)) {
$temaid = $tema['id'];
$nombre = $tema['nombre'];
$apartados = getApartado($nombre, $idcat);
?>
<tr>
<th><a href="contenido_lengua.php?idcat=<?php echo $idcat ?>&tema_nombre=<?php echo $nombre; ?>" class="enlacesblack"><?php echo $temaid; ?></a></th>
<td><a href="contenido_lengua.php?idcat=<?php echo $idcat ?>&tema_nombre=<?php echo $nombre; ?>" class="enlacesblack"> <?php echo $nombre; ?></a></td>
</tr>
<?php
while ($apartado = mysqli_fetch_array($apartados)) {
$apartadoId = $apartado['id'];
$apartadoNombre = $apartado['nombre'];
?>
<tr>
<th><a href="#" class="enlacesblack"><?php echo $temaid . "." . $apartadoId; ?></a></th>
<td><a href="#" class="enlacesblack"> <?php echo $apartadoNombre; ?></a></td>
</tr>
<?php
}
}
?>
</table>
</div>
<?php include_once 'php/footer.html'; ?>
</body>
</html>