Jump to content

Edit History

eldermaster

eldermaster

Ok,

So after i got very frustrated with this bug I decided to solve it in my way, alone ..... 

So anyone who encounter this issue this is how I fixed it.

1. Go to /controllers/front

2. Open AuthController.php

3. Look for  

if ($hookResult && $register_form->submit()) {
                    $should_redirect = true;

is around line 60

4. Comment $should_redirect = true; like that  //$should_redirect = true;

5. Add after this line Tools::redirectLink(__PS_BASE_URI__);

To be more confident with the solution do the same with line 77 - even this is only for the login process when the client is already registered ... so is not really necessary :) to do this second change.

if (Tools::isSubmit('submitLogin')) {
                if ($login_form->submit()) {
                    //$should_redirect = true;
                    Tools::redirectLink(__PS_BASE_URI__);

Post here if is working for you,

PS: Possible drawback is that the customer will always be redirected to homepage, no matter the page where he is when he decide to create the account - but I don't care ... at least no more security error

The order process when the customer create his account is not affected by this change. He will be redirected as usual into confirmation page.

Good luck,

eldermaster

eldermaster

Ok,

So after i got very frustrated with this bug I decided to solve it in my way, alone ..... 

So anyone who encounter this issue this is how I fixed it.

1. Go to /controllers/front

2. Open AuthController.php

3. Look for  

if ($hookResult && $register_form->submit()) {
                    $should_redirect = true;

is around line 60

4. Comment $should_redirect = true; like that  //$should_redirect = true;

5. Add after this line Tools::redirectLink(__PS_BASE_URI__);

To be more confident with the solution do the same with line 77

if (Tools::isSubmit('submitLogin')) {
                if ($login_form->submit()) {
                    //$should_redirect = true;
                    Tools::redirectLink(__PS_BASE_URI__);

Post here if is working for you,

PS: Possible drawback is that the customer will always be redirected to homepage, no matter the page where he is when he decide to create the account - but I don't care ... at least no more security error

Good luck,

eldermaster

eldermaster

Ok,

So after i got very frustrated with this bug I decided to solve it in my way, alone ..... 

So anyone who encounter this issue this is how I fixed it.

1. Go to /controllers/front

2. Open AuthController.php

3. Look for  

if ($hookResult && $register_form->submit()) {
                    $should_redirect = true;

is around line 60

4. Comment $should_redirect = true; like that  //$should_redirect = true;

5. Add after this line Tools::redirectLink(__PS_BASE_URI__);

To be more confident with the solution do the same with line 77

if (Tools::isSubmit('submitLogin')) {
                if ($login_form->submit()) {
                    //$should_redirect = true;
                    Tools::redirectLink(__PS_BASE_URI__);

Post here if is working for you,

PS: Possible drawback is that the customer will always be redirected to homepage, no matter where the page where he is when he decide to create the account - but I don't care ... at least no more security error

Good luck,

eldermaster

eldermaster

Ok,

So after i got very frustrated with this bug I decided to solve it in my way, alone ..... 

So anyone who encounter this issue this is how I fixed it.

1. Go to /controllers/front

2. Open AuthController.php

3. Look for  

if ($hookResult && $register_form->submit()) {
                    $should_redirect = true;

is around line 60

4. Comment $should_redirect = true; like that  //$should_redirect = true;

5. Add after this line Tools::redirectLink(__PS_BASE_URI__);

To be more confident with the solution do the same with line 77

if (Tools::isSubmit('submitLogin')) {
                if ($login_form->submit()) {
                    //$should_redirect = true;
                    Tools::redirectLink(__PS_BASE_URI__);

Post here if is working for you,

Good luck,

×
×
  • Create New...