-
flash & shopping carts
I've never used a shopping cart program before but I have a client that wants one integrated into their site. Is their a way to integrate this 100% with Flash w/o having to link to or use other straight-HTML pages?
Also, since I know nothing of shopping carts, I would like to hear some opinions on what the best ones to use are and if there are any free shopping cart systems that are good to use?
-
Senior Member
It should be possible and I have seen Flash shopping carts being offered. Just Google. You need serverside scripts of course. If you only need paypal it is pretty simple.
- The right of the People to create Flash movies shall not be infringed. -
-
could you give me a brief example of how to utilize PayPal w/ Flash? thx
-
You probably won't use PayPal with Flash directly. You'd use it with your server side script: Coldfusion, PHP, ASP, etc.
Although you might be able to make it work with URLVariables.
Code:
payPalVars:URLVariables = new URLVariables();
payPalVars.<some variable1> = <some value1>;
payPalVars.<some variable2> = <some value2>;
payPalVars.<some variable3> = <some value3>;
...
payPalRequest = new URLRequest("<some PayPal URL>");
payPalRequest.data = payPalVars;
payPalRequest.method = "POST";
payPalLoader = new URLLoader();
payPalLoader.load(payPalRequest);
payPalLoader.addEventListener(Event.COMPLETE, <some function to handle the return from PayPal>);
...
I've not tested that code, but it's a general idea of what you can do.
Hope this helps.
-
Senior Member
var url:String="https://www.paypal.com/cgi-bin/webscr";
var request:URLRequest=new URLRequest(url);
var paypal_lv:URLVariables=new URLVariables;
paypal_lv.add="1";
paypal_lv.cmd="_cart";
paypal_lv.business="ccccc@vvv.com";
paypal_lv.item_name="watch";
paypal_lv.amount="59.95";
paypal_lv.no_shipping="1";
paypal_lv.no_note="1";
paypal_lv.quantity="1";
paypal_lv.currency_code="USD";
paypal_lv.bn="PP-ShopCartBF";
request.data=paypal_lv;
request.method=URLRequestMethod.POST;
navigateToURL (request,"_blank");
- The right of the People to create Flash movies shall not be infringed. -
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|