Community Add-Ons

Maintainers: Medreces
Add file to this package
Top » Features

Ajax Buy Now
for osCommerce Online Merchant v2.2

All simple: Buy Now without reload page

Legend:  Download   Report
Expand All / Collapse All
This fix is for "Dynamic_force_attribute_selection" Users ! faaliyet 1 Apr 2009  

This fix is for "Dynamic_force_attribute_selection" Users !
--------------------------------------------------------------
This is a small change but works correctly for ajax buy now users including me.
Until users don't make this change with Dynamic_force_attribute_selection , ajax buy now will not work correctly.
As I seen on forum, one of the problems for users is to not able to find bug.(for exp. user jake seymour's web-pages)
This bug becomes to users of using Dynamic_force_attribute_selection contribution
Users do not realize that so this change was needed.
---------------------------------------------------------------------------------------------------------------------------------------

********************************************

1)Open products_info.php file:

Find:

<td width="100%" valign="top"><?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product'), 'post', 'onSubmit="return validate(this);"'); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">

And Replace With:

<td width="100%" valign="top"><?php echo tep_draw_form('cart_quantity', tep_href_link(FILENAME_PRODUCT_INFO, tep_get_all_get_params(array('action')) . 'action=add_product')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">

********************************************

2)Open the ajax_sc.js file.

Find:

function doAddProduct(form) {


And Replace With:

function doAddProduct(form) {

var attributes_force=validate();
if(attributes_force==false) return false;

********************************************

3)On v1.6 the only small change is "function validate()", do not change it with "function validate(cart_quantity)".
If you do change it, it will not work.

********************************************

That's all.
Seyhun Cavus(faaliyet)

Fix position of loading image createvideo 5 Mar 2008  
Fix places folder classes Medreces 27 Mar 2006  
New release Medreces 26 Mar 2006  
v 1.1 Medreces 18 Mar 2006  
Ajax Buy Now Medreces 16 Mar 2006