Discussion Locked

Add PHP to a system built in ASP (??)

0 helpful
11 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

Add PHP to a system built in ASP (??)
A company has an application that was built in ASP/SQL Server which runs on a Windows platform. A new module is being planned. A new programmer is going to build this module (ie. not the programmer who built the original system.)

The new programmer suggests writing the new code in PHP (instead of ASP). The new programmer prefers open source languages and suggests that the company should keep in mind that with the introduction of ASP.Net you never knowif Microsoft will stop supporting ASP down the road.

The question is: is it a good idea to develop the new module in PHP, or should it be written ASP, like the rest of the application. The company is conerned about 2 things: (1) how would a PHP module perform in the Windows environment? and (2) would it become an issue in the future regarding maintaining the system ie. having modules built in different languages?

Though this info is general, any input from anybody who develops web applications and has experience in this area would be appreciated.

Presently, the company is not certain if the module should be developed in PHP or ASP.

11 replies

by jay eckles

I can't answer the question for you, but I can tell you how I would look at it...

If the rest of the system is in ASP, and Microsoft stops supporting non-.Net ASP in the future, then you're going to have to rearchitect the entire application. I think that task would be easier if it was all ASP and not 90% ASP + a little PHP.

Will PHP perform according to your expectations in your environment? I have no idea, and neither does anyone else. You're going to have to do some performance testing to determine how PHP will compare to ASP. Set up some simple scripts - display 1000, 10000, or 100000 records from a database, and do it the same way but once in ASP and once in PHP. Measure the time it takes to fetch and display.

Finally, regarding maintainability. Obviously if you have a company full of ASP or Microsoft developers and this one person is the only one who knows PHP, then that person is buying himself some job security ;-). If there are no other developers or if the other developers know PHP, then it's a moot point.

Good luck.

by four-eyes

If you dont mind maintaining a system written in various programming languages, then go for it. But consider this:

1) Will your company move to .NET or open-source languages if Microsoft stops supporting ASP? If your company moves to .NET then better to have the new module written in ASP since it will be easier to migrate to code. If not, you will have to redo the whole system anyway and it would be a lot better if the guys doing the conversion only had to deal with one language instead of two.
2) If you did go cross-language, can your company afford to keep developers who can maintain the system using both ASP and PHP in the long run?
3) Like what Jay said, its a moot point if you only had one programmer and he wants to do it in PHP.

Just use your best judgement and try to focus on the long-term impact of your decision.

Best of Luck!

by gnc

I will give a perspective from a management point of view.

First, the previous responses were right on the money ? nice logic. I would advise you to keep a very - very close eye on this new programmer. One does not need an empire builder in themiddle of a close knit team.

Second, watch out for the magic term open source. Find out what your new programmer means by that and what if any affect it has on ? your ? business model.

Third, as far as never knowing if Microsoft will stop supporting ASP down the road - so what? You seem to be a Microsoft shop and as such, will you not move forward with advancements anyway? I think this is a very long road to be worried about at this time. I would be more concerned about your ? new bump in the business road ? than I would be jumping at making changes to your business platform. Besides, has anyone heard the term deprecated when speaking of Java? Things change and this sounds like an excuse to become king of the mountain.

by ethan roberts

Several of the other replies seem to question the developer's motivation (i.e., empire building) rather than the technical aspects of the question. I'll try to address a little of both.

I currently do web development using ASP, and we are considering a migration to ASP.NET sometime in the next year. In my company, we have a directive to use Microsoft technologies in our development, so I would not recommend using PHP in my current situation.

However, if I were in a more flexible environment, I would certainly consider using PHP. It's a lower-cost alternative (free but with training and migration, etc.) that's very popular, and the syntax is much in line with ASP. The first question I would have to ask, though, is how my business components are written. If all your mid-tier work is in VB/VC++ COM components, you may lose some performance in going through PHP rather than ASP. If your logic is primarily coded in the ASP pages themselves, moving to PHP isn't out of the question.

I agree that the long-term migration plan is probably the most important factor. If your shop is considering lower-cost development alternatives, by all means you should consider PHP. Perhaps look at this as a pilot project for feasibility testing. If you plan on staying MS-specific, make that part of your policy and let your staff know.

