The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Sessions on Parked Domains

Discussion in 'General Discussion' started by tj111, Sep 10, 2007.

  1. tj111

    tj111 Member

    Joined:
    Sep 7, 2007
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    I have three domains, two of which I parked on top of the first(deltascan.net -main, deltascanlabs.com -parked, deltascanlaboratories.com -parked). I use session based authentication (in PHP) to allow users to login to the private site. However when attempting to login from either of the parked domains, it redirects to deltascan.net, then only says "You do not have access to view this page". Nowhere in any of my scripts does that text appear, nor does that text appear, I set it up to redirect to a login page then display an error if the session doesn't validate. I was previously a Plesk user, which uses "domain aliases", and it never changed the user's url when accessing any pages. Any insight is appreciated.
     
  2. tj111

    tj111 Member

    Joined:
    Sep 7, 2007
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    I have gotten it to work to an extent. Now when logging in from one of the parked domains it redirects back to the main domain login page with the error "Not logged in". Then once logging in from the main domain you can login no problem. Why is it redirecting back to the main domain, instead of just keeping the current domain in the address bar? The session validation checks the domain, so it is causing it to fail.
     
  3. Infopro

    Infopro cPanel Sr. Product Evangelist
    Staff Member

    Joined:
    May 20, 2003
    Messages:
    14,474
    Likes Received:
    202
    Trophy Points:
    63
    Location:
    Pennsylvania
    cPanel Access Level:
    Root Administrator
    Twitter:
    Parked domains just point to the account you have them parked on.
     
  4. tj111

    tj111 Member

    Joined:
    Sep 7, 2007
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    1
    Yes but when following links around a parked domain, the domain in the url stays the same. Ie. at deltascanlabs.com. clicking any link will take you to deltascanlabs.com/link. However it seems when using PHP headers, it redirects you to deltascan.net/link (the account domain), and causes my session validation script to fail. Is there any way to prevent this (without rewriting my scripts)?
     
Loading...

Share This Page