Post by itrends » Thu Apr 14, 2011 9:27 pm

Hi, how can I change the login process so that instead of seeing their account page they instead get taken to the homepage of the store?

Thanks

Active Member

Posts

Joined
Tue Jul 14, 2009 7:54 pm

Post by Avvici » Thu Apr 14, 2011 11:21 pm

Just be careful as to where you send people after certain functions. OC sends them to the account page because organically it makes sense because they just logged in :)

So look for the following file: catalog/controller/account/login.php

Now search for the following line of code:

Code: Select all

if (isset($this->request->post['redirect'])) {
					$this->redirect(str_replace('&', '&', $this->request->post['redirect']));
				} else {
					$this->redirect(HTTPS_SERVER . 'index.php?route=account/account');
				} 
			}
    	}  
Replace with this:

Code: Select all

if (isset($this->request->post['redirect'])) {
					$this->redirect(str_replace('&', '&', $this->request->post['redirect']));
				} else {
					//$this->redirect(HTTPS_SERVER . 'index.php?route=account/account');
                                          $this->redirect(HTTPS_SERVER . 'index.php?route=common/home');
				} 
			}
    	}  
Last edited by Avvici on Thu Apr 14, 2011 11:41 pm, edited 1 time in total.

User avatar
Expert Member

Posts

Joined
Tue Apr 05, 2011 12:09 pm
Location - Asheville, NC

Post by phpuk » Thu Apr 14, 2011 11:39 pm

Helpful :-)

Try looking at this file:
catalog/controller/account/login.php

Phil.

Global Moderator

Posts

Joined
Wed Mar 25, 2009 10:57 am

Post by phpuk » Thu Apr 14, 2011 11:40 pm

Damn you must have posted a micro second before me :-)

Or I didn't refresh before posting.

Global Moderator

Posts

Joined
Wed Mar 25, 2009 10:57 am

Post by Avvici » Thu Apr 14, 2011 11:42 pm

phpuk wrote:Damn you must have posted a micro second before me :-)

Or I didn't refresh before posting.

Looks like it :laugh:

User avatar
Expert Member

Posts

Joined
Tue Apr 05, 2011 12:09 pm
Location - Asheville, NC
Who is online

Users browsing this forum: Amazon [Bot] and 25 guests