1 | <!DOCTYPE html> |
2 | <html lang="es"> |
3 | |
4 | <head> |
5 | |
6 | <meta charset="UTF-8"> |
7 | <meta name="viewport" content="width=device-width"> |
8 | |
9 | <title>Productos</title> |
10 | |
11 | <script type="module" src="lib/js/consumeJson.js"></script> |
12 | <script type="module" src="lib/js/muestraObjeto.js"></script> |
13 | <script type="module" src="lib/js/muestraError.js"></script> |
14 | |
15 | </head> |
16 | |
17 | <body onload="consumeJson('srv/productos.php') |
18 | .then(render => muestraObjeto(document, render.body)) |
19 | .catch(muestraError)"> |
20 | |
21 | <h1>Productos</h1> |
22 | |
23 | <p><a href="carrito.html">Ver carrito</a></p> |
24 | |
25 | <dl id="lista"> |
26 | <dt>Cargando…</dt> |
27 | <dd><progress max="100">Cargando…</progress></dd> |
28 | </dl> |
29 | |
30 | </body> |
31 | |
32 | </html> |