[ic] Asking for more information if buying a certain product

Doug Alcorn interchange-users@lists.akopia.com
Tue May 29 21:11:01 2001


Jillian Carroll <jcarroll@horizon.sk.ca> writes:

> I have a project that I am working on in which I would like to be
> able to ask the customer for more information if they buy a certain
> product.

What I do is change the mv_checkout value on the pages/ord/basket.html
page.  So, as I'm looking through the cart in the basket page if one
of my items requires more information I just change the actual
checkout page.  In my case, all of my items that need a custom
checkout page are in a seperate table.  I do it with perl like this:

[perl]
$Scratch->{checkout} = "";   # reset it on each page reload
for (my $i = 0; $i < @{$Items}; $i++) {
  my $item = $items->[$i];
  if ($item->{mv_ib} eq "special_items_table") {
        $Scratch->{checkout} = "ord/special_checkout";
  }
}
[/perl]

Then later down in the actual form part you set

<INPUT TYPE="hidden" NAME="mv_checkout" VALUE="[scratch checkout]">

Good Luck
-- 
 (__) Doug Alcorn (mailto:doug@lathi.net http://www.lathi.net)
 oo / PGP 02B3 1E26 BCF2 9AAF 93F1  61D7 450C B264 3E63 D543
 |_/  If you're a capitalist and you have the best goods and they're
      free, you don't have to proselytize, you just have to wait.