Forums / Templates, Stylesheets, Page Layout / Redirect to home page... how?

Redirect to home page... how?

Started by incircolo on 10 Oct 2011, 2:52 PM · Views: 985

Results 1 to 6 of 6
10 Oct 2011, 2:52 PM
#1
incircolo avatar

incircolo

New Zenner

Join Date:
Aug 2009
Posts:
50
Plugin Contributions:
0

Redirect to home page... how?

ZenCart 1.3.9H

In a customized shopping-cart template i'd like to redirect users to the home page after all the products are removed from the shopping cart.
How can i do it?

10 Oct 2011, 3:07 PM
#2
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,701
Plugin Contributions:
0

Re: Redirect to home page... how?

Silly question - Why?

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.

10 Oct 2011, 3:30 PM
#3
incircolo avatar

incircolo

New Zenner

Join Date:
Aug 2009
Posts:
50
Plugin Contributions:
0

Re: Redirect to home page... how?

Because i don't know how to do it... do you know which are the instruction to recreate the home page?
I have a custom template which has some errors on it, and the default template brake the page.

10 Oct 2011, 5:43 PM
#4
rescoccc avatar

rescoccc

Totally Zenned

Join Date:
May 2010
Location:
WA State
Posts:
1,700
Plugin Contributions:
2

Re: Redirect to home page... how?

Do you want to redirect the customer after they complete a purchase? If they empty their cart manually? What is the goal of redirecting them?

The best way to learn is to try stuff. But, back it up first.

10 Oct 2011, 9:29 PM
#5
incircolo avatar

incircolo

New Zenner

Join Date:
Aug 2009
Posts:
50
Plugin Contributions:
0

Re: Redirect to home page... how?

The problem is that there is a bug with shopping-cart template.
When the customer empty the shopping cart, the structure of the page is not correctly rebuilt, so i'd like instead that when the cart is empty (because customer has removed every article from the cart) he has been redirected to the homepage (or the home page is rebuilt)
Now i can't understand exactly if there is a call in zencart for loading the home page.

Something like

If products >0 then {
... }
else {
go to homepage }

I hope it's clear for you.

10 Oct 2011, 10:15 PM
#6
Kim avatar

Kim

Obaa-san

Join Date:
Jun 2003
Location:
West Coast, North America
Posts:
26,701
Plugin Contributions:
0

Re: Redirect to home page... how?

It would be much better to fix whatever template problem there is instead of redirecting to a different page - what is the URL?

Please do not PM for support issues: a private solution doesn't benefit the community.

Be careful with unsolicited advice via email or PM - Make sure the person you are talking to is a reliable source.