Your developer may be trying to help the company save money and move towards a more platform-agnostic development model. If your company switches to Linux servers, for example, you're already doing great with PHP. ChiliSoft ASP would also handle your ASP migration, but these are the types of things your developer may be thinking about. Ask him (or her) for a report on why this PHP migration is a good idea, both pros and cons.

Many companies are starting to investigate open-source alternatives to development. Your developer is offering you an opportunity to be one of them.

by rick1947

ASP.NET is the next logical step from ASP. It allows you to separate presentation from code, and eliminates the typical spaghetti-code effect of ASP. If your current staff can handle ASP, they will have little problem going to ASP.NET, and will be able to code in full-fledged VB.NET or C#, not just VBScript.

I would be suspicious of someone who wants to make such a radical change in your development approach. This person either wants to be the new top dog by switching to an area where he/shealready has expertise (and the rest of your staff doesn't) or lacks the necessary commitment to your organization to learn the methods which you are already using.

by landlord

As the programmer suggested, ASP.Net is undetermined. PHP is fast to learn and had many portable modules.

PHP can be as fast as ASP in SQL Server, try use ADODB.

when Using PHP , you are using an open tech that can support by yourself forever.

by brent_d

you can get php almost as fast as asp using ADODB, but since you converted over to php in the first place, chances are your going to want to switch to MYSQL(the fastest readonly db around). then when more then 5 users are connected it rips itself apart because a query locks the whole table. PHP and MYSQL are for amateurs writing blogs. Stick with asp and SQL server!

by hfuecks

It's odd that you ask a fairly specific technical question and receive some answers which amount to "fear and loathing".

First of all I wouldn't recommend anything which involves re-writing old code in another language unless the cost to do so islow. Better alternatives exist to integrate the previous code with the new "modules". If the existing ASP code is stable then any additional effort should integrate with what you have.

Of course if the existing application suffers from significant design issues, then it could be worth considering a re-write, taking advantage of the user experiences with the current code.

As to your specific questions about PHP;

(1) how would a PHP module perform in the Windows environment?

PHP will run reliably under IIS or Apache 1.3 on Windows. Under IIS you'd be able to run PHP and ASP scripts from the same server.

It performs reasonably well on Windows (and can be boosted with free accelerators on Windows e.g. http://www.turcksoft.com/en/e_mmc.htm - other "acceleration" such as that provided by Zend [http://www.zend.com] usually run on Linux only) although is significantly faster on Linux (preferably with Apache [1.3x]).

(2) would it become an issue in the future regarding maintaining the system ie. having modules built in different languages?

If they're well designed (i.e. are truly modular - have solid APIs) and you have the expertise on hand, I see no problem.

by hfuecks

If you do consider using PHP with ASP, integration of the two should be fairly easy, with both running on the same server. Both should be able to share the same database (PHP can access practically directly via their API or even via ODBC). The one area which may be tricky, if you're using ASP sessions for authentication, is how PHP can integrate smoothly with the existing system. I leave that to your programmer to resolve... You might alternatively opt to run PHP on a seperate web server and take advantage of a web services protocol such as XML-RPC or SOAP.

From the description of the problem, it sounds like we're talking about an Intranet application or something with a fairly small user base (as opposed to a large site that's publically exposed). I also assume that the budget here is fairly tight (or you'd either have more developers or employ some ASP specialists). If I'm right in those assumptions, PHP is an excellent choice.

The only cost you have with PHP is the salary of the developers using it. More to the point there is a wealth of open source code written in PHP which can significantly reduce development times. One of the best examples is eZ publish ( http://developer.ez.no ) - free under GPL - which is on the surface a pre-built content management system and below the surface an application framework, great for building PHP apps.

by bigdog

I agree that the motives of the programmer must not be self-centered. There are going to be issues when you start mixing languages together. However there are additional questions that need to be asked.

1. What is the bottomline cost for ASP code?
2. What is the cost for the PHP code?
3. What will the cost be to get them working together?
4. What is the maintenance cost?

Now you have to support 2 types of environments: PHP and ASP. What is the cost for this additional support.

There are many factors that come into question, yet the bottom line is what is the cost to do it one way versus the other.

This discussion is closed to new replies.