Re: Adding insurance to an order, round 2

This WebDNA talk-list message is from

2003


It keeps the original formatting.
numero = 50594
interpreted = N
texte = WJ Starck wrote: > > I have a form that has a checkbox named insurance the value of which > is T if it's checked. This is so customers can elect to insure a > package (or not). > > The checkbox is submitted to another page that has the following code:Code is a little off below... forgetting an ending bracket. > > [setheader cart=[GetCookie SessionID]header40=[insurance][/setheader] ^ > and below that an orderfile that displays the cart info. > > Formulas.db has a [showif] that calculates an insurance amount if the > checkbox has been selected like so: > > Shipcost [showif [header40]=T]some code to add insurance to > shipcost[/showif] > > (It was suggested by Jay yesterday to use shipcost to add insurance to > an order as a whole, not as a lineitem.)Yes you can do this or you can do a setheader to change ShippingTotal in a template. > > Problem is, it seems like once items are added to the cart, the > Shipcost formula from Formulas.db has been applied and cannot be > changedThis is not correct. Shipping is calculated everytime an orderfile is enacted (from the formulas.db unless overridden by a setheader). - unless I remove all the items, remember what they were, check > to see if the insurance checkbox was checked, and then readd them, so > that the formula will be reapplied. > > Is there another way to do this I'm missing?Exact code to the list might help.Donovan > > Thanks, > > -- > > Will Starck > NovaDerm Skincare Science > http://www.novaderm.com > wjs@novaderm.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://webdna.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://webdna.smithmicro.com/ Associated Messages, from the most recent to the oldest:

    
  1. Re: Adding insurance to an order, round 2 (WJ Starck 2003)
  2. Re: Adding insurance to an order, round 2 (WJ Starck 2003)
  3. Re: Adding insurance to an order, round 2 (dbrooke 2003)
  4. Re: Adding insurance to an order, round 2 (Tim Robinson 2003)
  5. Re: Adding insurance to an order, round 2 (WJ Starck 2003)
  6. Re: Adding insurance to an order, round 2 (Tim Robinson 2003)
  7. Re: Adding insurance to an order, round 2 (WJ Starck 2003)
  8. Adding insurance to an order, round 2 (WJ Starck 2003)
WJ Starck wrote: > > I have a form that has a checkbox named insurance the value of which > is T if it's checked. This is so customers can elect to insure a > package (or not). > > The checkbox is submitted to another page that has the following code:Code is a little off below... forgetting an ending bracket. > > [setheader cart=[GetCookie SessionID]header40=[insurance][/setheader] ^ > and below that an orderfile that displays the cart info. > > formulas.db has a [showif] that calculates an insurance amount if the > checkbox has been selected like so: > > Shipcost [showif [header40]=T]some code to add insurance to > shipcost[/showif] > > (It was suggested by Jay yesterday to use shipcost to add insurance to > an order as a whole, not as a lineitem.)Yes you can do this or you can do a setheader to change ShippingTotal in a template. > > Problem is, it seems like once items are added to the cart, the > Shipcost formula from formulas.db has been applied and cannot be > changedThis is not correct. Shipping is calculated everytime an orderfile is enacted (from the formulas.db unless overridden by a setheader). - unless I remove all the items, remember what they were, check > to see if the insurance checkbox was checked, and then readd them, so > that the formula will be reapplied. > > Is there another way to do this I'm missing?Exact code to the list might help.Donovan > > Thanks, > > -- > > Will Starck > NovaDerm Skincare Science > http://www.novaderm.com > wjs@novaderm.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://webdna.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://webdna.smithmicro.com/ dbrooke

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:

quantity minimum problem (1997) append=T problem (1998) [WebDNA] reCAPTCHA and WebDNA (2010) Grant, please help me ... (1997) Date Formats (1997) Authenticate (2000) [isfile] ? (1997) encrypting (2000) Return records from another (1997) RE: [WebDNA] Help me install (WebDNA 7 fastcgi install on Lion 10.7.3) (2012) Discounts (2002) problem with [include] and Web*/SSL 3.0.1 (1998) Virtual hosting and webcatNT (1997) Protect and Serve (1999) searchable list archive (1997) [url] link (1998) [WebDNA] File Include HTM (2008) Document Contains No Data! (1997) no global [username] or [password] displayed ... (1997) WebCat b13 CGI -shownext- (1997)