Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Redirect a page to Login page


Guest

Recommended Posts

Posted

I am using this method for redirection is there anyother method can any one tell me how to do this with header(Location: url) method in oscommerce anyone tried header method

 

tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'NONSSL'));

 

use session control to redirect page

 

if (empty($sessid)) {

$navigation->set_snapshot();

tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'NONSSL')); -->if u have SSL active in login page use SSL instead of NONSSL

}

or

 

if (!tep_session_is_registered('customer_id')) {

$navigation->set_snapshot();

tep_redirect(tep_href_link(FILENAME_LOGIN, '', 'NONSSL'));

}

Posted

header() should work, but tep_redirect does actually use header()...

 

What exactly are you trying to do, and what's not working about it?

 

-jared

Posted

Please make a example of that header in your reply it will be more usefull for orthers . I checked personaly it worked fine for me. make example it will help other ..... thanks for your reply buddy.

Posted

But it will help others even more to do a tiny bit of research and find examples on how to do it themselves. Most people remember more the things they figure out.

 

php.net/header.

 

-jared

Archived

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

×
×
  • Create New...