dculley Posted May 31, 2015 Share Posted May 31, 2015 Adding a back to top button was great idea. But I can not find one that is "BACK" to last page for bootstrap. Is there one? Also on the "What is my cart" and "Checkout" there is no "Continue to shop" button. So the customer can go back and select more items. How can this be added? Thank you. Link to comment Share on other sites More sharing options...
Mort-lemur Posted June 4, 2015 Share Posted June 4, 2015 this has been missed off all versions of OSC - you have to add it manually: http://www.oscommerce.com/forums/topic/383073-continue-shopping-button-in-shopping-cart/ Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members. Link to comment Share on other sites More sharing options...
dculley Posted June 5, 2015 Author Share Posted June 5, 2015 @@Mort-lemur Thank you for the help. I will give it a try this weekend. Link to comment Share on other sites More sharing options...
dculley Posted June 6, 2015 Author Share Posted June 6, 2015 @@Mort-lemur You put me in the right direction. I'm running under Bootstrap. So the link helped. But I came up with this bit of code that seems to work under BS. <div class="buttonSet"> <div class="text-right"><?php echo tep_draw_button(IMAGE_BUTTON_CONTINUE_SHOPPING, 'glyphicon glyphicon-chevron-right', tep_href_link(FILENAME_DEFAULT), 'primary', NULL, 'btn-success'); ?></div> <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> Thanks for helping. Link to comment Share on other sites More sharing options...
♥14steve14 Posted June 7, 2015 Share Posted June 7, 2015 Rather than stack the buttons on a large screen try something like <div class="buttonSet"> <div class="col-xs-6"><?php echo tep_draw_button(IMAGE_BUTTON_CONTINUE_SHOPPING, 'glyphicon glyphicon-chevron-right', tep_href_link(FILENAME_DEFAULT), 'primary', NULL, 'btn-success'); ?></div> <div class="col-xs-6 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> REMEMBER BACKUP, BACKUP AND BACKUP Link to comment Share on other sites More sharing options...
dculley Posted June 7, 2015 Author Share Posted June 7, 2015 @@14steve14 Thanks - I was hoping that someone would help with that. I'm not a programer and didn't know just how to it. Link to comment Share on other sites More sharing options...
♥14steve14 Posted June 7, 2015 Share Posted June 7, 2015 Been playing with this a bit more today to get back to the page where the item was added to the cart. Now I have <div class="buttonSet"> <?php $back = sizeof($navigation->path)-2; if (isset($navigation->path[$back])) { echo '<div class="col-xs-6">' . tep_draw_button(IMAGE_BUTTON_CONTINUE_SHOPPING, 'glyphicon-chevron-left', tep_href_link($navigation->path[$back]['page'], tep_array_to_string($navigation->path[$back]['get'], array('action')), $navigation->path[$back]['mode']), 'primary', NULL, 'btn-success') . '</div>'; } ?> <div class="col-xs-6 text-right"><?php echo tep_draw_button(IMAGE_BUTTON_CHECKOUT, 'glyphicon-chevron-left', tep_href_link(FILENAME_CHECKOUT_SHIPPING, '', 'SSL'), 'primary', NULL, 'btn-success'); ?> </div> </div> Which does seem to work, but may need more testing. REMEMBER BACKUP, BACKUP AND BACKUP Link to comment Share on other sites More sharing options...
dculley Posted June 7, 2015 Author Share Posted June 7, 2015 @@14steve14 It seems to work great. Think you have it. :) Thank you Link to comment Share on other sites More sharing options...
dculley Posted June 24, 2015 Author Share Posted June 24, 2015 Please keep in mind that I'm not a programer and I make what attempts I can to achieve as close as I can to get to what I need. But hope that this will help and maybe someone will help with a better line up of the three buttons. To add "<BACK" button to product_info.php with the following code. <div class="buttonSet row"> <div class="col-xs-6 text-left"> <?php $back = sizeof($navigation->path)-2; if (isset($navigation->path[$back])) { echo tep_draw_button(IMAGE_BUTTON_BACK, 'glyphicon glyphicon-chevron-left', tep_href_link($navigation->path[$back]['page'], tep_array_to_string($navigation->path[$back]['get'], array('action')), $navigation->path[$back]['mode'])); } ?> </div> <div class="col-xs-6 text-center"><?php echo tep_draw_button(IMAGE_BUTTON_REVIEWS . (($reviews['count'] > 0) ? ' (' . $reviews['count'] . ')' : ''), 'glyphicon glyphicon-comment', tep_href_link(FILENAME_PRODUCT_REVIEWS, tep_get_all_get_params())); ?></div> <div class="col-xs-6 text-right"><?php echo tep_draw_hidden_field('products_id', $product_info['products_id']) . tep_draw_button(IMAGE_BUTTON_IN_CART, 'glyphicon glyphicon-shopping-cart', null, 'primary', null, 'btn-success'); ?></div> </div> Have fun. Link to comment Share on other sites More sharing options...
trier Posted June 24, 2015 Share Posted June 24, 2015 Hi, More general than totally specific to this, is there any reason to not use javascript for ‘back’ buttons (shopping cart, product info. etc.)? <div class="col-xs-6"> <?php echo tep_draw_button(IMAGE_BUTTON_BACK, 'glyphicon glyphicon-chevron-left', 'javascript:history.go(-1)'); ?> </div> In the past I assumed it was because dependence on javascript was frowned upon? Current sites seem to be very dependent on javascript, is it now acceptable or still inadvisable? Link to comment Share on other sites More sharing options...
Sam-AUST Posted March 16, 2016 Share Posted March 16, 2016 Can anyone point in the direction of exactly where this code needs to be added? (Also which file?) Link to comment Share on other sites More sharing options...
Sam-AUST Posted March 16, 2016 Share Posted March 16, 2016 Scratch that last question of mine - I just used 14Steve14's code with one change, it looks like the word glyphicon was left out and the buttons were odd looking because the chevron was then missing. I changed the direction of the Chevrons so they make more sense (to me, they should be back and forward). With one digit change, you can have the customer return to the CATEGORY they were in instead of looking at the product they were last on. This is what I used: <div class="buttonSet"> <?php $back = sizeof($navigation->path)-3; if (isset($navigation->path[$back])) { echo '<div class="col-xs-6">' . tep_draw_button(IMAGE_BUTTON_CONTINUE_SHOPPING, 'glyphicon glyphicon-chevron-left', tep_href_link($navigation->path[$back]['page'], tep_array_to_string($navigation->path[$back]['get'], array('action')), $navigation->path[$back]['mode']), 'primary', NULL, 'btn-success') . '</div>'; } ?> <div class="col-xs-6 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> Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.