views:

84

answers:

2

Possible Duplicate:
How can one use multi threading in php applications

Any body knows PHP5 supports multi threading or not. If it support how to implement that?

+1  A: 

When using php as a module (like in apache), it's not possible. If you use php in CLI, you can use the function pcntl_fork

Ikke
A: 

While you can use the pcntl extension to fork, please don't. It creates all sorts of entertaining issues, especially when you're using mod_php.

There are better ways. Try a work queue, like Gearman.

Charles