|
Posted by Rik on 05/16/06 13:41
T. Wintershoven wrote:
> Hi all,
>
> The code in shop.php works just fine
>
> But, when i go to pay.php, i get the following error message:
>
> Warning: Illegal offset type in C:\Program
> Files\xampp\htdocs\Study\Week 8\pay.php on line 41
>
> Is there someone who can help me please.
> It has something to do with the line
> $_SESSION["trolley"][$_GET["order"]]["amount"] but i can't find out
> what.
Hmmmz, seeing as the above line is not in pay.php I doubt it.
It would have helped if you had indicated where line 41 was, as you're not
pasting the entire code.
I'd say:
if ($_SESSION["trolley"][$i]["amount"]!="")
should be:
if
(isset($_SESSION["trolley"][$i]["amount"])&&!empty($_SESSION["trolley"][$i][
"amount"]))
Else, explain somewhat further how things are set, and maybe
print_r($_SESSION), which could make clear to you what the problem with the
data is.
Grtz,
--
Rik Wasmus
Navigation:
[Reply to this message]
|