EasyCFM.COM ColdFusion Forums / ColdFusion Applications / Passing parameters to merchant account

   Reply to Discussion | New Discussion << previous || next >> 
Posted By Discussion Topic: Passing parameters to merchant account

book mark this topic Printer-friendly Version  send this discussion to a friend  new posts last

azhavee
09-25-2003 @ 5:12 PM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
New Member
Posts: 6
Joined: Sep 2003

I spent almost 2 weeks designing a shopping cart in coldfusion, but now that I have a merchant account, they have their own shopping cart that I can customize, so I tried to use theirs, but the result was less than satisfactory. So at this point I am trying to use my own shopping cart and send them the variables trough URL parameters. And here is when my problem begins because I am not sure how to do so.
For the services selection section I tried using the <cfhttpparam> tag , then after that I guess they will be redirected to page where they give their credit card information, and I guess all of that must be sent to them through URL parameters, am I right? Should I use the<cfhttpparam> tag? Thanx

This is the services selection part
<cfform action="servicesconfirmt.cfm" method="post" target="_self" >
          <p><font color="#666699" face="Arial, Helvetica, sans-serif"><strong>1.</strong>
            I want to receive charts on Financial Ratios beginning with our most
            recent period: </font></p>
          <p>
            <label>
            <cfinput name="RadioGroup1" type="radio" value="1" required="yes" message="Please select your most recent period">
            <font color="#666699" face="Arial, Helvetica, sans-serif">One month
            - $9</font></label>
            <br>
            <label>
            <cfinput type="radio" name="RadioGroup1" value="3" required="Yes" message="Please select your most recent period">
            <font color="#666699" face="Arial, Helvetica, sans-serif">Three months
            - $19</font></label>
            <br>
            <label>
            <cfinput name="RadioGroup1" type="radio" value="12" required="yes" message="Please select your most recent period">
            <font color="#666699" face="Arial, Helvetica, sans-serif">Twelve months
            - $49</font></label>
          strong>2.
            </strong>I want to begin with some previous months to start building
            a historical basis (optional):</font></p>
          <p><font color="#666699" face="Arial, Helvetica, sans-serif">How many
            months
            <cfinput name="Product_Id1"  type="text" id="Product_Id1" size="12" required="yes" message="Please enter a number from 0 to any number">
            at $9.00 per month </font><input type="submit" name="Submit" value="Submit"></cfform> This is the action page....<cfhttp  method="post"
url ="https://www.2checkout.com/cgi-bin/sbuyers/purchase.2c?sid=90547&Product_id&quantity&demo=Y">

<cfhttpparam  name="services"type="formfield" value="Form.Product_Id1">
</cfhttp>
<cfif IsDefined("Form.RadioGroup1")>
<cfif form.RadioGroup1 EQ 1>
<cfset myValue = 9>
<cfelseif Form.RadioGroup1 EQ 3>
<cfset myValue = 19>
<cfelseif Form.RadioGroup1 EQ 12>
<cfset myValue = 49>
<cfelse>
<cfset myValue = 0>
</cfif>
</cfif>
<cfparam name="form.checkbox3" default="no">
<cfparam name= "form.checkbox4" default="no">
<cfset result= myValue + (form.Product_ID1 * 9) >
<cfparam name='RadioGroup1' default=''>
<cfparam name='Product_Id1' default=''>
Please
          verify the information that you entered:</strong></font></p>
        <ul>
          <li><font color="#666699" face="Arial, Helvetica, sans-serif"> I want
            to receive charts on Financial Ratios beginning with our most recent
            period of:<u><cfoutput>#form.RadioGroup1#</cfoutput></u> month(s).</font></li>
          <cfif form.textfield2 GT 1 >
            <li><font color="#666699" face="Arial, Helvetica, sans-serif"> I want
              to begin with the past <cfoutput>#form.Product_Id1#</cfoutput>months to start building a historical basis. </font></li>
            <cfelseif form.textfield2 LT 1>
            <li><font color="#666699" face="Arial, Helvetica, sans-serif">I dont
              want to begin with the past months.</font> </li>
          </cfif>
        </ul>
        <p><strong><font color="#666699" face="Arial, Helvetica, sans-serif">All
          of these for a total of $<cfoutput>#result#</cfoutput>.</font></strong></p>
        <p>&nbsp;</p>

apletfx
09-25-2003 @ 11:06 PM
Reply
Edit
Profile
Send P.M.
My Gravatar!
Powered by Gravatar
Moderator
Posts: 607
Joined: Nov 2002

First off, Never send credit card info in a url, it's very dangerous.

With 2 checkout.com, all you need to do is pass the final price and your id number. 2checkout.com will handle all the credit card processing, and billing. they do offer a pass back routine that return the user to your site after credit processing is complete. It will have an approved value of yes or no, depending on if their credit card was accepeted or declined. 2checkout has all the returned values posted on their website. I think you have to log in to see it.

hope this helps

Mark Aplet
http://www.pixeljunkie.org


Website Designed and Developed by Pablo Varando.