PHP pthreads: Fatal error: Class 'Thread' not found

前端 未结 6 1478
小蘑菇
小蘑菇 2020-12-06 05:28

I use php5.5 on my webserver. Now I want to use pthreads. Here\'s my php config: http://dd19010.kasserver.com/infophp.php55

After implementing this code.....

6条回答
  •  [愿得一人]
    2020-12-06 05:48

    Your phpinfo shows that you have php with thread safety disabled. You need to install a version of php that is thread safe to use pthreads. This may or may not fix your current issue though.

    You may need to copy the pthreadsVC2.dll into the bin directory of your web service as well.

    /etc/php55/fpm/
    

    You're looking for the folder with php.ini in it.

    Make sure the php.ini file has the line added:

    extension=php_pthreads.dll
    

提交回复
热议问题