#1
  1. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2003
    Posts
    3
    Rep Power
    0

    Angry I am desperarte....


    thought i was on the right track but...since you see me posting here assume I was way off track.

    Each item on the menu has the some additional items associated with it.
    ex. "name0" "quantity0" "beans0" "meat0" "extraMeat0"

    Since my menu has over 100 products in it you can see why I do not want to send the generated results to the Resturant without looping over it to see if the Quantity is GT < 0. And removing that from the order that is generated.

    I was trying to get the quanity and If the quanity is < 0 i wanted to display it in the email along with the items that also end in "0" (meat0, beans0. extraMeat0, name0).

    Please advise on your feedback and ideas. TY in advance

    I would appreciate any help you offer me.

    If you have a better solution I am all ears.


    Regards
    Steve
  2. #2
  3. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Location
    London, Ontario
    Posts
    7
    Rep Power
    0

    more info?


    I might have missed another post somewhere, but I don't really understand your post. What is the system you're trying to write and what is the problem?

    And for reference '>' is the "Greater Than" and '<' is "Less Than."
  4. #3
  5. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2003
    Posts
    3
    Rep Power
    0

    Re: I am desperarte....


    I have an order form www.moesmaitland/order/order.asp

    the form action is written in coldFusion.

    I only want to pass the Item and the associated properties to an email if the Items have a quanity of 1 or greater.

    That way the resturant does not get a huge print out of their menu each order and have to find the ITEMS that were ordered. It will be real simple.

    I sorta have something working now if you go to the URL above. but its so GHETTO.

    Thanks for looking at this for me.

    Steve
  6. #4
  7. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Sep 2003
    Location
    London, Ontario
    Posts
    7
    Rep Power
    0

    mailform.cfm


    When the user clicks submit it look like it takes them to mailform.cfm, which I can't see, but assume cycles through the products and checks if they are 0 or not.

    First, I would add default='0' to all the "Product" inputs. Without defaults they will be null and that could mess things up when comparing them to zero.

    Then, in the mailform.cfm I would use something like:

    <cfmail from="theirEmail" to="yourEmail" subject="ORDER">
    <cfoutput>
    <cfloop from='1' to='Number of Product' index='i'>
    <cfset tmp = "Form.Product" & i>
    <cfif #tmp# gt 0>PRINT OUT INFO FROM POSITION i</cfif>
    </cfloop>
    </cfoutput>

    Not sure if this is what you are looking for, but let me know if you need more info, or something along different lines.

    JEff
  8. #5
  9. No Profile Picture
    Junior Member
    Devshed Newbie (0 - 499 posts)

    Join Date
    Oct 2003
    Posts
    3
    Rep Power
    0

    Re: mailform.cfm


    Yes that is basically what I have now.

    I guess that seems to be the best situation

IMN logo majestic logo threadwatch logo seochat tools logo