Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
Ángel Chica Moral
/
tbw2122_4
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
a28b5916
authored
Apr 06, 2022
by
Javier Godino Moral
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Terminada todas las funcionalidades
parent
cc2a652a
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
79 additions
and
50 deletions
administrador/seccion/tarjetas.php
datosequipos.php
equipos.php
administrador/seccion/tarjetas.php
deleted
100644 → 0
View file @
cc2a652a
<?php
include
(
"../template/cabecera.php"
);
?>
<?php
$txtequipo
=
(
isset
(
$_POST
[
'equipo'
]))
?
$_POST
[
'equipo'
]
:
""
;
$txtnombreJugador
=
(
isset
(
$_POST
[
'nombreJugador'
]))
?
$_POST
[
'nombreJugador'
]
:
""
;
$accion
=
(
isset
(
$_POST
[
'accion'
]))
?
$_POST
[
'accion'
]
:
""
;
include
(
"../config/bd.php"
);
switch
(
$accion
){
case
"Agregar"
:
break
;
case
"Modificar"
:
break
;
case
"Cancelar"
:
break
;
}
?>
<div
class=
"col-md-7"
>
<table
class=
"table table-bordered"
>
<thead>
<tr>
<th>
Equipo
</th>
<th>
Jugador
</th>
<th>
Tarjetas
</th>
<th>
Goles
</th>
<th>
Acciones
</th>
</tr>
</thead>
<tbody>
<tr>
<td>
Nombre equipo
</td>
<td>
Nombre jugador
</td>
<td>
Goles
</td>
<td>
Tarjetas
</td>
<td>
Seleccionar | Borrar
</td>
</tr>
</tbody>
</table>
</div>
<?php
include
(
"../template/pie.php"
);
?>
\ No newline at end of file
datosequipos.php
View file @
a28b5916
<?php
include
(
"template/cabecera.php"
);
?>
<?php
include
(
"administrador/config/bd.php"
);
$idequipo
=
(
isset
(
$_POST
[
'id_equipo'
]))
?
$_POST
[
'id_equipo'
]
:
""
;
//SELECT id_equipoL, id_equipoV FROM jornadas WHERE id_jornada=:id_jornada
$SQL
=
$conexion
->
prepare
(
"SELECT Imagen, Nombre FROM equipos WHERE id=:id_equipo "
);
$SQL
->
bindParam
(
':id_equipo'
,
$idequipo
);
$SQL
->
execute
();
$datosequipo
=
$SQL
->
fetchAll
(
PDO
::
FETCH_ASSOC
);
$SQL2
=
$conexion
->
prepare
(
"SELECT Nombre FROM jugadores WHERE id_equipo=:id_equipo "
);
$SQL2
->
bindParam
(
':id_equipo'
,
$idequipo
);
$SQL2
->
execute
();
$jugadoresequipo
=
$SQL2
->
fetchAll
(
PDO
::
FETCH_ASSOC
);
?>
<div
class=
"card"
>
<div
class=
"card-header"
>
Consultar Datos equipo
</div>
<div
class=
"card-body"
>
<form
method=
"POST"
enctype=
""
>
<div
class =
"form-group"
>
<label
for=
"jornada"
>
Equipo:
</label>
<input
type=
"number"
min=
"1"
max=
"20"
required
class=
"form-control"
name=
"id_equipo"
id=
"id_equipo"
placeholder=
"Indica el equipo que desea consultar"
>
</div>
</br>
<div
class=
"btn-group"
role=
"group"
aria-label=
""
>
<button
type=
"submit"
name=
"Jornada"
value=
"Jornada"
class=
"btn btn-success"
>
Consultar
</button>
</div>
</form>
</div>
</div>
<div
class=
"col-md-5"
>
</br>
<div
class=
"card"
>
<div
class=
"card-header"
>
<?php
foreach
(
$datosequipo
as
$equipo
)
{
?>
<?php
echo
$equipo
[
'Nombre'
]
?>
<?php
}
?>
</div>
<div
class=
"card-body"
>
<?php
foreach
(
$datosequipo
as
$equipo
)
{
?>
<div
class=
"col-md-6"
>
<img
class=
"card-img-top"
src=
"./img/.
<?php
echo
$equipo
[
'Imagen'
]
?>
"
alt=
""
>
</div>
<?php
}
?>
</div>
</div>
</div>
<div
class=
"col-md-7"
>
</br>
<div
class=
"card"
>
<div
class=
"card-header"
>
Jugadores
</div>
<div
class=
"card-body"
>
<?php
foreach
(
$jugadoresequipo
as
$jugador
)
{
?>
<div
class=
"col-md-12"
>
<h3
class=
"text"
>
<?php
echo
$jugador
[
'Nombre'
]
?>
</h3>
</div>
<?php
}
?>
</div>
</div>
</div>
<?php
include
(
"template/pie.php"
);
?>
\ No newline at end of file
equipos.php
View file @
a28b5916
...
...
@@ -7,16 +7,23 @@ include("administrador/config/bd.php");
$listaEquipos
=
$SQL
->
fetchAll
(
PDO
::
FETCH_ASSOC
);
?>
<?php
foreach
(
$listaEquipos
as
$equipo
)
{
?>
<div
class=
"col-md-12"
>
<div
class=
"card"
>
<div
class=
"card-body"
>
<a
name=
""
id=
""
class=
"btn btn-primary"
href=
"/webapp/datosequipos.php?"
role=
"button"
>
Consultar más información
</a>
</div>
</div></br>
</div>
<?php
foreach
(
$listaEquipos
as
$equipo
)
{
?>
<div
class=
"col-md-3"
>
<div
class=
"card"
>
<img
class=
"card-img-top"
src=
"./img/.
<?php
echo
$equipo
[
'Imagen'
]
?>
"
alt=
""
>
<div
class=
"card-body"
>
<h4
class=
"card-title"
>
<?php
echo
$equipo
[
'Nombre'
]
?>
</h4>
<a
name=
""
id=
""
class=
"btn btn-primary"
href=
"/webapp/datosequipos.php?>"
role=
"button"
>
Consultar más información
</a>
</div>
</div>
</div>
</br>
</div>
<?php
}
?>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment