Detection of Headphone from PHP program


#1

hi 2 all.
i am working in a telephone company.
we have an asterisk server which routes the call on different IP’s using SIP and IAX protocol.
i want to develop a webpage in php that contains a button(click for a free call to customer service).
when user click that button call is connected with customer service officier.(say to a number 0425987621)
i want to check that “Is there any headphone and mic is connected with user’s machine or not and if there is headphone then how can i access that via php.”

i want your experienced knowledge to share with me.
any positive responce in this regard will be highly appreciated.
Thanks in advance.

regards


#2

hi

The thing is that PHP is just the severside script. Then u’ll output something to the client’s browser. thats the point to look at.

Most of the time u are outputting HTML for the client side. There is no possibility to access the soundcard with HTML.

that means that u’ll need a plugin. and then u may comunicate with that plugin with PHP.

i would know to plugins that may be capable of accesing the soundcards input:

  1. JavaApplets (i neither like them nor know much about them)
  2. Flash (since version 7 the flash plugin can access the mic)

[ul]It is posible to create swf files in PHP, and to comunicate with that file via XML witch can be created by PHP as well
but i don’t know how flash is sending the sound back to the server.[/ul]

probably there are more.

i don’t know whether it is posible to check the connection of a mic, i guess that depends on the soundcard. The user who puts on his headphone should be the one who made sure they are connected.

hope this gave u a point 2 start from, as i have no idea about that topic.