Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Flash and Oscommerce Problem with PHP & Flash


Sinister-Racing

Recommended Posts

I currently have the HTML area contribution on my OSC site. within the HTML Area I have embedded a flash movie that shows all our products in a more dynamic way than OSC can. The problem I am running into is being able to click an "add to cart" button in the flash movie and have it add the product into the shopping cart of OSC. Thats the first step. The second step is to be able to have a combo box (drop down) in flash to choose an attribute (ie. color, flavor, size etc.etc.) and have both the product with the attribute get added to the cart in OSC. I have been through a ton of Flash tutorials and read a ton on communicating between Flash and PHP but nothing has worked so far. I am hoping to get this working with a little help, and hopefully a good flash/OSC contribution can come out of this.

check out the test site at: Test Site

Link to comment
Share on other sites

I have been going through actionscript forums as well as this one trying to figure out a solution to my problem. If any OSC gurus are ActionScript gurus I could really use some help with this issue.

 

Thanks in advance.

 

Haven't tried this contrib yet but may be worth a look if you haven't seen it yet.

 

http://www.oscommerce.com/forums/index.php?showtopic=108535&hl=

 

Hope this helps and keep us posted on your progress!

 

Iggy

Everything's funny but nothing's a joke...

Link to comment
Share on other sites

Thanks Iggy,

 

I have this installed. It keeps the session varaibles with using flash.

 

not exactly what i am looking for though

 

I posted this at actionscript.org.

 

I currently have a Flash Movie with lots of products. It works like a shopping site. In each of the products I have either a single "Add to Cart" button or both "Add to Cart" and a combo box that has product attributes that need to be added to the action script to transfer to the php. I have all the values and product_id from the MySQL database. I have what I think the php code is:

 

productinfo.php

 

<?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_image_submit('button_in_cart.gif', IMAGE_BUTTON_IN_CART); ?>

 

applicationtop.php

 

// Shopping cart actions

if (isset($HTTP_GET_VARS['action'])) {

// redirect the customer to a friendly cookie-must-be-enabled page if cookies are disabled

if ($session_started == false) {

tep_redirect(tep_href_link(FILENAME_COOKIE_USAGE));

}

 

if (DISPLAY_CART == 'true') {

$goto = FILENAME_SHOPPING_CART;

$parameters = array('action', 'cPath', 'products_id', 'pid');

} else {

$goto = basename($PHP_SELF);

if ($HTTP_GET_VARS['action'] == 'buy_now') {

$parameters = array('action', 'pid', 'products_id');

} else {

$parameters = array('action', 'pid');

}

}

 

I am not sure how to transfer the data of the combo box or just the "add to cart" button to the php page.

 

I dont necessarilly need to access the mysql database, because if there is a way to code the "add to cart" button to add product_id # whatever to the shopping cart I can hard code each product since we wont ever have more than 30-40 products. Any help would be very appreciated. I have been through countless forums to try and find an answer prior to posting w/o any luck.

 

Thanks in advance.

Link to comment
Share on other sites

  • 2 weeks later...

:D

Hello,

Maybe, I found a good solution but did'nt have time to test it or combine it with os commerce yet : Jgenerator ;

 

A web server production application (written in Java language) that can dynamically

combine text, graphics, and sound to build rich Flash content.

Website : http://www.jzox.com

 

 

Good luck and give us your feedback.

:blush:

Link to comment
Share on other sites

:D

Hello,

Maybe, I found a good solution but did'nt have time to test it or combine it with os commerce yet : Jgenerator ;

 

A web server production application (written in Java language) that can dynamically

combine text, graphics, and sound to build rich Flash content.

Website : <a href='http://www.jzox.com' target='_blank'>http://www.jzox.com</a>

Good luck and give us your feedback.

:blush:

 

 

Didn't really take the time to look over this...but it sounds like you're using an application server to develop Flash movies using a programming language (other than actionscript). If this is the case, why not just use PHP?

 

http://us2.php.net/manual/en/ref.swf.php

Chris Sullivan

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...