Re: PHP or COLDFUSION

From: Karim (karim3411_at_yahoo.moc)
Date: 11/06/03


Date: Thu, 6 Nov 2003 09:12:13 -0800

On Thu, 06 Nov 2003 11:27:18 +1100, Terence wrote:

>> PHP might have more functionality but .NET is geared towars Windows only as
>> expected from all MS products.
>
> I have no problems with windows, and just because I think PHP is OK
> doesn't mean I'm anti-microsoft, it's more IIS that irks me. But that's
> just my opinion based on this product's horrific record of exploits.
> Havint said that, at least I am willing to give ASP.NET a go anyway.
> Have you at least done some tutorials in PHP let alone read a book on it?

These major exploits, maybe 3 of them, happened quite some time ago. So far
I haven't heard of new ones. Apache suffers from them too. We hear about
website defacements, many of them are on Apache/Linux.
PHP doesn't offer anything that I can't do in ASP.NET. No sense in learning
two different languages.

>
>> No.. you will not find functions that
>> support MySQL or Postgres but if you're on Windows, you really don't care
>> and if you do want to use something like MySQL, there are free drivers out
>> there that you can use. It's not a dead end.
>>
>
> Well as a windows programmer, I thought that would be obvious in light
> of ODBC. PHP's database support, while comprehensive, is not remarkable.
> It's the some total of all this and all the other functionality that
> makes it remarkable.

It's the productivity that matters.
What are the capabilities of debugging in PHP using the best IDE? Can you
set breakpoints, resume running, view and edit all variables in debug mode,
line by line trace output, try-catch-throw error trapping ..etc?

>
>> I haven't used PHP but I am pretty sure it doesn't support server controls
>> like a datagrid where you can drag and drop a grid, set some properties and
>> have a grid where you can insert, edit and update values, do validation,
>> sort and paginate right away. I am sure PHP can do all this but it's not
>> going to be done in as productive way like asp.net. You will need to a ton
>> of code where asp.net already has it done for you and if you need to etend
>> on a server control, the open hooks are there.
>> .NET is *fully* OO while php 5 is going there. You have visual
>> inheritance, code behind in a file seperated from the html file...etc.
>>
>
> This is where it is futile trying to debate a language vs a framework.
> PHP is a programming language with lots of functionaltiy. It is not
> tightly bound to any one framework like ASP.NET. The same goes for CF.
> For PHP and CF, frameworks are a separate thing and there are many of
> them avilable to choose from, that's why you don't have HTML and web
> controls.

The funtionality in PHP is based on available libraries. The .NET framework
is also a set of libraries. Same thing.. different nomenclature. You take
away php libraries and php becomes very weak. In the Windows world, both
are implemented as DLLs.

One advantage of .NET is that you can build web applications, Windows apps
,Windows forms, Web services. Basically anything which means you learn one
language and one framework. PHP is good for web development only.
Web controls in ASP.NET are high productivity tools. If I want a a tree
view or a grid, I plug them in and use them right away. They come with
asp.net and are free.
In php, you have to code them yourself or buy them and if you want to
deploy them, you have to include them with your site.

> ASP.NET framework has it's archicture centrered around Visual Studio.
> Now that's not neccesarily a bad thing if authoring environment is
> paramount to your web apps development. Visual Studio is an excellent
> package, I use it on a daily basis. To make things easy, the bundle a
> bunch of layout (HTML markup) components that you can drag and drop.
> They provide interfaces to make data-binding easy. The end reasult is
> rapid development of functional web pages. That's great.

No. Visual Studio is a tool. .NET is not tied around VS. You can write
asp.net apps in NotePad, in Web Matrix, Borland's C# Builder. VS is just an
IDE to increase your producivity. Everything VS does is eventually
converted into html in aspx files and/or code in code behind files. You can
do this manually if you want to. but why.

