Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 8 of 8
  1. #1
    New to the CF scene
    Join Date
    Aug 2002
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    dynamic quote calculator

    I am trying to find a quote calculator to put on a web page.
    The application is to calculate the cost of cleaning in a house. Variables being 'No. of rooms'; 'No. of settees';'No. of chairs' with a static value against each of the three variables and the quote simply adding the products of the three variables and their respective static values.
    Is there some code available that I could modify to get this done?

  • #2
    Regular Coder
    Join Date
    Jun 2002
    Location
    FL, USA
    Posts
    734
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Could you post your calculator script here.. It would be eisear to see how to do it with the script.
    CYWebmaster.com - See why we dot com!!
    ACJavascripts.com - Cut & Paste Javascripts!
    SimplyProgram.com - Personal Blog

  • #3
    Regular Coder
    Join Date
    Jun 2002
    Location
    Flint, Michigan, USA
    Posts
    620
    Thanks
    1
    Thanked 20 Times in 20 Posts
    Code:
    <!doctype HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
      "http://www.w3.org/TR/REC-html40/loose.dtd">
    
    <html lang="en-US">
      <head>
    
        <title>House Cleaning Quote</title>
        
        <!-- jimsaxton -->
    
        <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-5">
        <meta name="Author" content="James A. Alarie - jalarie@umich.edu" />
        <link rev="made" href="mailto:jalarie@umich.edu" />
    
        <meta name="MSSmartTagsPreventParsing" content="TRUE" />
    
        <script type="text/javascript">
          <!-- Hide this code from non-JavaScript browsers
            function TotalIt() {
              CostPerRoom=103.47;
              CostPerSettee=47.02;
              CostPerChair=12.17;
              
              f1=document.forms[0];                     // abbreviation
              
              RI=f1.SelR.selectedIndex;
              RV=RI*CostPerRoom;
              SI=f1.SelS.selectedIndex;
              SV=SI*CostPerSettee;
              CI=f1.SelC.selectedIndex;
              CV=CI*CostPerChair;
              TV=RV*1+SV*1+CV*1;
              
              RV=Math.round(RV*100)/100;
              SV=Math.round(SV*100)/100;
              CV=Math.round(CV*100)/100;
              TV=Math.round(TV*100)/100;
              
              f1.TotR.value=RV;
              f1.TotS.value=SV;
              f1.TotC.value=CV;
              f1.Total.value=TV;
              
              return true;
            }
          // End hiding -->
        </script>
    
      </head>
    
      <body background="jaa_bgnd.jpg" bgcolor="#ffffee" text="black"
          link="blue" vlink="#800088" alink="red">
    <!-- Page Header -->
        <center><h1>House Cleaning Quote</h1></center>
        <hr />
    
    <!-- Content -->
        <center>
          <form action="">
            <table border="1" cellspacing="2" cellpadding="2">
              <thead>
                <tr>
                  <th bgcolor="#ffffcc" colspan="3">Cost of Cleaning</th>
                </tr>
                <tr>
                  <th bgcolor="#ffffcc">Items</th>
                  <th bgcolor="#ffffcc">Count</th>
                  <th bgcolor="#ffffcc">Cost</th>
                </tr>
              </thead>
              <tbody>
                <tr>
                  <td bgcolor="aqua">No. of Rooms</td>
                  <td bgcolor="aqua">
                    <select name="SelR">
                      <option>- Pick One -</option>
                      <option>1</option>
                      <option>2</option>
                      <option>3</option>
                      <option>4</option>
                    </select>
                  </td>
                  <td bgcolor="aqua">
                    <input type="text" name="TotR" onfocus="this.blur();" />
                  </td>
                </tr>
                <tr>
                  <td bgcolor="aqua">No. of Settees</td>
                  <td bgcolor="aqua">
                    <select name="SelS">
                      <option>- Pick One -</option>
                      <option>1</option>
                      <option>2</option>
                      <option>3</option>
                    </select>
                  </td>
                  <td bgcolor="aqua">
                    <input type="text" name="TotS" onfocus="this.blur();" />
                  </td>
                </tr>
                <tr>
                  <td bgcolor="aqua">No. of Chairs</td>
                  <td bgcolor="aqua">
                    <select name="SelC">
                      <option>- Pick One -</option>
                      <option>1</option>
                      <option>2</option>
                      <option>3</option>
                      <option>4</option>
                      <option>5</option>
                    </select>
                  </td>
                  <td bgcolor="aqua">
                    <input type="text" name="TotC" onfocus="this.blur();" />
                  </td>
                </tr>
                <tr>
                  <td bgcolor="#ffcccc" colspan="3" align="center">
                    <input type="button" value=" Compute " onclick="TotalIt();" />&nbsp;
                    <input type="reset" value=" Clear ">
                  </td>
                </tr>
                <tr>
                  <td bgcolor="#ccffcc" colspan="2">Total</td>
                  <td bgcolor="#ccffcc">
                    <input type="text" name="Total" onfocus="this.blur();" />
                  </td>
                </tr>
              </tbody>
            </table>
          </form>
        </center>
    
    <!-- Page Footer -->
        <br clear="all" /><hr />
        Written on October 25, 2002, by:&nbsp;
        <a href="mailto:jalarie@umich.edu">James Alarie</a>
    
      </body>
    
    </html>

  • #4
    New to the CF scene
    Join Date
    Aug 2002
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Thanks

    James,

    Thanks for posting code for cost of cleraning house it is great, I presume you don't mind if i now build it in to my web site.

    Jim Saxton

  • #5
    Regular Coder
    Join Date
    Jun 2002
    Location
    Flint, Michigan, USA
    Posts
    620
    Thanks
    1
    Thanked 20 Times in 20 Posts
    jimsaxton, the code is provided as-is, for free, to do with as you wish. You may find other things of use at my site at:

    &nbsp;http://spruce.flint.umich.edu/~jalarie/

  • #6
    New to the CF scene
    Join Date
    May 2014
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hello Jalarie. I have a similar problem, i need a quote calculator for my accountancy website that is similar to this one below:
    Online Calculator
    Can you help?
    Thanks

  • #7
    New to the CF scene
    Join Date
    May 2014
    Posts
    3
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Hello Jalarie. I have a similar problem, i need a quote calculator for my accountancy website that is similar to this one below:
    Online Calculator
    Can you help?
    Thanks

  • #8
    Supreme Master coder! Philip M's Avatar
    Join Date
    Jun 2002
    Location
    London, England
    Posts
    17,919
    Thanks
    203
    Thanked 2,531 Times in 2,509 Posts
    This forum is not a free coding service. As a general rule, the people helping out in this forum don't write code for others, but try to help with fixing code that doesn't work.

    Do what you would do if your car or a domestic appliance broke down or you had toothache or you wanted accountancy services - pay a professional who understands what they are doing to do the work. You can post in the Web Projects section of this forum.

    All the code given in this post has been tested and is intended to address the question asked.
    Unless stated otherwise it is not just a demonstration.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •