Forums / Basic Configuration / password protecting directories or creating link to members only area

password protecting directories or creating link to members only area

Locked

Views: 2,271

Results 1 to 8 of 8
This thread is locked. New replies are disabled.
23 Apr 2007, 3:28 PM
#1
bradymc avatar

bradymc

New Zenner

Join Date:
Feb 2007
Location:
Dallas area
Posts:
75
Plugin Contributions:
0

password protecting directories or creating link to members only area

I've looked in the forums and the admin section and can't find an answer to my problem. So forgive me if this has already been covered.

My client has a directory with a few different pages that he would like only paid customers to have access to. Is it possible to have a "members only" link appear once a customer has signed into the site. Or is it possible to password protect directories so that customers use their ZC UN & PW to get in?

23 Apr 2007, 3:30 PM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: password protecting directories or creating link to members only area

What kind of pages are these?

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

23 Apr 2007, 3:34 PM
#3
bradymc avatar

bradymc

New Zenner

Join Date:
Feb 2007
Location:
Dallas area
Posts:
75
Plugin Contributions:
0

Re: password protecting directories or creating link to members only area

This is a fitness website. There are two php forms that are used to gather info from the customer about their lifestyle and workout habits. And one html page that has a listing of exercises and their descriptions.

They are currently not a part of the cart system. By that, I mean that they are stand-alone pages and not integrated with my ZC look or feel.

23 Apr 2007, 4:16 PM
#4
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: password protecting directories or creating link to members only area

If you made them part of Zen Cart you could force the login in order to see the pages ...

I am not sure what happens once you get to those pages with the data, but this is one method of doing it ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

23 Apr 2007, 4:27 PM
#5
bradymc avatar

bradymc

New Zenner

Join Date:
Feb 2007
Location:
Dallas area
Posts:
75
Plugin Contributions:
0

Re: password protecting directories or creating link to members only area

I've struggled with the option of integrating them with ZC because of the way the function and the space needed to display the info. I guess I could toy around with it and see how it looks. Once I integrate, how do I get them setup so that they are only accessible after the customer logs in?

Is it possible to have a link appear only to someone who is logged in?

23 Apr 2007, 4:33 PM
#6
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: password protecting directories or creating link to members only area

You can add this to the top of the header_php.php file for that particular page or pages ...

// if the customer is not logged on, redirect them to the login page
if (!$_SESSION['customer_id']) {
  $_SESSION['navigation']->set_snapshot();
  zen_redirect(zen_href_link(FILENAME_LOGIN, '', 'SSL'));
}

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!

30 Apr 2007, 2:07 PM
#7
bradymc avatar

bradymc

New Zenner

Join Date:
Feb 2007
Location:
Dallas area
Posts:
75
Plugin Contributions:
0

Re: password protecting directories or creating link to members only area

Linda,

I created a new page with external links and used the code you suggested. It works fine going through ZC, but we still need these other pages to be separate from the cart system.

As they stand now, these pages are directly accessible if you type them into your browser. Is it possible to use the ZC usernames/passwords to password protect these pages?

3 May 2007, 3:40 AM
#8
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Re: password protecting directories or creating link to members only area

Zen Cart was not designed to run outside of Zen Cart ...

You might look at the Downloads and see if there is anything for sideboxes or pages outside of Zen Cart that might help you do something like this ...

Linda McGrath
If you have to think ... you haven't been zenned ...

**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**

Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here

Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!