Jump to content

thread in php


Recommended Posts

is there any way to implement thread in php? i came across pcntl but it is telling it is not for windows. how to do it with windows?

Link to post
Share on other sites

I am trying to developing a websocket server which can listen from browser. if i use any other language rather than php how both will incorporate? how should i approach?

Link to post
Share on other sites

I'm not really sure what your requirements are, but you definitely wouldn't want to write a web server using PHP. Multithreading is actually disabled in PHP when it is running as an Apache module with a server, it is only available from the command line. I don't know what you're trying to do, but you can have multiple programs use the same database or things like that to exchange information.

Link to post
Share on other sites

If you must have your socket server running on Windows, the best thing to do is not use PHP, but use a language more appropriate for (portable?) desktop applications... like C# or JAVA.If you insist on using PHP, you'll have to settle with using a UNIX server - there's nothing for Windows yet.

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...