PHP order form and calculations

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mbatestblrock
    New Member
    • Sep 2007
    • 164

    PHP order form and calculations

    Hey all you PHP gods and goddesses, I was hoping for a pointer for a tutorial, perhaps some teachings on creating an order form. I am not asking for a complete explanation by anyone here but was hoping you may be able to point me towards a tutorial online somewhere.

    I found this... which is pretty much cut and try for what I need.
    http://www.developingw ebs.net/html/formcalculation sphp.php
    Only the example at the bottom of the page doesn't calculate anything. I starting to read through it now but know how good it will be.

    My end goal is to have a food menu with a few sections of different food items. I need to have a quantity box, and then a submit for total button that will do just that.

    I am decent at picking things up so any pointers, or links to something that is along those lines would be amazing. Generally I would search a heck of a lot longer but this was kind of last minute and the issue is pressed for time!

    so thank you very much in advance!
  • ronverdonk
    Recognized Expert Specialist
    • Jul 2006
    • 4259

    #2
    Like this one?
    PHP Tutorial: Order Form

    Ronald

    Comment

    • mbatestblrock
      New Member
      • Sep 2007
      • 164

      #3
      Originally posted by ronverdonk
      Like this one?
      PHP Tutorial: Order Form

      Ronald

      Sorry I guess I should have specified.. I need the actual calculations to take place.

      2 cakes at $5.00 each
      5 muffins at $2.00 Each


      ---------------------------------------
      Customers Oder Page:

      You ordered

      2 Cakes
      5 Muffins

      Your total is $20.00 Thank you.

      _______________ _______________ __

      Something along those lines.. I ran through that link I gave earlier and I am getting the output as theirs.. They have variable holding prices in the script, it just doesnt calculate it
      ???

      Thank you for the quick response though!

      Comment

      • Markus
        Recognized Expert Expert
        • Jun 2007
        • 6092

        #4
        Have a look at php operators.

        [php]
        $_x = 1;
        $_y = 3;
        echo $_x + $_y;
        [/php]

        Comment

        • ronverdonk
          Recognized Expert Specialist
          • Jul 2006
          • 4259

          #5
          Originally posted by mbatestblrock
          Sorry I guess I should have specified.. I need the actual calculations to take place.

          2 cakes at $5.00 each
          5 muffins at $2.00 Each


          ---------------------------------------
          Customers Oder Page:

          You ordered

          2 Cakes
          5 Muffins

          Your total is $20.00 Thank you.

          _______________ _______________ __

          Something along those lines.. I ran through that link I gave earlier and I am getting the output as theirs.. They have variable holding prices in the script, it just doesnt calculate it
          ???

          Thank you for the quick response though!
          So what do you expect us to do? Teach you how to program calculations? Make you an order form? You'll have to start programming yourself. When you run into trouble with that, show us and we will try to help you.

          Ronald

          Comment

          • mbatestblrock
            New Member
            • Sep 2007
            • 164

            #6
            Originally posted by ronverdonk
            So what do you expect us to do? Teach you how to program calculations? Make you an order form? You'll have to start programming yourself. When you run into trouble with that, show us and we will try to help you.

            Ronald
            I am not sure if you read my original post where I said exactly this..

            "I am not asking for a complete explanation by anyone here but was hoping you may be able to point me towards a tutorial online somewhere."

            and then this..
            "Generally I would search a heck of a lot longer but this was kind of last minute and the issue is pressed for time!"

            I am not trying to sound to sound like some idiot who mooches off the forums. After sifting through the link I originally posted, and the one that you and markusn00b posted I got a generalized idea on how to perform what I need done.

            So thanks a lot guys.

            Comment

            • Markus
              Recognized Expert Expert
              • Jun 2007
              • 6092

              #7
              Originally posted by mbatestblrock
              I am not sure if you read my original post where I said exactly this..

              "I am not asking for a complete explanation by anyone here but was hoping you may be able to point me towards a tutorial online somewhere."

              and then this..
              "Generally I would search a heck of a lot longer but this was kind of last minute and the issue is pressed for time!"

              I am not trying to sound to sound like some idiot who mooches off the forums. After sifting through the link I originally posted, and the one that you and markusn00b posted I got a generalized idea on how to perform what I need done.

              So thanks a lot guys.
              He wasn't grilling you :)
              you're welcome

              Comment

              • mbatestblrock
                New Member
                • Sep 2007
                • 164

                #8
                Originally posted by markusn00b
                He wasn't grilling you :)
                you're welcome
                yeah he probably wasn't. I just wanted to make it clear I was not expecting such things at all. The script is working NICE by the way...

                Comment

                • Markus
                  Recognized Expert Expert
                  • Jun 2007
                  • 6092

                  #9
                  Originally posted by mbatestblrock
                  yeah he probably wasn't. I just wanted to make it clear I was not expecting such things at all. The script is working NICE by the way...
                  Good luck with your project!

                  Post back whenever!

                  Comment

                  Working...