Request for JS quote

Discussion in 'Javascript' started by Shaun Furlong, Sep 18, 2006.

  1. Shaun Furlong, Sep 18, 2006
    #1
    1. Advertising

  2. Shaun Furlong

    Evertjan. Guest

    Shaun Furlong wrote on 18 sep 2006 in comp.lang.javascript:
    > I need a quote for a simple "Density Calculator" in JS.


    As long as you do not topquote,
    quoting is free on this NG.

    It is strange however,
    when one uses "I need",
    while meaning "I want".

    ;-}

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Sep 18, 2006
    #2
    1. Advertising

  3. JRS: In article <>, dated
    Mon, 18 Sep 2006 13:25:38 remote, seen in news:comp.lang.javascript,
    Shaun Furlong <> posted :
    >I'm new to this group - and newsgroups in general - so I aplogize if I'm out
    >of line here...


    If you had been intelligent enough to read past posts for a while before
    posting, you would not have felt a need to write something like that.
    The FAQ, and RFC1855 which it cites, would have told you what you need
    to know.

    >I'm a web designer, but not proficient in JS.
    >
    >I need a quote for a simple "Density Calculator" in JS. Here are two
    >examples (not JS):


    Examples on the Web are not convenient for those not using permanent
    connections.

    >1. http://www.cheeseman.com/Density-Calculator.asp
    >2.
    >http://www.myyellow.com/dynamic/services/yfsdensitycalculator/sitedensitycalcula
    >tor.jsp?PARENT=yfscjhowtoshipfromservices


    I usually calculate density by dividing the mass in kilograms by the
    volume in cubic metres.

    A quote can either be text extracted from elsewhere (e.g. "Eschew
    Surplusage") or be a firm estimate of the cost of a task. It might
    alternatively mean, in poor English, a link to a Web site.

    Learn to write intelligible, unambiguous English - after all, the Danes
    and the Dutch can do so, so why not you?

    It's a good idea to read the newsgroup and its FAQ.
    --
    © John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4 ©
    <URL:http://www.jibbering.com/faq/>? JL/RC: FAQ of news:comp.lang.javascript
    <URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates, sources.
    <URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items, links.
     
    Dr John Stockton, Sep 19, 2006
    #3
  4. > It is strange however,
    > when one uses "I need",
    > while meaning "I want".


    Thanks. It may not be technically correct, but there's nothing strange about
    it. People use the word that way all the time. ;-)

    "Evertjan." <> wrote in message
    news:Xns9842E31865A48eejj99@194.109.133.242...
    > Shaun Furlong wrote on 18 sep 2006 in comp.lang.javascript:
    >> I need a quote for a simple "Density Calculator" in JS.

    >
    > As long as you do not topquote,
    > quoting is free on this NG.
    >
    > It is strange however,
    > when one uses "I need",
    > while meaning "I want".
    >
    > ;-}
    >
    > --
    > Evertjan.
    > The Netherlands.
    > (Please change the x'es to dots in my emailaddress)
     
    Shaun Furlong, Sep 19, 2006
    #4
  5. Shaun Furlong

    McKirahan Guest

    "Shaun Furlong" <> wrote in message
    news:...
    > I'm new to this group - and newsgroups in general - so I aplogize if I'm

    out
    > of line here...
    >
    > I'm a web designer, but not proficient in JS.
    >
    > I need a quote for a simple "Density Calculator" in JS. Here are two
    > examples (not JS):
    >
    > 1. http://www.cheeseman.com/Density-Calculator.asp
    > 2.
    >

    http://www.myyellow.com/dynamic/services/yfsdensitycalculator/sitedensitycal
    culator.jsp?PARENT=yfscjhowtoshipfromservices


    Will this help -- though it has no error checking?

    <html>
    <head>
    <title>Density Calculator</title>
    <script type="text/javascript">
    function calc() {
    var decs = 5; // = decimal positions displayed
    var form = document.form1;
    var l_ft = parseInt(form.L_ft.value,10);
    var l_in = parseInt(form.L_in.value,10);
    var w_ft = parseInt(form.W_ft.value,10);
    var w_in = parseInt(form.W_in.value,10);
    var h_ft = parseInt(form.H_ft.value,10);
    var h_in = parseInt(form.H_in.value,10);
    var o_lb = parseInt(form.O_lb.value,10);
    var o_oz = parseInt(form.o_Oz.value,10);
    var c_ft = l_ft * w_ft * h_ft;
    var c_in = l_in * w_in * h_in;
    var cube = (12 * c_ft + c_in) / 12;
    var wait = (16 * o_lb + o_oz) / 16;
    var dens = wait / cube;
    dens = dens.toString()
    if (dens.indexOf(".") >= 0) {
    dens = dens.substr(0,dens.indexOf(".")+decs+1);
    }
    form.Cube.value = cube;
    form.Dens.value = dens;
    }
    function init() {
    var form = document.form1;
    form.L_ft.focus();
    form.L_ft.select();
    }
    window.onload = init;
    </script>
    </head>
    <body>
    <pre>
    <b>Calculate Density</b>
    <form name="form1">
    <b>Length: </b><input type="text" name="L_ft"
    size="6" value="0" style="text-align:right"> Feet
    <b> </b><input type="text" name="L_in"
    size="6" value="0" style="text-align:right"> Inches
    <b>Width : </b><input type="text" name="W_ft"
    size="6" value="0" style="text-align:right"> Feet
    <b> </b><input type="text" name="W_in"
    size="6" value="0" style="text-align:right"> Inches
    <b>Height: </b><input type="text" name="H_ft"
    size="6" value="0" style="text-align:right"> Feet
    <b> </b><input type="text" name="H_in"
    size="6" value="0" style="text-align:right"> Inches
    <b>Weight: </b><input type="text" name="O_lb"
    size="6" value="0" style="text-align:right"> Pounds
    <b> </b><input type="text" name="o_Oz"
    size="6" value="0" style="text-align:right"> Ounces
    <input type="button" value="Calculate" onclick="calc()"
    style="background-color:white; width:110px">
    <b> </b><input type="text" name="Cube" readonly
    size="6" value="0" style="text-align:right"> Cubic Feet (ft<sup>3</sup>)
    <b> </b><input type="text" name="Dens" readonly
    size="6" value="0" style="text-align:right"> lbs/ft<sup>3</sup>
    <input type="reset" value="Clear" onclick="init()"
    style="background-color:white; width:110px">
    </form>
    </pre>
    </body>
    </html>

    Watch for word-wrap.

    It may not be the best solution but it is "a" solution.

    Or did you "need" to pay for a solution.
     
    McKirahan, Sep 19, 2006
    #5
  6. Shaun Furlong

    Evertjan. Guest

    Shaun Furlong wrote on 19 sep 2006 in comp.lang.javascript:

    >> It is strange however,
    >> when one uses "I need",
    >> while meaning "I want".

    >
    > Thanks. It may not be technically correct, but there's nothing strange
    > about it. People use the word that way all the time. ;-)


    People can act strange all the time,
    as I wanted but not needed to say.

    The above proves that your 'all the time',
    in the case of need/want, is not correct,
    and expect you to respond
    that people use 'all the time' all the time,
    when they mean sometimes.

    I submit that for programmers,
    exactness in their statements
    is as important as exactness in their functions.

    ;-}

    --
    Evertjan.
    The Netherlands.
    (Please change the x'es to dots in my emailaddress)
     
    Evertjan., Sep 19, 2006
    #6
  7. JRS: In article <>, dated
    Tue, 19 Sep 2006 11:09:52 remote, seen in news:comp.lang.javascript,
    McKirahan <> posted :

    >Will this help -- though it has no error checking?


    > var c_ft = l_ft * w_ft * h_ft;
    > var c_in = l_in * w_in * h_in;
    > var cube = (12 * c_ft + c_in) / 12;


    Why do you not stick to topics that you understand? Take a cubic foot
    of wood, saw it into cubic inches, and count them.


    >Watch for word-wrap.


    That's the author's responsibility; do not shirk it.

    >It may not be the best solution but it is "a" solution.


    It's rubbish. It fails the simple test of comparing 1' * 1' * 1' with
    12" * 12" * 12".

    Of course, the job would be even simpler in SI - were you not a Merkin,
    you might just about be able to get that right.

    --
    © John Stockton, Surrey, UK. *@merlyn.demon.co.uk / ?? ©
    Web <URL:http://www.merlyn.demon.co.uk/> - FAQish topics, acronyms, & links.
    Correct <= 4-line sig. separator as above, a line precisely "-- " (SoRFC1036)
    Do not Mail News to me. Before a reply, quote with ">" or "> " (SoRFC1036)
     
    Dr John Stockton, Sep 19, 2006
    #7
  8. > Learn to write intelligible, unambiguous English - after all, the Danes
    > and the Dutch can do so, so why not you?


    What I have learned to do is avoid at least this newsgroup. You people are
    a little too unnecessarily abrasive for me. I'm actually running a
    business, and just "needed" a little friendly help. Guess I'll find that
    elsewhere.

    > If you had been intelligent enough to read past posts for a while before
    > posting, you would not have felt a need to write something like that.
    > The FAQ, and RFC1855 which it cites, would have told you what you need
    > to know.


    Actually I'm a pretty intelligent fellow (most days) - just not familar with
    the newsgroup protocol. I certainly wasn't looking for insults. Why on
    Earth would you respond in such a way to a perfect stranger just asking for
    a little help? (Don't answer - it's just a rhetorical question).

    Thanks anyway. Sheesh!

    "Dr John Stockton" <> wrote in message
    news:...
    > JRS: In article <>, dated
    > Mon, 18 Sep 2006 13:25:38 remote, seen in news:comp.lang.javascript,
    > Shaun Furlong <> posted :
    >>I'm new to this group - and newsgroups in general - so I aplogize if I'm
    >>out
    >>of line here...

    >
    > If you had been intelligent enough to read past posts for a while before
    > posting, you would not have felt a need to write something like that.
    > The FAQ, and RFC1855 which it cites, would have told you what you need
    > to know.
    >
    >>I'm a web designer, but not proficient in JS.
    >>
    >>I need a quote for a simple "Density Calculator" in JS. Here are two
    >>examples (not JS):

    >
    > Examples on the Web are not convenient for those not using permanent
    > connections.
    >
    >>1. http://www.cheeseman.com/Density-Calculator.asp
    >>2.
    >>http://www.myyellow.com/dynamic/services/yfsdensitycalculator/sitedensitycalcula
    >>tor.jsp?PARENT=yfscjhowtoshipfromservices

    >
    > I usually calculate density by dividing the mass in kilograms by the
    > volume in cubic metres.
    >
    > A quote can either be text extracted from elsewhere (e.g. "Eschew
    > Surplusage") or be a firm estimate of the cost of a task. It might
    > alternatively mean, in poor English, a link to a Web site.
    >
    > Learn to write intelligible, unambiguous English - after all, the Danes
    > and the Dutch can do so, so why not you?
    >
    > It's a good idea to read the newsgroup and its FAQ.
    > --
    > © John Stockton, Surrey, UK. ?@merlyn.demon.co.uk Turnpike v4.00 IE 4
    > ©
    > <URL:http://www.jibbering.com/faq/>? JL/RC: FAQ of
    > news:comp.lang.javascript
    > <URL:http://www.merlyn.demon.co.uk/js-index.htm> jscr maths, dates,
    > sources.
    > <URL:http://www.merlyn.demon.co.uk/> TP/BP/Delphi/jscr/&c, FAQ items,
    > links.
     
    Shaun Furlong, Sep 20, 2006
    #8
  9. In article <>, Dr John Stockton
    <> writes

    <snip>
    >Of course, the job would be even simpler in SI - were you not a Merkin,
    >you might just about be able to get that right.


    Why don't you spend more time on something useful and less time pursuing
    your vendetta against Murkins ? (Note correct spelling of Murkin.)

    John
    --
    John Harris
     
    John G Harris, Sep 20, 2006
    #9
  10. Shaun Furlong

    VK Guest

    > Request for JS quote

    I believe that Usenet doesn't prohibit implicetly any business-related
    conversations, as FIDONet does. In such case it was a reasonable
    question asked at a reasonable place.

    I rely on Dr.Stockton's opinion in this case (while reserving the
    rights for my own).
     
    VK, Sep 20, 2006
    #10
  11. Shaun Furlong

    Randy Webb Guest

    VK said the following on 9/20/2006 4:15 PM:
    >> Request for JS quote

    >
    > I believe that Usenet doesn't prohibit implicetly any business-related
    > conversations, as FIDONet does. In such case it was a reasonable
    > question asked at a reasonable place.
    >
    > I rely on Dr.Stockton's opinion in this case (while reserving the
    > rights for my own).


    John Stockton's opinion isn't worth the match it would take to burn the
    paper you wrote it own. Yours ranks right there with it.


    --
    Randy
    Chance Favors The Prepared Mind
    comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
    Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
     
    Randy Webb, Sep 20, 2006
    #11
  12. Shaun Furlong

    Randy Webb Guest

    John G Harris said the following on 9/20/2006 3:57 PM:
    > In article <>, Dr John Stockton
    > <> writes
    >
    > <snip>
    >> Of course, the job would be even simpler in SI - were you not a Merkin,
    >> you might just about be able to get that right.

    >
    > Why don't you spend more time on something useful and less time pursuing
    > your vendetta against Murkins ? (Note correct spelling of Murkin.)


    Because then he wouldn't have anything to do!

    --
    Randy
    Chance Favors The Prepared Mind
    comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
    Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
     
    Randy Webb, Sep 20, 2006
    #12
  13. Shaun Furlong

    VK Guest

    Randy Webb wrote:
    > John Stockton's opinion isn't worth the match it would take to burn the
    > paper you wrote it own. Yours ranks right there with it.


    I don't care where my rank is as well as my real opinion about many of
    Dr.Stockton's statements can be easily found in Usenet archives.

    Yet a question like "I have $100...$1,000 to pay for this" posted at
    c.l.j. is a netiquette question I would like to have clarified once and
    forever, with all RFC#X, Y, Z and comments from RFC#X1, Y1, Z1 (if
    existing)

    In *this* aspect I do rely on Dr.Stockton ( with the regular "Quid
    custed custodies?" fall back reserved).
     
    VK, Sep 20, 2006
    #13
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Replies:
    3
    Views:
    13,314
  2. Stimp
    Replies:
    2
    Views:
    2,290
    Stimp
    Sep 20, 2006
  3. Eric Layman
    Replies:
    3
    Views:
    643
    Rad [Visual C# MVP]
    Apr 14, 2007
  4. Replies:
    6
    Views:
    446
    Stefan Ram
    Jun 15, 2008
  5. Valery Khamenya
    Replies:
    3
    Views:
    727
Loading...

Share This Page