We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 19534
    • 183 Posts
    Hi

    I’ve got a problem when an anonymous user tries to access a protected document and is being redirected to the 403 document:

    My protected document is titled "protected", my 403 document "unauthorized access". I’m using two templates to display these documents where I have something like
    <h1>[[+pagetitle]]</h1>
    in both templates.

    And now my problem:

    I clean the site cache and open the protected document as an anonymous user
    -> I’m forwarded to the 403 document and get
    <h1>unauthorized access</h1>


    I open the document as a registred user
    -> I get the document and
    <h1>protected</h1>


    I open the document as an anonymous user once again
    -> I’m forwarded to the 403 document and get
    <h1>unauthorized access</h1>


    That’s fine...

    Now I make a change to the protected document (or clean the site cache)

    I open the document as a registred user
    -> I get the document and
    <h1>protected</h1>


    I open the protected document as an anonymous user
    -> I’m forwarded to the 403 document and get
    <h1>protected</h1>


    In short: When I open the protected document as a registered user directly after cleaning the cache or editing the document, the "pagetitle" placeholder in my 403 document is set to the value of my protected page. It seems as [[+pagetitle]] is somehow set (cached?!?) before the anonymous user is forwarded to the 403 document (same with other placeholders). I don’t want to disable the cache on all protected documents..

    I’m no modx expert so can someone give me a hint how to solve this problem?

    My system info:

    * ModX Traditional 2.0.2pl
    * XAMPP 1.7.3 on WIndows XP
    * PHP Version 5.3.1
    * MySQL Client API 5.1.41
    * PDO Driver for MySQL 5.1.41
    * Firefox 3.6.10

    There are no logs in core/cache/logs/error.log

    Thank you in advance!

      Add-On to easily manage your multilingual sites: Babel