We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 23134
    • 33 Posts
    Quote from: BobRay at Nov 21, 2011, 03:08 PM
    I think the problem is more likely to be with the server configuration than MODX.

    It could be a problem with session.save_path and/or session.gc_maxlifetime.

    Who is your host and is it a windows or *nix server?

    FreeBSD virtual server (jail machine).
      • 23134
      • 33 Posts
      No server. But session variable is defined cached value.
      I find that value in /tmp folder (where sessions files), in site folder - no match...
      And find in mysql that value - in mysql finded!
      In table modx_session (modx_ - is prefix)
        • 23134
        • 33 Posts
        You can look for the money and tell - what's really going on? I can give you access ftp in manageryu How much will it cost?

        Now the situation is as follows:
        On page: http://new777.veterany.org/forum/vstrechi.html
        call script assets/components/captcha/captcha.php in tag <img>. That script must defined session variable $_SESSION['veriword'] = $code;
        If I loguot in mgr and web, from every contexts, damping $_SESSION['veriword'] == NULL

        If login in mgr context - damp variable $_SESSION['veriword'] take first value of defined in captcha.php, then then the same value first $_SESSION['veriword'] from cache in table modx_session - despite the fact that captcha.php take different value....

          • 3749
          • 24,544 Posts
          I'm sorry, Petja. I'm the wrong person for that job. I'm not an expert in server configuration and I don't use FormIt.

          Maybe someone else will be interested.

          BTW, you could switch to reCaptcha, which is more secure and (I think) doesn't use the $_SESSION array. [ed. note: BobRay last edited this post 14 years, 11 months ago.]
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting
            • 23134
            • 33 Posts
            I can not stop until I do not understand why modx caches the session, and how to get it to update a certain value. This is not server problem. May be FormIt, but I have not gotten to it...
              • 23134
              • 33 Posts
              This is problem modx!
              I withiut FormIt output <img="captcha.php" /> and snippet [[!snipname]] where
              <?php
              echo $_SESSION['veriword'];

              And dont work. Modx cached session in DB and dont update it...
              Why did it????????????.........
                • 23134
                • 33 Posts
                Why if i open captcha.php in a separate window, and refresh page with snippet <?php echo $_SESSION['veriword'];
                then value of $_SESSION['veriword'] refreshed!

                But if open snippet and call <img src="captcha.php... - value of $_SESSION['veriword'] - cached and one and the same from cache???


                Help me PLEASE four week going....
                  • 3749
                  • 24,544 Posts
                  captcha.php must be called with a different argument each time to make sure the value is refreshed. Something like this:

                  $output = '<img src="captcha.php?rand=' . rand() . '">';


                  SPform does that. I don't know if FormIt does or not.
                    Did I help you? Buy me a beer
                    Get my Book: MODX:The Official Guide
                    MODX info for everyone: http://bobsguides.com/modx.html
                    My MODX Extras
                    Bob's Guides is now hosted at A2 MODX Hosting
                    • 23134
                    • 33 Posts
                    captcha.php nothing to do with if you run the code, where any session variable set to any value, then the session cached, and if you change this value, it still displays modx first cached value!
                      • 23134
                      • 33 Posts
                      My hosting conflicting with modSessionHandler. On another hosting worked... But i dont know which is why it did not work...

                      But i disable his (modSessionHandler) on manager -> System -> System Settings -> session_handler_class -> clear value...

                      And all works.

                      Yhanks All for help!