Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

tep_session_destroy();


mamounara

Recommended Posts

Hello all,

 

I have (for some of you here) a small problem.

 

In one of the addons that i found for oscommerce it describes how you can control login.

 

So far so good. At the end of the instructions it says.......:

"I suggest that you give an info to add tep_session_destroy(); to the create_account_success.php. I've added this right to the beginning of this file, but it doesn't really matter. If you don't add this the user that just registered is already logged in, even that the customers_status is set to '0'. Of course, after logging out, he/she can't login anymore until account has been activated."

 

My question is if any of you know how to put the tep_session_destroy(); inside the code so i can fix the problem (If you don't add this the user that just registered is already logged in).

 

How i write it? the code for it. I tried something...but.......

 

Note: I now very few about php. :)

 

Thank you all.

manos

Link to comment
Share on other sites

Hello all,

 

I have (for some of you here) a small problem.

 

In one of the addons that i found for oscommerce it describes how you can control login.

 

So far so good. At the end of the instructions it says.......:

"I suggest that you give an info to add tep_session_destroy(); to the create_account_success.php. I've added this right to the beginning of this file, but it doesn't really matter. If you don't add this the user that just registered is already logged in, even that the customers_status is set to '0'. Of course, after logging out, he/she can't login anymore until account has been activated."

 

My question is if any of you know how to put the tep_session_destroy(); inside the code so i can fix the problem (If you don't add this the user that just registered is already logged in).

 

How i write it? the code for it. I tried something...but.......

 

Note: I now very few about php. :)

 

Thank you all.

manos

 

 

please someone help........

Link to comment
Share on other sites

Try adding it to the bottom of create_account_success.php, just above the line

 

<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

 

<?php 
 if (tep_session_is_registered('customer_id')) {
	tep_session_destroy();
 }
?>

 

 

 

EDIT: Just in case that is confusing, all in all, so it looks like this:

 

<?php 
 if (tep_session_is_registered('customer_id')) {
	tep_session_destroy();
 }
?>

<?php require(DIR_WS_INCLUDES . 'application_bottom.php'); ?>

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...