I have a huge problem... Help~!

greenspun.com : LUSENET : S-Mart Shopping Cart : One Thread

Apparently everyone on my site is using the same shopping cart and thus when ppl add items to their cart they see other people's items on their cart.

I've checked out the problem. I went into the temp dir and found that this is how S-Mart named the temp files...


The IP address of the person who ordered does not come up! I've since checked my source and it looks like this:

# Get the hostname, for file reference sub get_host { $host = $ENV{'REMOTE_HOST'}; $reffile = "$tmpdir$delim$storename-$host"; }

So it shoulda' done it. Anyone have ideas? Thanks!

-- Ekin (hsiehpaul@hotmail.com), February 19, 2000


I had this problem also

it is because not everyone hase a hostmane assoc with there IP

$host = $ENV{'REMOTE_HOST'}; changes to $host = $ENV{'REMOTE_ADDR'};

-- Scott Bakalor (scott@bakalor.com), February 19, 2000.

Moderation questions? read the FAQ