Page 2 of 3 FirstFirst 123 LastLast
Results 11 to 20 of 21
  1. #11
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Those settings force the Login Page to be displayed ...

    You can add links via Easy Pages to allow guests to reach the pages that are allowed in the:
    /includes/init_includes/init_customer_auth.php

    That way, anyone can click on the links to see these pages ...

    They still have to Login and be approved to see anything else ...
    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: v1.5.5]
    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!

  2. #12
    Join Date
    Aug 2008
    Posts
    448
    Plugin Contributions
    0

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Can I make pages that allow anyone to view regardless if they are logged in or not?

    Thats what I'm saying. With the settings that I have, for some reason, the contact_us page is viewable (after they click the link of course) regardless if they are logged in or not. And that is what I want. But I want to make other pages just like contact_us to be viewable even when they are not logged in. Is that doable?

  3. #13
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Read the pages listed in the file carefully that are currently set to be allowed for *anyone* to see:
    Code:
      if (!in_array($_GET['main_page'], array(
    FILENAME_LOGIN, 
    FILENAME_LOGOFF, 
    FILENAME_CREATE_ACCOUNT, 
    FILENAME_PASSWORD_FORGOTTEN, 
    FILENAME_CONTACT_US, 
    FILENAME_PRIVACY))) {
    If you want more pages, add them ...

    If you want less pages, remove them ...

    Then, you make the links for people to get to the pages that are allowed ...

    Easy Pages is one of the simplest methods to build the links that are allowed ...
    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: v1.5.5]
    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!

  4. #14
    Join Date
    Aug 2008
    Posts
    448
    Plugin Contributions
    0

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Hi Linda,

    Thanks! That works. I tested with FILENAME_PRIVACY and it works. There were 2 sections that met my website conditions and the first section it didn't list any array with those filenames, that is why I was lost. The code you posted was in the 2nd section. My fault for not carefully reading through all of it.

    But I'm testing with the ez pages now and I can't get that to work. I put in FILENAME_EZPAGES into the array and when I link it using
    this code in the header.
    Code:
    <li><a href="<?php echo zen_href_link(FILENAME_EZPAGES, 'id=1&chapter=0') ?>" rel="nofollow">Help</a></li>
    It doesn't allow me to view that page. So am I not linking it right or am I putting the wrong code inside the array?

    Thanks.

  5. #15
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Are you trying to allow 1 specific Easy Pages to work? Or All EZ Pages to work?
    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: v1.5.5]
    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!

  6. #16
    Join Date
    Aug 2008
    Posts
    448
    Plugin Contributions
    0

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    I want to allow all the ez pages to work. But knowing the option to allow individuals would be nice too. I'm just trying to put a link that links to an ez page and allow everyone (login or logout) to be able to view that page. thats it.

  7. #17
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Try changing the code to:
    Code:
      case (CUSTOMERS_APPROVAL_AUTHORIZATION == '1' and $_SESSION['customer_id'] == ''):
      /**
       * customer must be logged in to browse
       */
    //  if (!in_array($_GET['main_page'], array(FILENAME_LOGIN, FILENAME_CREATE_ACCOUNT))) {
      if (!in_array($_GET['main_page'], array(FILENAME_LOGIN, FILENAME_LOGOFF, FILENAME_CREATE_ACCOUNT, FILENAME_PASSWORD_FORGOTTEN, FILENAME_CONTACT_US, FILENAME_PRIVACY, FILENAME_EZPAGES))) {
        if (!isset($_GET['set_session_login'])) {
          $_GET['set_session_login'] = 'true';
          $_SESSION['navigation']->set_snapshot();
        }
        zen_redirect(zen_href_link(FILENAME_LOGIN, '', 'SSL'));
      }
      break;
    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: v1.5.5]
    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!

  8. #18
    Join Date
    Aug 2008
    Posts
    448
    Plugin Contributions
    0

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Hi Linda,

    I tried that already. In my 2nd to last post is where I mentioned adding FILENAME_EZPAGES into the array and also how I link to it. Any ideas? I don't know if this helps, but I also was testing with adding FILENAME_SHIPPINGINFO into the array and try to link to it, but was having issues with that as well.

    Thanks for helping me look into this matter.

  9. #19
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Look for each of the arrays where you see:
    FILENAME_EZPAGES

    Above each one, is the condition ... such as the the Approval is set to 1 and the customer is not logged in yet:
    Code:
    /**
     * if not down for maintenance check login status
     */
      case (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == ''):
      /**
       * customer must be logged in to browse
       */
      if (!in_array($_GET['main_page'], array(FILENAME_LOGIN, FILENAME_CREATE_ACCOUNT, FILENAME_EZPAGES))) {
    If I have the FILENAME_EZPAGES added to that condition, then I can get to the Easy Page when I am not logged in and the Authorization is set to 1 ...

    There are several of these in the file ...
    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: v1.5.5]
    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!

  10. #20
    Join Date
    Aug 2008
    Posts
    448
    Plugin Contributions
    0

    Default Re: Why am I able to view Contact Us and not other links when Customer not Authorized

    Hello Linda,

    The stock file includes/init_includes/init_customer_auth.php does not have FILENAME_EZPAGES. So I don't see FILENAME_EZPAGES anywhere. I think you meant look in the file and find this condition:

    Code:
    case (CUSTOMERS_APPROVAL == '1' and $_SESSION['customer_id'] == ''):
    Anywhere that has this condition to add FILENAME_EZPAGES into the array inside that condition. Guess what? It works!

    The FILENAME_EZPAGES had to be added under 2 different places with that condition for it to work. All this time, I was only adding to one of the condition.

    I just tested and it works. Thank you very much for your help in this matter. I will run and try not to bug so much. I hope this helps others out there that need to implement this. Cheers

 

 
Page 2 of 3 FirstFirst 123 LastLast

Similar Threads

  1. Not able to view my categories
    By lauriesscraps in forum Setting Up Categories, Products, Attributes
    Replies: 4
    Last Post: 28 Oct 2010, 08:17 PM
  2. Authorized customer can only view certain products?
    By rennevat in forum General Questions
    Replies: 0
    Last Post: 22 Apr 2010, 12:22 AM
  3. Replies: 0
    Last Post: 9 Dec 2009, 04:28 AM
  4. Why is my shipping estimator not allowing customer to select other countries?
    By vik007 in forum Built-in Shipping and Payment Modules
    Replies: 0
    Last Post: 25 Mar 2009, 11:00 PM
  5. Customer not able to log in or view catagories
    By just2zang in forum Managing Customers and Orders
    Replies: 6
    Last Post: 9 Apr 2007, 11:46 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg
Zen-Cart, Internet Selling Services, Klamath Falls, OR