Author |
Topic |
|
epseja
VP-CART New User
USA
61 Posts |
Posted - December 05 2004 : 10:34:16
|
Hi,
Right now I have my minicart in my omnipresent left navigation bar. What I want to accomplish is this:
(1) From item's extended description page, customer hits "add to cart". (2) shopaddtocart's "ProcessNewAdd" sub runs, adding the item to the cart. (3) after the sub is run, it automatically redirects back to the page it came from (refreshing the page), thus showing the updated minicart.
Now, I'd LOVE to have this happen without ever hitting shopaddtocart so it's lightning fast, but I would assume that I'd have to pull the "ProcessNewAdd" sub out of shopaddtocart and put it into shopexd, then have it refresh the page once it's run. Would that cause problems with other functions or can it be done?
I'm up for any solution, so fire away!
-Eric
|
|
epseja
VP-CART New User
USA
61 Posts |
Posted - December 05 2004 : 10:54:10
|
Figured out an interim solution. At the end of the ProcessNewAdd sub, just before the "end sub" line, I stuck in this line:
ProcessReturntoLastPage
Then, right after the "end sub" line, I stuck this code in:
Sub ProcessReturntoLastPage() Dim lastpage set lastpage=request.servervariables("http_referer") responseredirect lastpage end sub
That performs the (1) (2) (3) combo I requested above. Now to try and get the sub to run right on the shopexd page.
-Eric
|
|
|
epseja
VP-CART New User
USA
61 Posts |
Posted - December 05 2004 : 10:58:50
|
Ack! The code above doesn't allow you to view the shopping cart at all. Working on a fix...
-Eric
|
|
|
|
Topic |
|