Products     Magento Extension     PCI-Shopping-Carts     Templates       CRELoaded     WordPress Modules     osCommerce Modules       osCommerce Addons       osCommerce Features       osCommerce Management       Payment Modules     CRELoaded Modules       CRE Loaded Addons       CRE Loaded Features       CRE Loaded Management       Payment Modules       CRELoaded Services
Free Stuff
Customization
Templates
Compare Products
You have no items to compare.
Affiliate Info
Affiliate Program FAQ
Affiliate Log In
Recent Orders
Hot Keywords: Order Notification, Order Search, Coupon, Flash Board, Compare, Floating Message, Tracking, Moneris, RSS, Visitor Filter

  Dynamic force attribute selection

The following osCommerce contribution is a free Opensource code originated from official osCommerce website and provided for your reference only, you may download the original contribution file(s) and install it on your own; or you may request a Paid Installation Service from Agents Of Power; Agents Of Power does the "AS IS" installation on your website, we do not guarantee it will work properly on your website. Extra Paid service is available for repairing the problem from the original contribution or from your website.
This fix is for "Ajax Buy Now" 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)
+ improved options as images code
+ cleaned up install docs
   Posted on: 09/24/2008     See contribution details Request Installation with Paid service