Re: formula part 3

This WebDNA talk-list message is from

2000


It keeps the original formatting.
numero = 34872
interpreted = N
texte = from the docs:[REMOVELINEITEM cart=cartID&index=3] Putting [REMOVELINEITEM] in your template immediately deletes the specified line item from the specified shopping cart file. Alternately, you may use the Remove command. See also [AddLineItem] and Add. If the cart file is not in a ShoppingCarts folder, you may use the alternate form file=/folder/cartID instead of cart=cartID.Your syntax omitted an index #-JohnArturo Vargas wrote:> I have this working > in invoice.tpl if Quantity>3 then discount2 gets added from the catalog.txt > my code is as follows: > [showif [Quantity]>3][AddLineItem > cart=[cart]&db=catalog.txt&sku=Discount2]quantity=1[/addlineitem][/showif] > > but when some one goes back from the invoice to the shopping cart and back > to the invoice I have discount2 twice. > > So I added this code to the shopping cart: > [lineitems][removelineitem > cart=[cart]&db=catalog.txt&SKU=Discount2][/lineitems] > but it is not working I still keep getting more discounts everytime I go to > the invoice.tpl. > > Can some one help? > > Arturo Vargas > The World Wide Web Store > > -----Original Message----- > From: WebCatalog Talk [mailto:WebDNA-Talk@talk.smithmicro.com]On > Behalf Of John Butler > Sent: Tuesday, July 18, 2000 6:05 PM > To: WebCatalog Talk > Subject: Re: formula part 3 > > not that I know of. probably the author of that code you found was passing > in a value > for that var (or generating it locally via [lineitems] in conjunction with > [text] or > [math]) > > Arturo Vargas wrote: > > > Ok I know I ask lots of questions!! :) > > > > I am trying to have a customer buy 3 items and get the 4th one free. This > is > > what I have done so far > > > > In the invoice.tpl I added this code that I found in another existing page > > that does what I need. > > [showif [totalQty]>3][AddLineItem > > cart=[cart]&db=catalog.txt&sku=Discount2]quantity=1[/addlineitem][/showif] > > > > Discount2 is a product that exists on my db, the price of discount2 > > is -19.95 > > > > This is not working > > > > It adds the discount2 product no matter the quantity is. > > > > Any Suggetions?? > > and is [totalQty] a tag ?? if so where is it I can't find it. > > > > Arturo Vargas > > The World Wide Web Store > > > > ------------------------------------------------------------- > > 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://search.smithmicro.com/ > > ------------------------------------------------------------- > 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://search.smithmicro.com/ > > ------------------------------------------------------------- > 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://search.smithmicro.com/ ------------------------------------------------------------- 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://search.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: formula part 3 (John Butler 2000)
  2. Re: formula part 3 (Arturo Vargas 2000)
  3. Re: formula part 3 (John Butler 2000)
  4. formula part 3 (Arturo Vargas 2000)
from the docs:[REMOVELINEITEM cart=cartID&index=3] Putting [removelineitem] in your template immediately deletes the specified line item from the specified shopping cart file. Alternately, you may use the Remove command. See also [addlineitem] and Add. If the cart file is not in a ShoppingCarts folder, you may use the alternate form file=/folder/cartID instead of cart=cartID.Your syntax omitted an index #-JohnArturo Vargas wrote:> I have this working > in invoice.tpl if Quantity>3 then discount2 gets added from the catalog.txt > my code is as follows: > [showif [Quantity]>3][AddLineItem > cart=[cart]&db=catalog.txt&sku=Discount2]quantity=1[/addlineitem][/showif] > > but when some one goes back from the invoice to the shopping cart and back > to the invoice I have discount2 twice. > > So I added this code to the shopping cart: > [lineitems][removelineitem > cart=[cart]&db=catalog.txt&SKU=Discount2][/lineitems] > but it is not working I still keep getting more discounts everytime I go to > the invoice.tpl. > > Can some one help? > > Arturo Vargas > The World Wide Web Store > > -----Original Message----- > From: WebCatalog Talk [mailto:WebDNA-Talk@talk.smithmicro.com]On > Behalf Of John Butler > Sent: Tuesday, July 18, 2000 6:05 PM > To: WebCatalog Talk > Subject: Re: formula part 3 > > not that I know of. probably the author of that code you found was passing > in a value > for that var (or generating it locally via [lineitems] in conjunction with > [text] or > [math]) > > Arturo Vargas wrote: > > > Ok I know I ask lots of questions!! :) > > > > I am trying to have a customer buy 3 items and get the 4th one free. This > is > > what I have done so far > > > > In the invoice.tpl I added this code that I found in another existing page > > that does what I need. > > [showif [totalQty]>3][AddLineItem > > cart=[cart]&db=catalog.txt&sku=Discount2]quantity=1[/addlineitem][/showif] > > > > Discount2 is a product that exists on my db, the price of discount2 > > is -19.95 > > > > This is not working > > > > It adds the discount2 product no matter the quantity is. > > > > Any Suggetions?? > > and is [totalQty] a tag ?? if so where is it I can't find it. > > > > Arturo Vargas > > The World Wide Web Store > > > > ------------------------------------------------------------- > > 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://search.smithmicro.com/ > > ------------------------------------------------------------- > 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://search.smithmicro.com/ > > ------------------------------------------------------------- > 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://search.smithmicro.com/ ------------------------------------------------------------- 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://search.smithmicro.com/ John Butler

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:

WebCat2 - Getting to the browser's username/password data (1997) RAM variables (1997) [OT] HTML Email in Lotus Notes (2005) A little syntax help (1997) About WebCatalog and iTools 7 (2003) Re[2]: 2nd WebCatalog2 Feature Request (1996) Webstar 1.3.1 PPC (1997) Line items in table cells (1997) re: date search problem (1999) [WebDNA] showif/sendmail question (2008) [writefile] and CR's (2001) Date Question (2002) [OT] KeepItUp for Windows (2003) webcat serving up 2+ versions of the same db!!!?? (2000) WebDelivery downloads alias, not original ? (1997) Unsibscribe Was: UPS uber integration (2007) Emailer (1998) Emailer Problem (2000) Sample Tearoom Search Error (1997) [WriteFile] problems (1997)