ActionScript 2.0 :: Shop Cart Functionality With Array?

Dec 1, 2004

How exactly do I emulate a shopping cart? I don't want to actually send any info, I just want to have the person click on something they want, then later be able to review the items "collected".My prof "showed" us how and this is what I have (but it doesn't work).

PHP Code:

addToCart.onPress = function() {
descSound.stop();
_global.collect_array.push("pieceThumb");
trace(_global.collect_array);

[code]....

(I added the _global. thinking if it was a global variable, it might work. It didn't work before either, when the variable was just declared in the same AS window as the above function.)

addToCart is the instance name of the movie clip you click on to add the item to the cart. mainCont.cartContent.cartItems is the path to the movie clip where I want the items to show up.

pieceThumb is the name of the movie clip I want added to the cart (the name of the clip, not the instance name). Pushing this to the array works, as when it is traced, the word "pieceThumb" shows up.

PHP Code:

cartLink.onPress = function() {
_root.mainCont.gotoAndStop("shopCart");
//haltActions.apply(exitLink);
descSound.stop();
_root.mainCont.cartContent.cartItems.attachMovie(_global.collect_array[0], _global.currentshown, 1000, {_x:-200, _y:10});


cartLink is the link to the shopping cart, so that when you click on it, this function is called. I'm assuming it makes the items show up, but nothing appears. So I'm assuming this is what's broken.

View 1 Replies


Similar Posts:


IDE :: Trying To Add Cart Like Functionality To Site

Sep 18, 2008

I built my dynamic gallery using AS 2.0 and XML, now, what I want to do is add a shopping cart of sorts. All I really want to do, is have the person on the other end be able to click an image and then be able to select a size or sizes and quantity, at the end it shows them their selections (text not images) and then they hit send and it sends me an email. That's it....

View 6 Replies

ActionScript 3.0 :: Output Cart Array Into Dynamic TextField

Jan 14, 2010

I am trying to output my cart array into a dynamic text field and format it. After the user clicks 'add' I am using...

ActionScript Code:
//insert product data into cart array
details.push([ItemCode,ItemColor,SecondColor,Price,Description]);
//reset text box
var textoutput:String = "";
//loop through contents
[Code] .....

How can I format each value? Ineed some sort of neat table style output but how to do this in flash.

View 3 Replies

ActionScript 2.0 :: Array Functionality Inside Classes?

Aug 18, 2005

I have 4 defined private arrays defined in the constructor of my class.Later down in one of the methods, im trying to push() variables into these arrays, but nothing seems to happen. I tried using this.arrayname.push(), but that doesn't seem to work either.do i need to manually push them by this.arrayname[arrayname.length+1] = "";

View 3 Replies

CS3 XML Flash Paypal Shop

Nov 2, 2009

I need to add a script to my code..."subtotal + shipping $11.00 = total".

View 1 Replies

ActionScript 3.0 :: XML Flash Paypal Shop?

Oct 28, 2009

I need to add a script to my code ... "subtotal + shipping $11.00 = Total"

cartRow.txt_St.text=currencySymbol+Number+carData[arrItems].SubTotal+".00";

View 0 Replies

ActionScript 3.0 :: Creating Object Hash While Retaining Array Functionality

Jan 25, 2010

Ever needed to create an object hash, yet wanted to retain some array functionality such as .length, and getItemAt()? Well I wrote a handy little utility class, using Proxy, that does so. Simply use it in place of a generic Object, and it will maintain a count of it's properties, as well as allow you to reference any index you need [URL].

View 0 Replies

ActionScript 2.0 :: Setting Up A Webisite With An Online Shop?

Apr 25, 2006

How was this site done www.shopcomposition.com I am looking at setting up a webisite with an online shop and I came across this and it's amazing. How hard would it be to pull somthing like that off and what would be involved in making it.

View 14 Replies

ActionScript 2.0 :: Embed The New Paypallabs Shop Feature Into An Swf?

Jan 20, 2008

how to embed the new paypallabs shop feature into an swf? This is the code generate from paypallabs:

[Code]...

View 9 Replies

Media Server :: RTMP Based HTTP DVR Functionality And HLS Based IOS Functionality?

Jan 20, 2012

I want to use RTMP based HTTP DVR functionality and HLS based IOS functionality, So I need to know how to MPP from my existing DVR app to the livepkgr app so that the stream being recorded at the DVR app can be used by the Flash and Stream MPP over to livepkgr app and can be used by the IOS HLS.

View 1 Replies

Modifying Flash Shopping Cart

Apr 12, 2009

modify an existing flash shopping cart I purchased from Flashden.net (link). The cart uses two XML files to pull in data and to configure most of the data settings. I need help with one thing: I'm using this cart on a sunglasses shopping site and I need to configure the optional sunglasses to be clickable so they can be added to the cart. I know I need to modify both the flash .fla and the xml file so I've included the code for both below. Here's a link to the website I'm trying to re-configure. The section I need to edit has the optional sunglasses on the right-hand side of the main photo.Here's the first xml file that does some of the basic settings. This file is called settings.xml.[code]I made an attachment for the actionscript code called actionscript.txt that needs to be modified. All I need to do is figure out a way to make the optional images clickable so they can be added to the main cart. We can also just create a button that says add to cart next to each sunglass option. Either way works for me. I'm even willing to compensate the person who can help me come up with a workable solution.

View 3 Replies

ActionScript 2.0 :: Simply Xml Shopping Cart

Jan 13, 2010

i was trying to find simple code of xml shopping cart i.e it's in AS3 or AS2 it's should be simple & run as different level?i mean if i need to import different swf file or using _root.shopping_cart.URL...

View 1 Replies

Add A Delete Item Option To A Cart?

Jan 18, 2010

im trying to add a delete item option to a cart, currently i have....

Code:

//populate cart
details.push([vItemCode,vBaseColor,vSecondColor,vThirdColor]);
//loop through cart and output it into the text field

[code]....

how could i add a delete button to remove certain items?

View 3 Replies

ActionScript 3.0 :: Delete Option On Cart?

Jan 19, 2010

I have my cart data stored using...

ActionScript Code:
details.push([ItemCode,ItemColour,ItemName,ItemCost]);

I then output this cart on my movie file by using...

ActionScript Code:
var test:String = "";
//loop through cart and output it into the text field
for (i = 0; i < details.length; i++)[code]....

the cart items are outputted into a dynamic text field. The problem is that next to each item i need to add a delete button that deletes the specific row that it is placed upon.i know i could use splice to remove the item from the array, but the problem is getting to this stage first.

View 1 Replies

ActionScript 2.0 :: [CS3] Add Multiple Items To A Paypal Cart?

May 1, 2008

I'm not sure whether this is right place to put this. I've done a search but nothing is helping unfortunately and I was hoping someone on here had done something like this.I am selecting an amount of an item from a drop down list in flash and assigning it to a global value. I then want to put that global value as the number of items in the code.My code is:

PHP Code:
panel.dropdownpink.addtocart.onRelease = function()
{

[code].....

View 9 Replies

ActionScript 3.0 :: Loading Image Viewer Via XML Into Cart

Nov 13, 2009

I am trying to load this little image viewer via xml into my as3 shopping cart. [URL] I have resized it larger but that shouldn't matter. I have another swf that I created quickly and load it the same way via xml and it opens perfectly in the center of the cart movie, the other one is way left and high for some reason.

Here is the code for it:
stage.scaleMode = StageScaleMode.NO_SCALE;
// import tween
import fl.transitions.Tween;
import fl.transitions.easing.*;
[Code] .....

View 3 Replies

ActionScript 3.0 :: Insert Add To Cart Buttons To Webpage?

Feb 4, 2010

I'm trying to insert paypal ADD TO CART buttons to my webpage. How do I use the paypal HTML codes in my webpage? How to set things up? Show me the script I sould use. What about the Paypal generated HTML code?

View 6 Replies

ActionScript 3.0 :: Function With The PayPals Add To Cart Button?

Feb 23, 2010

This is the script I'm using in my web page. How to amend this to function with the PayPals Add to Cart button? I have searched for a solution in the PayPal website... but was not successful.
 
I thought of posting it here so I can get your help in fixing my website to make the add to cart button working.

[Code]...

View 2 Replies

ActionScript 3.0 :: If / Else / Switch Statement For A Shopping Cart

Feb 24, 2011

I am trying to create a Flash styled shopping cart to integrate into my website. When the "Add to Cart" button is clicked, i am displaying the corresponding text down the side of the stage. However I need a "Total Price" Dynamic text field to display the Total price of all items clicked!I am new to flash and it's proving very difficult to me, as the only way i could think of doing this is creating Boolean variables with all the items and if "add to cart" had been clicked Boolean = True... But how do I code the addition of prices? and cater for all the variations that are possible?

View 15 Replies

ActionScript 2.0 :: Build A Shopping Cart In Flash?

Feb 10, 2009

i want to build a shopping cart in flash, but i dont know how to do.actually i have a gallery i.e. [URL]now what i want to do is that to put check boxes under each thumbnail,after selecting that check box that product should be added to the cart.

View 2 Replies

ActionScript 2.0 :: XML Gallery With Paypal Add To Cart Button?

Feb 17, 2009

I have an xml generated AS 2.0 gallery which i also would like to have a paypal 'add to cart' button. This is my first venture into e-commerce,so not exactly sure how these would connect up.I am using the free cart provided by paypal and can generate the <form> buttons for 'add to cart' and 'view cart'. In HTML this is fine, however, i need the buttons to work from the xml.Is this something with Xform? If so, is there a nice intro to that?

View 0 Replies

ActionScript 3.0 :: Submitting Cart Data To PHP Page

Feb 10, 2010

im trying to pass my AS3 array to a sendmail.php page to send the user details of the order (the arrays contents) my array is called 'details'. The method im using is a bit unreliable and im wondering if theres a more effective way of doing this? Im currently using....

ActionScript Code:
//submit button
function cartsubmit(e:Event):void {

[Code].....

View 1 Replies

ActionScript 3.0 :: Remove From Cart Paypal Button?

Apr 2, 2010

I've made a paypal shopping cart intergrated with flash, where customers can add items to the paypal checkout, then view it. But I'd also like to know the code for removing items on the paypal checkout page, but from within the swf.

View 2 Replies

ActionScript 3.0 :: Send Vars From Cart To Mail?

Aug 3, 2010

When you press the button you go to a paypal-account, but I don't want to work with paypal.Instead I would like to receive all the info from the shopping cart (ordered items, price) mailed to me. So people can order without paying ahead

ActionScript Code:
function click_PayBtn(e:MouseEvent):void {
//_Create a new URLVariables variabes

[code].....

View 4 Replies

ActionScript 2.0 :: Build A Thorough Shopping Cart In Flash?

May 31, 2002

how to build a thorough shopping cart in Flash, with a checkout button and everything? And/or could some provide a fla. that has a checkout button and everything?

View 6 Replies

ActionScript 3.0 :: Flash Shopping Cart By Dreamline Studio?

Mar 4, 2008

has anyone ever used it or have experience with it? It seems a decent price and good functionality, but if someone has experience with it that gives me a lot more insightlso, it's designed w/ AS2 and says it can be used easily w/ AS3 via Loader & LocalConnection, but I've had problems in the past w/ LocalConnection & AVM1Movie's.

View 3 Replies

ActionScript 2.0 :: Creating Shopping Cart Feature In Flash

Oct 20, 2009

I am creating a shopping cart feature within flash using as2 using this tut [URL]. I have created the as file and there are no errors but when it can to adding the first part of code to go into the actual flash file I get this error

The class or the interface 'com.ahfx.
Product could not be loaded(source)
var myProduct = new Product();

The code added on the first frame of the flash file
import com.ahfx.Product;
var myProduct = new Product();
myProduct.setQuantity(3);
myProduct.setPrice(2.99);
myProduct.setDesc("Teddy Bear");
trace(myProduct.getDesc());
trace(myProduct.getPrice());
trace(myProduct.getQuantity());
trace(myProduct.getTotal());

View 1 Replies

ActionScript 2.0 :: Adding Annother Field To The View Cart?

Apr 1, 2010

Im using Adobe flash cs3 action scrpit 2.0 i think : You can see o working model of what I have to work with here http:[url]....If you ad somthing to cart and then click view cart youll see the fields it provides Item name, subtotal, qty, and total of item.Im trying to add annother field there called "size".Its all in action script as far as i can tell the action scripts that i think need to be modified are Cart.as

Actionscript Code:[code]...........

The cartlistitems.as i added the size in all fields and it returns no errors .

View 1 Replies

Professional :: Shopping Cart/store Built In Flash?

Mar 16, 2010

I have a shopping cart/store built in flash. All the pages are built in html. My problem is that when you navigate to another page the shopping cart empties. The cart is .xml based. I didn't think of this at the beggining. Does anyone have a suggestion? The link to the site is below.

View 2 Replies

Professional :: Set Up A Button To Automatically Add Items To A Shopping Cart?

Jan 7, 2011

ok, same project i've been working on, new criteria. here's the summary of the project.we are making a digital catalog, in our print catalog we have diagrams but in the digital version i am using flash to link parts of those diagrams to the page with that merchandiseeverything is getting worked out ok.now i have been given some more requirements, myboss wants me to add an "add to cart" button so they can automatically add it to their cart instead of linking to our website and adding it there.

View 4 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved