Re: buy 2 items get this free

This WebDNA talk-list message is from

2003


It keeps the original formatting.
numero = 48865
interpreted = N
texte = Jimi Sweet wrote: > My client wants to offer a free thing when someone buys 2 or more > other things. It doesn't need to show up as a line item, but is there > an elegant way to do this? i was thinking... > > [showif [number_of_items_in_cart]>1]You get this free thing![/showif] > > ...but is there a way to calculate [number_of_items_in_cart]? > By number of things do you mean units or lineitems (2 Chicklets[tm] vs 1 Wankel Rotary Engine and 1 can of SPAM). If it is two lineitems, you can use the suprisingly-named [NumLineItems] context. If it is units of anything, you'll have to use a [lineitems] loop and add the units up yourself.John-- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: buy 2 items get this free (John Peacock 2003)
  2. Re: buy 2 items get this free (Donovan 2003)
  3. Re: buy 2 items get this free (Clint Davis 2003)
  4. Re: buy 2 items get this free (Velma Kahn 2003)
  5. Re: buy 2 items get this free (Charles Kline 2003)
  6. buy 2 items get this free (Jimi Sweet 2003)
Jimi Sweet wrote: > My client wants to offer a free thing when someone buys 2 or more > other things. It doesn't need to show up as a line item, but is there > an elegant way to do this? i was thinking... > > [showif [number_of_items_in_cart]>1]You get this free thing![/showif] > > ...but is there a way to calculate [number_of_items_in_cart]? > By number of things do you mean units or lineitems (2 Chicklets[tm] vs 1 Wankel Rotary Engine and 1 can of SPAM). If it is two lineitems, you can use the suprisingly-named [NumLineItems] context. If it is units of anything, you'll have to use a [lineitems] loop and add the units up yourself.John-- John Peacock Director of Information Research and Technology Rowman & Littlefield Publishing Group 4501 Forbes Boulevard Suite H Lanham, MD 20706 301-459-3366 x.5010 fax 301-429-5748 ------------------------------------------------------------- This message is sent to you because you are subscribed to the mailing list . To unsubscribe, E-mail to: To switch to the DIGEST mode, E-mail to Web Archive of this list is at: http://webdna.smithmicro.com/ John Peacock

DOWNLOAD WEBDNA NOW!

Top Articles:

Talk List

The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...

Related Readings:

problems with 2 tags (1997) WebCat2b12--[searchstring] bug (1997) WebCat 5 Intranet Question (2003) WebCat.acgi from /cgi-bin/? (1997) OT: JavaScript question (2001) sorting and grouping (1998) Time for a hard questions. (1997) Anyone have a multi-level threaded forum? (2003) Problems when user hit back (2000) WebCat2b15MacPlugin - showing [math] (1997) WebCat2 - [include] tags (1997) Using Currencies other than Dollars (1997) sort on categories (DBEdit) (2001) [sendmail] questions... (1997) searchable list archive (1997) [WebDNA] DNA suffix (2008) Pass a form (2003) [WriteFile] problems (1997) [defined]ish (1997) WebCatalog.acgi quitting with error Type 2 (1998)