> What I don't like about it is that the components it gives you are in a
> dead-end format, they are in HTML. So again, we go back to the bad old
> days of having compatability issues with user-agents -- not to mention
> the obvious inflexibility of using a dead-end format. I think MS had to
> do this in order to keep integration with Visual Studio simple. For a
> lot of people (who don't know much about modern web apps and XML/XSLT),
> this is fine, it "gets the job done". For these people it is not a
> problem because they are usually the type that couldn't be bothered with
> user-agent compatability and W3C standards.

Of course they have to be in html. Otherwise how can they be displayed in a
web browser. Everything you do in any scripting language will be converted
into html, Javascript, CSS... etc. If there are compatibility issues (which
I haven't seen) then code in pure hand coded html in asp.net.
asp.net produces html so what does a deadend format mean exactly?

> If you're trying to deliver flexible non-dead-end solutions, then you
> cannot use the bundled HTML and web controls. You will still have to
> "roll you own" architecure. Now this is entirely possible, but then you
> cannot sing the joys of ASP.NET which is basically "web apps for Visual
> Studio" because now you're not really taking full advantage of the
> Visual Studio components development methodology(?). You can then go on
> to use ASP to develop propper XML/XSLT applications, but then it has no
> serious advantages over any other web technology including Java, CF, and
> PHP.

Do you have an example of a web control in VS that produces html that
doesn't display correctly in all browsers?

Some web designers develop for Intranets and specific websites that can use
IE only. VS should be perfectly fine for them.

>
>
>>
>> php has a ton of functions but you're still writing spaghetti code which is
>> hard to maintain.
>>
>
> Well the choice is yours. If you feel compelled to write spagetti code,
> you can. If you prefer to do object modelling, you can do that in PHP too.
>
> If I chose, to, I could write spagettig code in ASP.NET too (without
> trying too hard). At the end of the day, an ASP.NET page is == a single
> page object instance which is just a collection of functions and variables.

How's that different than php and any scripting langauge? Your final
objective is a web page, regardless of the language and tool you used.

>
>> When Mono on Linux is fully ready, then the ".NET works only in Windows"
>> excuse is not going to fly anymore. Besides,
>
> excuses? what excuses?

The excuse of .NET and ASP.NET works in Windows only. No cross platform
compatibility.

> I've been following the Mono project with some interest. It will be
> interesting to see if it will provide a strong enough alternative to the
> MS version.
>
> MS make all this fuss about how the Common Language Runtime is a
> ratified standard and all, but then they don't grow the thing the same
> as Sun does. Sun doesn't see the provision of J2EE platforms by other
> vendors as a threat -- quite the opposite, they set up frameoworks and
> specifications and certification programs to make it happen. That's why
> you have IBM, BEA, Oracle as J2EE platform providers. I can't see this
> ever happening with Microsoft. I don't see MS actively supporting
> commercial companies like Sun does. If I have any complaints about Sun,
> it's the lack of support they have given to JBoss but I think there are
> other issues there that I am not aware of so I can't be too critical.

ASP.NET 2.0 is coming out soon and yes MS is enhancing it. Java/J2EE is
older and therefore more mature. BTW, I thought we are talking about PHP
and you're diverting into a different topic.

>
> > when you create a website, it
>> doesn't matter where it's running on since all you care is that your site
>> works right under all the common browsers.
>
> In my experience, I haven't found this to be the case in real-life. You
> may be able to take this position as an individual developer, but IT
> departments are usually given a limited budget so they may not be able
> to just rush out and purchase new talent because one of their developers
> wants to use Visual Studio to make web apps. IT managers are sometimes
> forced to make comprimises based on their given environment which
> supports more than just web applications.

Many small companies are Windows only. When they want to develop web sites,
they will likely choose a Microsoft product and they do not have to pay
extra for the tools. IIS, ASP, .NET are free in Windows. They do not need
to retrain their developers. A VB developer can easily pick up ASP and use
it.

>> If it runs in Windows only, you
>> hire people who know Windows and .NET to maintain it and they are plenty
>> and more every day. .NET is not some old legacy language/framework where
>> you worry that it it runs on a certain OS only. To many people and
>> companies, cross platform compatibility is not an issue, specially in
>> Windows only shops.
>
> Anyway, I believe the original question was about CF vs PHP. As such, I
> recomend PHP for medium to large apps in concert with a decent framework
> (such as XAO). Otherwise, if you're basically a DreamWeaver person with
> not much interest other than processing a couple of forms, the CF has
> the shortest learning curve.
>
> When it comes to speaking broadly about technology choices, I think the
> discussion should be centrered on frameworks, and to that end, the best
> one I've seen to date is Cocoon.

So what's your gripe about .NET framework if now you're saying one should
concentrate on frameworks? Remember I said that .NET is a framework for
building *any* kind of app for Windows. web, Windows, mobile, web services.
With C#, you learn and use a single language and learn one framework. I
don't see the same advantage with php.

A strong language, a comprehensive framework, a mature productive IDE.
You need to tell me what's so compelling about PHP that I should switch.
You need to provide proof, examples case studies. Otherwise, we can talk
forever.

 
> Karim, instead of being so religious about defending your favourite
> product, do yourself a favour and try writing an app or two in something
> else, starting with Cocoon :)

If you're debating with me, then you're religious too with your opinions.
I have no interest in learning php. I would rather be a master of one
language and framework than an ok with two. .NET is huge and I learn new
stuff every day. It will be unproductive to add a new language and
technology to my learning capacity.

The point is that if what I am using does everything I need it to do plus
much more and I am very productive with it, why would I look at something
else. You have not convinced me otherwise.

I will be interested in why something is done better in php than asp.net.

I gave you an example of a datagrid web control in asp.net. Many people
find it very productive. Now tell me what I can do in php better or faster
than in asp.net. Convince me with an example. Let's assume we both are
using SQL Server and IIS.

Karim



Relevant Pages

  • Re: PHP running exec() Windows program very slow in comparison to UNIX equivalent program
    ... So, by converting a VB6 DLL into a COM and calling the COM from PHP I am able to work around the speed limitations of swetest.exe, PHP, and Windows. ... I wrote a little program in VB5 that essentially does what this other compiled C Windows program does in just one of the loops that gets executed about 140 times. ... the other thing is how long it takes to to execute the program with those statements from a command prompt. ...
    (alt.php)
  • RE: phpBB Worm
    ... the getpwent function is not supported on Windows. ... it probably depends on the web server ... I looked at the decoded Perl script, ... was invoked by PHP, which should have the Web server's permissions, ...
    (Bugtraq)
  • Re: MS Access im Intranet / Internet
    ... Ich habe nichts gegen Webanwendungen, ... dass in Access als dafuer ... > MS Windows, MS IE. ... PHP oder ASP oder ASP.net ...
    (microsoft.public.de.access)
  • Re: Developing PHP under Windows - Why?
    ... Windows 2000, Apache 2, Microsoft SQL Server, and PHP. ... We went with the Windows route mainly for human resource reason. ... I knew virtually nothing about Linux at the time - and very little about Apache. ...
    (comp.lang.php)
  • Re: Looking for e-commerce recommendations
    ... I believe Miva is a CGI/Pearl type script. ... I'm certain OS Commerce is PHP ... regarding the fp extensions/ windows environment: ... runs surprisingly well on a windows server so it'll be OK. ...
    (microsoft.public.frontpage.programming)