next up previous contents index
Next: Simple Server in Tcl Up: Server Previous: Simple Server in Perl   Contents   Index


Simple Server in PHP

First read "Simple Server in C". Then you copy the files from the template to your directory. Under ./language_bindings you will find them. If you have installed swig http://www.swig.org you can rebuild the bindings using the shell scripts in this directory. There is a subdirectory for each script language. Under this there is a further subdirectory "id" for inetd and "mt" for multithreaded server. For better debugging start with the "mt" version. In this case you can see the prints from your language on the screen.

Figure 3.15: Create new php project
mkdir newdir
cd newdir
cp $PVBDIR/language_bindings/php/mt/* .
rm periodic.*

Now use designer to define a mask1.

Figure 3.16: Create php from Qt Designer
designer mask1.ui
ui2pvc mask1.ui mask1.php

In test.php you have to substitute periodic with mask1. Now run your server.

Figure 3.17: Run PHP
./test.php


next up previous contents index
Next: Simple Server in Tcl Up: Server Previous: Simple Server in Perl   Contents   Index
Rainer Lehrig 2004-02-17