Recycling fee

This WebDNA talk-list message is from

1998


It keeps the original formatting.
numero = 22048
interpreted = N
texte = Hi all,For our computer store we have to charge a recycling fee for each HARDWARE product. The fee is calculated according to the Total of the bought items.In the invoice.tpl I have: [search db=SwicoTable.db&leAmountdata=[subTotal]&deAmountsort=1&Amounttype=num&max=1 ] [founditems] recycling fee Fr. [Fee] [/founditems] [/search] the SwicoTable.db is: Amount Fee 1000.00 5.00 2000.00 10.00 4000.00 20.00 6000.00 30.00 8000.00 40.00 10000.00 50.00 15000.00 100.00This works to some extend, that it returns a value, but for instance it returns 100.00 when the total is 6500.00, which is wrong the value should be 40.00 since it is FROM 6000.00 to 8000.00.Another problem is that I could not figure out yet how to only get Hardware products calculated. On Software the fee is not applied.I know I have to set something like [showif hardware=T] or something similar.I would really appreciate any feedback.Sincerely, Nitai Associated Messages, from the most recent to the oldest:

    
  1. Re: Recycling fee (John W 1998)
  2. Recycling fee (Nitai 1998)
Hi all,For our computer store we have to charge a recycling fee for each HARDWARE product. The fee is calculated according to the Total of the bought items.In the invoice.tpl I have: [search db=SwicoTable.db&leAmountdata=[subTotal]&deAmountsort=1&Amounttype=num&max=1 ] [founditems] recycling fee Fr. [Fee] [/founditems] [/search] the SwicoTable.db is: Amount Fee 1000.00 5.00 2000.00 10.00 4000.00 20.00 6000.00 30.00 8000.00 40.00 10000.00 50.00 15000.00 100.00This works to some extend, that it returns a value, but for instance it returns 100.00 when the total is 6500.00, which is wrong the value should be 40.00 since it is FROM 6000.00 to 8000.00.Another problem is that I could not figure out yet how to only get Hardware products calculated. On Software the fee is not applied.I know I have to set something like [showif hardware=T] or something similar.I would really appreciate any feedback.Sincerely, Nitai Nitai

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:

EIMS Problems (1997) E-mailer error codes (1997) Determining Method (2000) Running 2 two WebCatalog.acgi's (1996) A better way to do this?? (2005) [UPPERCASE] (1997) docs for WebCatalog2 (1997) [BoldWords] WebCat.acgib15Mac (1997) Is this possible, WebCat2.0 and checkboxes (1997) [BULK] RE: [WebDNA] RE: Error. WebDNA (version 5.1g or later) is not running. (2012) Credit Card Checking?? (1998) Message Board (2001) can WC render sites out? (1997) EIMS Problems (1997) Separate SSL Server (1997) taxTotal, grandTotal (1997) Wanted: Broader string manipulation functions (1997) Bulletin Board.... (2000) Nested tags count question (1997) Problem with [Search] inside of [Loop]? (1997)