Hello,

I have run into a situation where PayPals "add to cart" buttons are not going 
to work for me.  So I am looking for ideas on how to accomplish this.

The item I am trying to sell is a business card.  So I want the user to fill 
out Name, Email, Phone etc then add the item to their cart.

PayPal buttons can only take 3 options I will have about 10 things I want to 
track about the item added to the cart.

So I thought I would store the info to be printed on the business cart in a 
database and assign it a UID that I would pass to PayPal so I could look up 
what the user typed in.

Well, I have it so they fill out the form and enter their info then submit it 
to a CF page that enters the info into the database.  On this page I would like 
for the UID of the item to be added to the PayPal cart.

I have tried submitting the PayPal "add to cart" form with javascript with 
OnLoad in the Body tag, but I get pop-up warnings and don't want the user to 
have to worry about pop-ups.  I have tried using <cfhttp> to post the data, but 
the cart does not function right.  It is like the cart gets a new session and 
does not track the items in the cart right.  Must be a cookie thing or 
something.

Anyone have ideas on how to accomplish this?

Here is my cfhttp code.  Maybe I need to change something in this to keep the 
cart data?

<!--- display page to link to action page --->
<a href="PayPalTest.cfm?item_name=Business Card1&item_number=12345">card 1</a>
<a href="PayPalTest.cfm?item_name=Business Card2&item_number=12346">card 2</a>


<!--- action page that needs to submit to paypal --->
<cfhttp method="post" url="https://www.paypal.com/cgi-bin/webscr";>
        <cfhttpparam name="add" type="formfield" value="1">
        <cfhttpparam name="cmd" type="formfield" value="_cart">
        <cfhttpparam name="business" type="formfield" value="#yourPayPalEmail#">
        <cfhttpparam name="item_name" type="formfield" value="#URL.item_name#">
        <cfhttpparam name="item_number" type="formfield" 
value="#URL.item_number#">
        <cfhttpparam name="amount" type="formfield" value="25.00">
        <cfhttpparam name="shipping" type="formfield" value="10.00">
        <cfhttpparam name="no_shipping" type="formfield" value="2">
        <cfhttpparam name="currency_code" type="formfield" value="USD">
        <cfhttpparam name="weight" type="formfield" value="1">
        <cfhttpparam name="weight_unit" type="formfield" value="lbs">
        <cfhttpparam name="lc" type="formfield" value="US">
        <cfhttpparam name="bn" type="formfield" value="PP-ShopCartBF">
</cfhttp>

<cfoutput>
    #cfhttp.fileContent#
</cfoutput>


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to 
date
Get the Free Trial
http://ad.doubleclick.net/clk;203748912;27390454;j

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:309861
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to