protecting problems and questions

Discussion in 'Setting-up protection' started by pfen09, Jun 30, 2010.

  1. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    I'm trying to protect folders for content. I read the manual and I'm not understanding.

    let's say my amember is this directory url : www.site.com/amember

    1. would I create another directory inside amember for my content to be protected? Such as "membership". So the path would be www.site.com/amember/membership/my-webpage.html

    Anything that's going to be protected has to be inside the amember directory, right?

    2. Do I have to do this:

    You have to put .htaccess file to folder /service
    --------
    Code:

    AuthType Basic
    AuthName "Members Only"
    AuthUserFile /HOME/USER/amember/.htpasswd
    AuthGroupFile /HOME/USER/amember/.htgroup
    Require group PRODUCT_1
    ErrorDocument 401 /401.html ### create this file and put necessary content
    -----------

    before I use the New rewrite for protection?

    3. If so, How do I edit my htaccess file? When I bought blue host and created my public folder using filezilla, an htaccess file appeared in the public directory. Do I edit that one and move it somewhere? Or do I create a new one and leave the existing?

    Please help. Thank you!
    Nick
  2. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    1) I would not personally place the protected directory inside of the aMember directory, but rather a directory off of the root of your domain.

    Example: site.com/membership instead of site.com/amember/membership

    2) Using the "Protect Folder" wizard from within your aMember admin will auto create the .htaccess file for you automatically in the folder you are protecting.
  3. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    header issue

    Hey thanks...that worked great.

    New problem now. My header is not showing up. my footer and everything is good, but the header is not appearing in my protected content area.

    My header image is being called as a background image in CSS ...../images/header.png

    the images folder resides in the root directory with my protected directory as suggested above---mysite.com/images

    Can you help with this problem?

    Thank you,
    Nick
  4. davidm1

    davidm1 aMember User & Partner

    Joined:
    May 16, 2006
    Messages:
    4,437
    Did you protect this directory too? it shouldnt be.

    David
  5. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    No, it is not protected. What else do you think it is?
  6. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    something to think about, too...I don't know if this has anything to do with the header problem, but when I protected the folder and went to the link an error 500 message appeared saying their is a hiccup. Then, after a few seconds, I hit refresh and the page appeared, except for the header.

    Thanks
    Nick
  7. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    @pfen09: can you share a link to the site, probably the quickest way to tell you what's up
  8. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    sure, www.upgrademyreality.com/template.html

    Not sure if you want the protected page, I guess you would need the password and username for that. If that's case, it's ok because it's all just testing as of now. Let me know

    Nick
  9. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    When I'm on my protected page and I look at the source file and view the style sheet, this message comes up

    <html><head><title>404 Not Found</title></head>
    <body bgcolor=white>
    <h1>404 Not Found</h1>

    The requested URL /membership/support-files/template-main3.css does not exist.

    </body></html>

    I have 4 directories in my root public file. Support files is one of them and my protected file membership is the another.

    Whats going on?

    The protected directory or folder is stored outside of my amember folder, if that makes any difference.
  10. skippybosco

    skippybosco CGI-Central Partner Staff Member

    Joined:
    Aug 22, 2006
    Messages:
    2,526
    header looks ok here (see attached)
  11. pfen09

    pfen09 New Member

    Joined:
    Jun 29, 2010
    Messages:
    14
    the file upgrademyreality.com/template.html is not in a protected folder. That file sitting in my root folder.

    Once you log in, it sends you to my product url page which is sitting in a protected folder.

    The file that's missing the header is in a protected folder
  12. alexander

    alexander Administrator Staff Member

    Joined:
    Jan 8, 2003
    Messages:
    6,279
    Contact us in helpdesk and provide a way to recreate issue I will check this.

Share This Page