Ok.. long story short...
I would like to send the contents of the shopping cart to another page where i can grab the info then display it so it may be mailed as a form to the owners email address..
what I am trying to accomplish is.. instead of using a payment gateway to finallize the transaction, the owner of the site I am working on just wants the items that a customer orders to be sent to his email address along with some other pieces of info...
so here we go..
right now I am working inside of ViewCart.tpl.
as a test... at the bottom of the file.. i did the following to attempt to send the loaded array $ViewCart[items] to the target page using a form action POST
<form action="http://www.carmelsilver.com/docs/orderform.php" method="post">
<input type="hidden" name="cart" value="{$ViewCart.items}">
<input type="submit" value="Order These Items"/>
</form>
then on the target orderform.php page.. I have this...
<?php
$contents = $_POST[cart];
$many = count($contents);
echo $many;
?>
what is displaying in the browser is 1. I am using the php count() function to see what I have in the array that I shipped from viewcart.tpl to orderform.php as a test
will this method even work? Can I pass variables from a template to an external php page using this method? It seems to me that the var $ViewCart[items] is loaded with all the items that the cart has.. and in the orderform.php file I was going to use that array to fill the orderform with the sent info from viewcart.tpl and then add some other stuff before finally sending it on to the owners email account using phpmail.
what am i doing wrong?