[ic] Add item to cart and stay on flypage / results-page

Olaf Kolling kolling at w3welt.de
Sun Jan 30 08:25:20 EST 2005


Hello Philipp,

thanks for your suggestions but your code didn't work.

>> I need a way to add items to the cart and then stay on the flypage or
>> results-list instead of displaying the basket afterwards.
PT> [seti last_page][history-scan exclude=nothing count=0][/seti]
PT> [set bounce_back]
PT> [bounce href="[scratch last_page]"]
PT> [/set]
PT> and in your form this line :
PT> <input type=hidden  name=mv_click value="bounce_back">

With some more code snipets from the archives and trying i found a
solution.  Now i bounce the users back from the basket to where they
came from controlled by a cgi-variable. I also tried a solution With
mv_nextpage but always got an error telling me the page doesn't
exist.

Here's my working code:

An additional hidden form-field on all product flypages or result pages.
<input type=hidden name=put value="1">

Somewhere at the top of basket.html
[if cgi put]
  [bounce href='[history-scan exclude="^/ord|^/multi/|^/process" default=index]']
[/if]

If one calls basket directly nothing happens because the cgi-variable
"put" is not defined.
If the basket is displayed because a user has put a new item into it
the variable has been set on the previous page and the bounce gets
executed.


Bye Olaf

--

********************************************************************
                       W³Welt Web-Entwicklung
--------------------------------------------------------------------
Olaf Kolling                            eMail: kolling w3welt.de
Mörikestraße 67                 Tel.: +49 711 96666-200
70199 Stuttgart                           Fax: +49 711 96666-201
********************************************************************



More information about the interchange-users mailing list