Data from array to sql
Posted
by espentf
on Stack Overflow
See other posts from Stack Overflow
or by espentf
Published on 2010-05-14T13:59:55Z
Indexed on
2010/05/14
14:04 UTC
Read the original article
Hit count: 346
I'm making a webshop for a school asignment and therfore i needed to make a shopping cart. In the shopping cart the data is storred in an array.
The code for when I echo it out is
<tr>
<td><?php echo $row['Navn'];?></td>
<td><input type="text" name="antall-<?php echo $row['id_produkt'];?>" size="5" value="
<?php echo $_SESSION['handlekurv'][$row['id_produkt']]['antall'];?>" /> </td>
<td><?php echo $row['Pris'];?></td>
<td><?php echo $_SESSION['handlekurv'][$row['id_produkt']]['antall']*$row['Pris'];?></td></tr>
What i want is the store the data this code echoes out from the array, in a sql database.
Is there anyone who can help me whith this problem?
© Stack Overflow or respective owner