skip to Main Content

I have made a function in my Laravel application to send a message to my subscribers when I publish an entry, the problem is that it stops when it goes by the subscriber 28 and does not follow.

I’ve been researching and it seems that php by default for the script when it takes 30 seconds, I changed the configuration and even the support of my hosting has done for me. But still it is still cutting when it takes about 30 seconds.

Attached image of the php configuration of the cpanel

enter image description here

3

Answers


  1. Put that on top of your php script.
    Just change amount of seconds.

    max_execution_time = 10
    
    Login or Signup to reply.
  2. Php has a max execution time, you can set a new time limit:

    php script

    • ini_set(‘max_execution_time’, 100); //100 seconds
    • ini_set(‘max_execution_time’, 0); // for infinite

    htaccess

    • php_value max_execution_time 300

    Caution, scripts in an infinity loop will run forever.

    Login or Signup to reply.
  3. If you are using Cpanel/WHM , go to “MultiPHP INI Editor”(Basic Mode) and select PHP version .

    Then edit max_execution_time.

    Screenshot attached :

    Screen shot

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search