note 129310 added to function.session-start

From: Date: Mon, 04 Mar 2024 12:36:46 +0000
Subject: note 129310 added to function.session-start
Groups: php.notes 
Request: Send a blank email to php-notes+get-221223@lists.php.net to get a copy of this message
Codigo para hacer un pedido: <h2 align="left" ><a href="muestraProductos.php"><button type='button'>Volver al menú de compra</button></a></h2> <?php session_start(); $conexion=mysqli_connect('localhost', 'root', '', 'examen'); #Pedidos //OPCIÓN CON UNA CONSULTA MÁS COMPLICADA Y UN SOLO BUCLE if(isset($_SESSION["user"])){ $user=$_SESSION["user"]; $sql="SELECT * from pedidos, linea_pedido,productos where pedidos.usuario = '$user' and pedidos.idPedido = linea_pedido.idPedido and linea_pedido.idProducto=productos.id"; $result=mysqli_query($conexion,$sql); $idpedido=0; while($mostrar=mysqli_fetch_assoc($result)){ ?> <table border="1"> <tr> <th>idPedido</th> <th>Categoría</th> <th>Color</th> <th>Marca</th> <th>Precio</th> </tr> <tr> <td><?php echo $mostrar['idPedido'] ?></td> <td><?php echo $mostrar['categoria'] ?></td> <td><?php echo $mostrar['color'] ?></td> <td><?php echo $mostrar['marca'] ?></td> <td><?php echo $mostrar['precio']."€" ?></td> </tr> <?php if($idpedido!=$mostrar["idPedido"]){ echo "<br><br>"; $idpedido = $mostrar["idPedido"]; }?> <?php } } ---- Server IP: 45.112.84.4 Probable Submitter: 80.90.13.131 (proxied: 195.53.92.167) ---- Manual Page -- https://php.net/manual/en/function.session-start.php Edit -- https://main.php.net/note/edit/129310 Del: integrated -- https://main.php.net/note/delete/129310/integrated Del: useless -- https://main.php.net/note/delete/129310/useless Del: bad code -- https://main.php.net/note/delete/129310/bad+code Del: spam -- https://main.php.net/note/delete/129310/spam Del: non-english -- https://main.php.net/note/delete/129310/non-english Del: in docs -- https://main.php.net/note/delete/129310/in+docs Del: other reasons-- https://main.php.net/note/delete/129310 Reject -- https://main.php.net/note/reject/129310 Search -- https://main.php.net/manage/user-notes.php

« previous php.notes (#221223) next »