Jump to content

Search the Community

Showing results for tags 'shopping_cart.php'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • News and Announcements
    • News and Announcements
  • osCommerce Online Merchant v2.x
    • General Support
    • osCommerce Online Merchant Community Bootstrap Edition
    • Add-Ons
  • Development
  • General
    • General Discussions
    • Live Shop Reviews
    • Security
    • Developer Feedback
  • Club osC's Announcements
  • PayPal's Announcements
  • Sage Pay's Announcements
  • Solomono - new level osCommerce templates's Announcements
  • German Community's OSCOM v2.x
  • German Community's Allgemein

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Real Name


Location


Interests


Website

Found 1 result

  1. I needed to change the appearance of the out of stock message inside the shopping_cart.php to save some space when viewing the shop in sm or xs mode so i came up with this tiny little change which i would like to share. ============================================================================= what did i do: removed *** and replaced with background color for better and easier viewing. deactivated checkout button inside the shopping_cart.php if allow checkout is set to false changed files: general.php shopping_cart.php includes/languages/english/shopping_cart.php ============================================================================= inside the general.php *(you can change the color code of the background here and don't forget to adjust the message text to your color.) find this code around line 139 if ($stock_left < 0) { $out_of_stock = '<span class="markProductOutOfStock">' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . '</span>'; } replace with if ($stock_left < 0) { //$out_of_stock = '<span class="markProductOutOfStock">' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . '</span>'; $out_of_stock = '<tr style="background:#ffffb1;">'; } inside the shopping_cart.php find this code around line 80 $products_name .= '<tr>'; replace with if (STOCK_CHECK == 'true') { $stock_check = tep_check_stock($products[$i]['id'], $products[$i]['quantity']); if (tep_not_null($stock_check)) { $any_out_of_stock = 1; $products_name .= $stock_check; } else { $products_name .= '<tr>'; } } //$products_name .= '<tr>'; find this code around line 85 if (STOCK_CHECK == 'true') { $stock_check = tep_check_stock($products[$i]['id'], $products[$i]['quantity']); if (tep_not_null($stock_check)) { $any_out_of_stock = 1; $products_name .= $stock_check; } } and replace with /* if (STOCK_CHECK == 'true') { $stock_check = tep_check_stock($products[$i]['id'], $products[$i]['quantity']); if (tep_not_null($stock_check)) { $any_out_of_stock = 1; $products_name .= $stock_check; } } */ find this code around line 136 <div class="buttonSet"> <div class="text-right"><?php echo tep_draw_button(IMAGE_BUTTON_CHECKOUT, 'glyphicon glyphicon-chevron-right', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'), 'primary', NULL, 'btn-success'); ?></div> </div> and replace with <div class="buttonSet"> <?php if ($any_out_of_stock == 1) { echo '<div class="text-right" style="cursor:not-allowed;">' . tep_draw_button(IMAGE_BUTTON_CHECKOUT, 'glyphicon glyphicon-chevron-right', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'), 'primary', NULL, 'btn-success disabled') . '</div>'; } else { echo '<div class="text-right">' . tep_draw_button(IMAGE_BUTTON_CHECKOUT, 'glyphicon glyphicon-chevron-right', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'), 'primary', NULL, 'btn-success') . '</div>'; } ?> </div> inside the includes/languages/english/shopping_cart.php *(if color is changed text needs to be adjusted here, text for sample color is yellow) find this code around line 19 define('OUT_OF_STOCK_CANT_CHECKOUT', 'Products marked with ' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . ' dont exist in desired quantity in our stock.<br />Please alter the quantity of products marked with (' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . '), Thank you'); define('OUT_OF_STOCK_CAN_CHECKOUT', 'Products marked with ' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . ' dont exist in desired quantity in our stock.<br />You can buy them anyway and check the quantity we have in stock for immediate deliver in the checkout process.'); replace with //define('OUT_OF_STOCK_CANT_CHECKOUT', 'Products marked with ' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . ' dont exist in desired quantity in our stock.<br />Please alter the quantity of products marked with (' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . '), Thank you'); //define('OUT_OF_STOCK_CAN_CHECKOUT', 'Products marked with ' . STOCK_MARK_PRODUCT_OUT_OF_STOCK . ' dont exist in desired quantity in our stock.<br />You can buy them anyway and check the quantity we have in stock for immediate deliver in the checkout process.'); define('OUT_OF_STOCK_CANT_CHECKOUT', 'Products marked in <u>yellow</u> don\'t exist in desired quantity in our stock.<br />Please alter the quantity of products marked in yellow, Thank you'); define('OUT_OF_STOCK_CAN_CHECKOUT', 'Products marked in <u>yellow</u> don\'t exist in desired quantity in our stock.<br />You can buy them anyway and check the quantity we have in stock for immediate delivery in the checkout process.'); That's it.
×