[PHP] Re: Php exec

2007-12-23 Thread Christophe Gosiau

Try to configure courier te read his mailboxes/users from mysql?

mattias schreef:

If i use courier-mta
Can i create a php script wich create mailboxes?
And users
Hope any understand


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Try{} Catch()

2007-12-23 Thread Christophe Gosiau
Try{} catch{} makes more sense when your application is Object Oriented 
and you use the MVC model.
Your library performs some actions but when an error occures, it can't 
write directly to your browser.
Your modules speak with your library and checks if an error occures.. If 
so a decent error message can be shown...



Al schreef:

Try() and Catch() seems neat; but, I've not found it to be very practical.

Anyone using it? How?

Al...


--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] PHP interprocesss communication

2007-12-23 Thread Christophe Gosiau

Hi,
I'm trying to write the following program:
A browser connects to an apache web-server where a PHP application is 
running. Most of the actions of the application are Mysql database actions.
There are however also actions that needs to be done on the client side 
but that are not possible inside a browser (output to a display on a 
serial connection, printing to multiple printers...). For these actions 
I wrote a .NET program that is running on the client side and makes a 
TCP connection to a PHP server that is running on the same server as the 
webserver.
This PHP server is a multithreaded server that spawns child threads. 
Every connection from every user is handled by a seperate child thread.


So, on the client side, I have a .NET program with a persistent 
connection to the PHP server and a browser connecting to apache that 
runs a PHP application.
If the user chooses to perform an action that needs to be done on the 
client side (let's say output data to a serial connection), the 
webserver needs to tell the PHP server to send data to the clients .NET 
program (who will makes the final serial connection).


The problems I have with this setup are:
1) How does my PHP application finds out what thread is handling the TCP 
connection according to the user who is logged in into the application?
2) What is the best way to send a command to this thread? Shared Memory? 
Socket Pairs? Named Pipes?
3) Has anyone already made a similar setup or does anyone has good 
documentation about interprocess communication?


thx
Christophe

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php