Re: Wanted: More Math Functions (or, Can You Solve This?)

This WebDNA talk-list message is from

1997


It keeps the original formatting.
numero = 14039
interpreted = N
texte = On 10/20/97 4:37 PM Michael Winston wrote >So, [math]ceil(9.43)[/math] = 10 > and [math]ceil(9.43, .05)[/math] = 9.45.Wow cool! Just what I am looking for. I want to do a specialized shipping section. Here are my conditions:Base shipping is $4.75 cents. Every 5 pieces after the first 5 add 4.00 to shipping. Sets count as 5 pieces. I have assigned a shipping value to each item/set items =1 sets =5(could be more in the future)The formula looks like this: [math](((ceil [SV]\5)-1) x 4.00)+4.75[/math]where [SV] is the shipping valueHere would then be the result if 1 set and 1 piece where purchased SV is then 6. 6\5 is 1.1 rounded to 2. Subtract to get the value for the first 5 = 1 and multiply by $4.00 and add to $4.75 to get the total shipping of $8.75. Now I want to plug this into The shipping cost, but don't know how to get it in there. also is my use of parenthesis in the [math] function appropriate. :pSpeedyRobert Minor ______________________________________ Cybermill Communications 8616 Joseph Ave. St. Louis, MO 63144 (314) 962-4024webmaster@cybermill.com http://www.cybermill.com ______________________________________ PGP key available upon request. Associated Messages, from the most recent to the oldest:

    
  1. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  2. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  3. Re: Wanted: More Math Functions (or, Can You Solve This?) (Grant Hulbert 1997)
  4. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  5. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  6. Re: Wanted: More Math Functions (or, Can You Solve This?) (Grant Hulbert 1997)
  7. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  8. Re: Wanted: More Math Functions (or, Can You Solve This?) (Grant Hulbert 1997)
  9. Re: Wanted: More Math Functions (or, Can You Solve This?) (bob 1997)
  10. Re: Wanted: More Math Functions (or, Can You Solve This?) (Michael Winston 1997)
  11. Re: Wanted: More Math Functions (or, Can You Solve This?) (Grant Hulbert 1997)
  12. Wanted: More Math Functions (or, Can You Solve This?) (Michael Winston 1997)
  13. Wanted: More Math Functions (or, Can You Solve This?) (Kenneth Grome 1997)
  14. Re: Wanted: More Math Functions (or, Can You Solve This?) (Grant Hulbert 1997)
On 10/20/97 4:37 PM Michael Winston wrote >So, [math]ceil(9.43)[/math] = 10 > and [math]ceil(9.43, .05)[/math] = 9.45.Wow cool! Just what I am looking for. I want to do a specialized shipping section. Here are my conditions:Base shipping is $4.75 cents. Every 5 pieces after the first 5 add 4.00 to shipping. Sets count as 5 pieces. I have assigned a shipping value to each item/set items =1 sets =5(could be more in the future)The formula looks like this: [math](((ceil [SV]\5)-1) x 4.00)+4.75[/math]where [SV] is the shipping valueHere would then be the result if 1 set and 1 piece where purchased SV is then 6. 6\5 is 1.1 rounded to 2. Subtract to get the value for the first 5 = 1 and multiply by $4.00 and add to $4.75 to get the total shipping of $8.75. Now I want to plug this into The shipping cost, but don't know how to get it in there. also is my use of parenthesis in the [math] function appropriate. :pSpeedyRobert Minor ______________________________________ Cybermill Communications 8616 Joseph Ave. St. Louis, MO 63144 (314) 962-4024webmaster@cybermill.com http://www.cybermill.com ______________________________________ PGP key available upon request. bob

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:

[lookup] speed sales pitch (2003) SKU (1997) Firesite cache vs webcat cache (1997) MacActivity and PCS (1997) Email notification to one of multiple vendors ? (1997) problems with 2 tags (1997) Quickie question on the email templates (1997) WebCatalog 3 for Macintosh (1998) Solved. was pulldown menu differences (2005) price on detail, but not shoppingcart (1997) Clean source code (2007) Separate SSL Server (1997) webmerchant problems (2000) WebCat2b15MacPlugin - showing [math] (1997) Alternating colors (1997) WC2.0 Memory Requirements (1997) suffix mapping for NT? (1997) FW: Rollovers (1999) SiteEdit Pro Update Announcement (1997) Hello world ... (2002)