MiniVend Akopia Services

[Date Prev][Date Next][Thread Prev][Thread Next][Minivend by date ][Minivend by thread ]

Re: Emptying a cart via an HTTP request?



******    message to minivend-users from mikeh@minivend.com     ******

Quoting Bill (bplst@webbsite.com):
> 
> I need to empty all of the items out of the shopping cart from an external
> CGI script (not on the same server as Minivend).  The only way I could
> think of to do this is to put the following code:
> 
> [perl arg="carts"]
> $Safe{carts}->{main} = [];
> [/perl]
> 
> on a page named empty.html.  Then I have the other CGI program make a HTTP
> request for the page using a URL like:
> 
> http://shop.mycart.com/cgi-bin/rosmarino/empty?Vz4CrmYu;;2345
> 
> This URL is generated with a minivend [area empty] tag and passed to the
> other CGI program.  When I do this (execute the other CGI program), the
> cart doesn't empty (it's not empty when I check it by pulling up the
> ord/basket page).  However when I punch in the URL manually into a browser,
> it does empty! 
> 

If you are passing the session ID, then unless you are using WideOpen
it will not work unless the external request comes from the same
network. (WideOpen removes the host IP qualifcation.)

There are some other things you can do with a Cookie. If you
can set the MV_SESSION_ID cookie to the proper value including
network qualification then it will work without WideOpen.

Now that I think about it, I think you could read the cookie
with [read-cookie MV_SESSION_ID] and then cause your user agent
to set it to the proper session.

-- 
Mike Heins                          http://www.minivend.com/  ___ 
                                    Internet Robotics        |_ _|____
                                    131 Willow Lane, Floor 2  | ||  _ \
It's a little-known fact            Oxford, OH  45056         | || |_) |
that the Y1K problem caused         <mikeh@minivend.com>     |___|  _ <
the Dark Ages. -- unknown           513.523.7621 FAX 7501        |_| \_\
-
To unsubscribe from the list, DO NOT REPLY to this message.  Instead, send
email with 'UNSUBSCRIBE minivend-users' in the body to Majordomo@minivend.com.
Archive of past messages: http://www.minivend.com/minivend/minivend-list


Search for: Match: Format: Sort by: