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

    version: E2G-1.4.0-RC1-r259

    I’am getting this warning in the module after correct installation

    It is a line above the buttons and image upload, config etc. screen.

    Warning: set_time_limit() [function.set-time-limit]: Cannot set time limit in safe mode in ..../assets/modules/easy2/includes/classes/e2g.module.class.php on line 20

    What to do?

    Thanks in advance
      • 28042 ☆ A M B ☆
      • 24,524 Posts
      Your server is configured to not allow the change. Hopefully you won’t need to; you may have no problems processing your images at all as long as they are not too big to begin with.
        Studying MODX in the desert - http://sottwell.com
        Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
        Join the Slack Community - http://modx.org
        • 457
        • 19 Posts
        Images are not bigger than 80kb but get also error message when uploading them.
        when I look on the FTP-server they are correctly uploaded.

        When I open the webpage url I get this message:

        « MODx Parse Error »
        MODx encountered the following error while attempting to parse the requested resource:
        « PHP Parse Error »

        PHP error debug
        Error: set_time_limit() [function.set-time-limit]: Cannot set time limit in safe mode
        Error type/ Nr.: Warning - 2
        File: .../assets/modules/easy2/includes/classes/e2g.snippet.class.php
        Line: 1023
        Line 1023 source: set_time_limit(0);

        Parser timing
        MySQL: 0.0031 s (4 Requests)
        PHP: 0.1012 s
        Total: 0.1044 s


        ----------------

        I set the "classes" folder to 777. But still having this problem.

        Is it somthing I can ask my provider and if so, what can I ask my hosting provider to get it work correctly?


        Regards,
        Alfred
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          It’s working just fine; it tries to reset the time limit and that is what fails, causing the error message. But it doesn’t really need to. You might be able to get away with commenting out the line in the code that changes the time limit if the error message really bothers you. It’s on line 20 of the assets/modules/easy2/includes/classes/e2g.module.class.php file.

          PHP will be dropping safe_mode and its siblings and children soon. It’s already flagged as deprecated in PHP 5.3

          http://php.net/manual/en/features.safe-mode.php
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 457
            • 19 Posts
            No it is not working fine undecided

            It is no problem in the Manager. That works fine and I commented out line 20

            But the website in the browser with the gallery is not showing up.
            Then I get this error in the browser instead of the site:

            File: .../assets/modules/easy2/includes/classes/e2g.snippet.class.php
            Line: 1023
            Line 1023 source: set_time_limit(0);

            When I commenting this line out then there is another error showing up in my browser.

            Does my provider only has to disable the PHP.ini file maybe?
            Can you tell me what the sollution will be instead of working in the Easy2Gallery code?

            Thank you verry much.
              • 457
              • 19 Posts
              This is the sollution.

              My provider changed: PHP.ini

              safemode in PHP.ini must be disabled

              Thank you Sottwell for trying to help me.

              Regards,
              Alfred