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:

WebCat b13 CGI -shownext- (1997) Emailer [cart] file names (1997) Silly Question (1997) HTML Editors (1997) Change Subtotal (2000) [WebDNA] Encode cookies ONLY via "method=Base64" (2008) Why don't my carts expire (1998) Tab Charactor (1997) [HIDEIF] inside [FOUNDITEM] (1997) RE: completed orders database (1997) Why this code works from some places and doesn't from others? (2000) WebCat for mass emailings (1997) iis 4.0 (1997) E-Mailer (WebCatb15acgiMac) (1997) pc (1997) Ok here is a question? (1997) WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997) TCPConnect and SSL servers (2001) interactive .pdf files and WebCatalog (2000) listfiles shows invisible files ... (1999)