Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Continue Shopping

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions
 
Thread Tools Search this Thread
  #1  
Old 12-04-2002, 12:41 PM
 
Kanyon71 Kanyon71 is offline
 

Senior Member
  
Join Date: Oct 2002
Location: Lutz, FL
Posts: 128
 

Default Continue Shopping

I did a search on every way I could think of but didn't find anything. I need to add a button in the catalog that says Continue Shopping after you have added items to your cart. Any ideas on how I can do this? I want it to take you back to where you where last shopping.
Reply With Quote
  #2  
Old 12-04-2002, 01:54 PM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

Theres a couple of things that you could do ...

Either unset Redirect customer to cart in general settings to stop the customer giong to the view catr page when they add a product

or

create a new button file called continue_shopping.tpl that contains the following code.


the (-2) part is how many steps you wish to take them backwards. (-1) would take them back to the last product detail page or (-2) would move them back 2 steps and thus go to the products list page.

Now where ever you want that to appear just add this code ...

Quote:
{include file="buttons/continue_shopping.tpl"}

Its not perfect but it does the job most of the time
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #3  
Old 12-05-2002, 04:20 AM
 
Cefko Cefko is offline
 

Advanced Member
  
Join Date: Nov 2002
Posts: 69
 

Default

Which is best practice? To send them to cart when they "add" or not to send them to cart?
__________________
X-cart version 4.1.7
Apache/2.0.52 (CentOS)
My SQL 5.0.58
PHP Version 5.1.6
Reply With Quote
  #4  
Old 12-05-2002, 04:24 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

up to you I suppose but I reckon its best to show them the cart after choosing a product just so that they know its been added and dont try and add it again
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #5  
Old 12-05-2002, 05:55 AM
 
Kanyon71 Kanyon71 is offline
 

Senior Member
  
Join Date: Oct 2002
Location: Lutz, FL
Posts: 128
 

Default

Ok I am feeling pretty stupid about right now, where do I need to put the code to call this? I am not sure which file is getting called to display what you are seeing after adding a product.
Reply With Quote
  #6  
Old 12-05-2002, 06:00 AM
  shan's Avatar 
shan shan is offline
 

X-Guru
  
Join Date: Sep 2002
Location: Birmingham, UK
Posts: 6,163
 

Default

if you switch on the debug console in your admin area you should see what tpl files are being loaded for each page.

Im pretty sure that want to be looking at cart.tpl though
__________________
Looking for a reliable X-cart host ?
You wont go wrong with either of these.

EWD Hosting
Hands On Hosting
Reply With Quote
  #7  
Old 12-05-2002, 06:43 AM
 
Kanyon71 Kanyon71 is offline
 

Senior Member
  
Join Date: Oct 2002
Location: Lutz, FL
Posts: 128
 

Default

Yeah it was, I found it after a little digging, had a brain lock when I was typing.
Reply With Quote
  #8  
Old 03-30-2004, 12:12 AM
 
parmar parmar is offline
 

eXpert
  
Join Date: Apr 2003
Location: London, UK
Posts: 286
 

Default

Ok, this is a very old post I'm replying to, but I'm thinking of adding "continue shopping" button at the View Cart and Checkout stage.

I have tried to work with by disabling "redirect customer to cart" and although I have three "view Cart" and "checkout" links on our pages, customers seems to be getting confused once they add an item to cart, and when the shop doesn't direct them to a cart iteself after adding that item. I find that surprising but hey, customers are alway right.

What I need to do is redirect customers to the Category they were at and not direct them always to the last page they were at. Sometimes a customer will choose to see a product page and than add that product to a cart, or they may add an item using "Buy now" from within the Catagory pages. (-1) setting will redirect them to the last page they were at, which will be fine if they were on Catagory page, but if they added an item at Product page this will redirect them back to that product page. I wish them to be redirected to the Catagory page always. How do I go on about implimenting this?
__________________
--------------------
Sandip


x-cart version 5.4.X, hosted on X-Cart server/
Reply With Quote
  #9  
Old 04-30-2004, 04:59 PM
 
GM GM is offline
 

eXpert
  
Join Date: Mar 2004
Location: Canada
Posts: 293
 

Default

TRY THIS...

1:) Create a new button file in /buttons called

continue_shopping.tpl that contains the following code:

Code:
{include file="buttons/button.tpl" button_title=$lng.lbl_continue_shop}

2:) In Admin go to "languages" edit languages and create a new

entry called "lbl_continue_shop" (without the quotes)

Now in cart.tpl or where ever you want the button to appear just add this

code:


DONE!
__________________
v. 4.0.14 (GM Style)
O.S. Linux
Build Your Own Diamond Ring
Reply With Quote
  #10  
Old 05-24-2004, 05:51 AM
 
longhorn180 longhorn180 is offline
 

Senior Member
  
Join Date: Apr 2004
Location: Richmond, Virginia
Posts: 187
 

Default

I could'nt get these methods to work, so I tried something that is pretty much what was suggested above, but without the tpl file. I just created a label called lbl_continue_shop with text reading Click Here to Continue Shopping and added this code to customer/main/cart.tpl below the checkout and submit labels and below the your shopping cart is empty labels:


{$lng.lbl_continue_shop}



This works great for me.
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 09:23 PM.

   

 
X-Cart forums © 2001-2020