Does anyone out there know if it's possible (and if there's any complications with) using the PHP language inside a .NET C# project?
I understand that with VB and C# can be now mixed in solutions, so I wondered if, as IIS is now capable of running PHP, you can combine them into a singular runtime?
Obviously the reason for asking is to be able to get the same developers to work on the same parts of a single Web Service without having to learn C#/PHP - although I do know that working with the same language here is the ideal scenario.
You can run PHP apps on IIS.
You won't be able to combine an ASP.NET and a PHP app in a same runtime, but you can host them within the same IIS server and make them communicate through (for example) a RESTful interface.
For the sake of simplicity, I would host PHP app as a separate website from ASP.NET' one. Given said that, technically, nothing forbids you to host both PHP and ASP.NET from the same website (if, for example, you have a constraint at hosting level).
Mixing several languages (such as Python and Java, or PHP and C++) within an app is currently used for large apps when people with different backgrounds and language preferences won't have to know the whole system anyway. This being said:
This requires a well-done architecture with a well-done interface which will never or rarely change until the end of the project. Changing the interface between PHP part and ASP.NET part of the app will be disastrous for the schedule of most projects.
Doing it for small projects is an overkill. You'll end up being forced to learn both languages anyway.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With