Wordpress Amember Integration Using php include

Discussion in 'Integration' started by brandondrury, Feb 2, 2009.

  1. brandondrury

    brandondrury New Member

    Joined:
    Jan 30, 2009
    Messages:
    10
    Hello,

    I had planned on using the simple php include method of protecting individual directories within Wordpress. I'm having problems getting this to work without bugs.

    It appears that simply using the php include method causes this error when a user is redirected to the login screen:

    WARNING: array_filter() [function.array-filter]: The first argument should be an array in line 208 of file check.inc.php

    Any ideas?

    Brandon
  2. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    If you are protecting directories, why not use an .htaccess method like new_rewrite?
  3. davidm1

    davidm1 aMember User & Partner

    Joined:
    May 16, 2006
    Messages:
    4,437
    Protecting wordpress directories with htaccesss wont work, they are virtual directories, adding htaccess to the real versions will give an error.

    I would think with the php include method you would need to check the database for the article to see which category its in, then if it matches, use php include. I do this with my site which is joomla.

    The hidepost method is simpler to use, but it protects individual articles, not categories etc..

    David
  4. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    Good point. I guess he was not clear about whether he was protecting category based directories or actual directories.

    I was going along the lines of protecting, for example, wp-admin..

    If that is not the case then David is square on, hidepost is a much simpler solution.
  5. codeispoetry

    codeispoetry aMember Pro Customer

    Joined:
    Jan 12, 2009
    Messages:
    336
    Hi Brandon,

    You can protect category-based directories (virtual directories within Wordpress) using The Bridge.

    More info over at www.amemberincremental.com

    Lee

Share This Page