Lazarus and PHP (installing VCL?) lazarus / 10-Designer ---------------------------------------------------------------------- LazaruX · 2008-10-13 13:39 Hi, I have tried to convert my projects to PHP and I have tried to follow the instructions on the website (http://web.fastermac.net/~MacPgmr/PhpTk/PhpTkStatus.html), but its not working. This is how it should be: http://web.fastermac.net/~MacPgmr/PHP/hello.php but the only thing I get is: http://bpsoftware.blackapplehost.com/hello.php Can somebody help me? ---------------------------------------------------------------------- Phil · 2008-10-13 15:01 Quote from: "BPsoftware"Hi, I have tried to convert my projects to PHP and I have tried to follow the instructions on the website (http://web.fastermac.net/~MacPgmr/PhpTk/PhpTkStatus.html), but its not working. This is how it should be: http://web.fastermac.net/~MacPgmr/PHP/hello.php but the only thing I get is: http://bpsoftware.blackapplehost.com/hello.php Can somebody help me? It looks like you didn't add the event handling code, as described in the text: http://web.fastermac.net/%7EMacPgmr/PhpTk/PhpTkStatus.html#Examples Thanks. -Phil ---------------------------------------------------------------------- Leledumbo · 2008-10-14 03:30 Yes, the tool doesn't convert the body of event handler. Perhaps because it's not possible since PHP and Lazarus have different class libraries. ---------------------------------------------------------------------- Phil · 2008-10-14 20:16 Quote from: "Leledumbo"Yes, the tool doesn't convert the body of event handler. Perhaps because it's not possible since PHP and Lazarus have different class libraries. Correct, that would require translating Object Pascal source to PHP and JavaScript. Quite a feat that would be! However, you can put some of your non-UI Pascal code in a PHP extension (compiled library) and call it from PHP. See the example included with the PHP Toolkit. Here's a more sophisticated example, where I took an existing Delphi/Laz app and converted its forms automatically to VCL for PHP, then added some JS and PHP code to implement the basic UI (uploading and downloading files, etc.). Click Help for basic instructions. http://web.fastermac.net/~MacPgmr/PHP/IrMain.php Thanks. -Phil