PHP 5.4 compiler for .NET/Mono frameworks. Phalanger compiles legacy PHP code to MSIL while being fully compatible with PHP behavior.
Note: There is a new, modern PHP compiler to .NET entitled Peachpie, which is being developed at the moment. Please see the Peachpie repository
By Jakub Misek, 03/06/2013
After several months of development, contributions from opensource community and collaboration with big commercial users, Phalanger is getting bigger. Today we’ve released package of Phalanger, containing many new extensions and latest integration for Visual Studio.
Mainly Phalanger is getting more managed extensions.
Biggest advantage of Phalanger is its platform; Phalanger is built completely on .NET, using safe code. No native unsafe C/C++ code is being used, and so Phalanger does not suffer from common bugs like memory leaks, buffer overruns and others. However to achieve compatibility with existing PHP applications, it needs to support a lot of PHP extensions. Until now the only way was to use mechanisms of remoting and DLL hijacking, so old native PHP4 extensions might be used in otherwise clean .NET environment.
Since this release, Phalanger contains more extensions implemented directly in .NET, so the whole process can run managed, eyeglasses without prescription 64bit (AnyCPU if you want) fully taking advantage of .NET framework. See following section for new extensions.
Beside new extensions, Phalanger gets more PDO and SPL functions/classes and more PHP 5.4 and 5.5 (short array syntax, function array dereferencing, indirect static method call, binary number format, new callback options, boolval() function).
Phalanger Setup contains everything developer may need for running common PHP web or application under .NET with all its advantages.
Phalanger supports more extensions now, so it allows many more popular PHP projects running natively on .NET, without any unsafe native code.
To simplify development, Phalanger comes with its integration for Visual Studio. This allows to create .NET desktop applications written in PHP, or a WebSite running on ASP.NET and compiled seamlessly from PHP. See Visual Studio Gallery for more information. Note the integration requires Phalanger to be installed using its Setup.
Phalanger is still a free software. Companies and single developers may consider visiting commercial services page for information about migration assistance, technical support or feature requests.
As a part of commercial services you can also obtain additional memcached extension for Phalanger, which was not open-sourced currently.
Don’t forget about Mono; thanks to cooperation with Mono core developers, Phalanger runs on Mono fluently. This helped both Phalanger and Mono to improve their stability and reliability.
Phalanger is growing every day. Currently there are big plans about another increase of compiled apps performance. More smart compiler stuff will be introduced, and more compiler purchase actos online configuration options will be designed.
Of course every day task is to keep up with new PHP features; Anyway great thing about Phalanger is it takes advantage of .NET, ASP.NET and IIS – most of PHP issues are simply not possible on these platforms which are continuously developed by Microsoft. In future Phalanger will get missing PHP 5.4 sweets like traits and closures rebinding.
Stay tuned on twitter or facebook group for more details. Thanks!