Why use PHP instead of ASP.NET

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

clarkkent
Forum Newbie
Posts: 2
Joined: Mon Feb 10, 2003 1:27 pm

Why use PHP instead of ASP.NET

Post by clarkkent »

:?: I am new to internet programming and I am trying to determine which technology I should use to build my site PHP or ASP.NET (some users of the site will load data into a database table, while others will view/update that data).

Why should I use PHP instead of ASP.NET.
JPlush76
Forum Regular
Posts: 819
Joined: Thu Aug 01, 2002 5:42 pm
Location: Los Angeles, CA
Contact:

Post by JPlush76 »

I use it because I can get php boxer shorts

Image

plus PHP kicks ASP just like this shirt says :)

Image

Image
User avatar
lazy_yogi
Forum Contributor
Posts: 243
Joined: Fri Jan 24, 2003 3:27 am

Post by lazy_yogi »

HAHAHAHAHAHAHAHAHAHAHAHA

I LOVE IT !
NICE ONE JIM !


PHP is very new (only about 5 yrs old) .. and so is not as popular as it will be.
But it is growing at an incredible rate. In another 5 yrs it will kick all db-backed, server-side, html-embeded languages like asp and coldfusion.

The main reason it will take over asp as no. 1 spot is that it is platform independant .. meaning u can run it on any OS.
APS is only run on microsoft systems. (And we all know that microsoft sux.)

And php is awesome and improving constantly. It soon will have way more functionality than ASP.
jason
Site Admin
Posts: 1767
Joined: Thu Apr 18, 2002 3:14 pm
Location: Montreal, CA
Contact:

Post by jason »

lazy_yogi wrote:HAHAHAHAHAHAHAHAHAHAHAHA
PHP is very new (only about 5 yrs old) .. and so is not as popular as it will be.
But it is growing at an incredible rate. In another 5 yrs it will kick all db-backed, server-side, html-embeded languages like asp and coldfusion.
.NET is even newer. PHP is more than 5 years old, more like 8 years old. Also, I don't see why in another 5 years it will do what it's already doing.
The main reason it will take over asp as no. 1 spot is that it is platform independant .. meaning u can run it on any OS.
APS is only run on microsoft systems. (And we all know that microsoft sux.)
Some say it's already the number 1 server side scripting language.
And php is awesome and improving constantly. It soon will have way more functionality than ASP.
It already does. ASP is playing catch up.
User avatar
AVATAr
Forum Regular
Posts: 524
Joined: Tue Jul 16, 2002 4:19 pm
Location: Uruguay -- Montevideo
Contact:

Post by AVATAr »

ASP.Net: First of all,... .Net is a framework, i used Asp.Net and really Interdev is a great tool. its 100% object oriented (all .Net is). ASP.Net is precompiled and you need .Net framework to make it work. You need a msft server first place!...

PHP: runs in ANY server, its free, its very powerfull, its open source, you have much more support (us :D).
fractalvibes
Forum Contributor
Posts: 335
Joined: Thu Sep 26, 2002 6:14 pm
Location: Waco, Texas

Post by fractalvibes »

An interesting thread! There is a flavor of ASP by ChiliSoft that runs on other platforms, BTW - don't know how good/stable it is.

PHP versus "Classic" ASP - PHP has far more native functionality! ASP must rely on COM+ Dlls as callable objects to even come close, and I have a deep, abiding knowledge of that which they call "Dll - Hell" - been there more than would ever wish upon others.....

I will say that Microsoft's ADO does offer some amazingly good object-oriented functionality - I could connect to my Coffee pot given the right connectionstring and that my Coffee pot were on the network...

.Net I have just scratched the surface of...I think the idea of the code being separate from the presentation a good idea, though you can also do it in a more classic way. Jury is out on .Net till I learn more about it. Everyone I know who is using it thinks it is the best thing since the wheel....

If you are starting out, I would choose PHP over ASP, especially if you don't want to buy a bunch of other software and learn a bunch of interfaces to DLLs that provide the functionality ASP lacks.

I would disagree on the degree of support you can find - there is a terrific amount of sites and lists that deal with ASP/.Net - see http://www.aspalliance.com and http://www.asptoday.com and http://www.4guysfromrolla.com for starts.

Not trying to be argumentative about the topic, but I deal with ASP 8 hours a day, 5 days a week, and have an idea of what is out there. At home I do PHP and love it! (just so long as I don't forget where I need semicolons and where I shouldn't ;-)

Phil J.
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

100+ million domains can't be wrong.
Image Image
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

Is ASP as crappy as VBscript is? E.g., just getting data from radio buttons and other form elements takes a lot...

How is ASP with linewrapping, just like VB's use of _ ?

Pretty much any language but VB uses statement termination, perl, php, c, pascal etc use semicolon, python use indentation..

It's like its always been, VB'ers are in their own box, thinkoutside! :D
fractalvibes
Forum Contributor
Posts: 335
Joined: Thu Sep 26, 2002 6:14 pm
Location: Waco, Texas

Post by fractalvibes »

Hmmmm...Ok. I like both ASP and PHP.
Difficulty with form variables? I think not - if you have a form field like:

<input type="text" name="txtUserName" size="20" maxlength="20">

Then it is just Request.Form("txtUserName") You could also just do
Request("txtUserName"), but I like to specify - saves a little time in ASP's
lookup of which collection that var is in. $txtUserName works fine in PHP,
but if I am looking at someone else's code, I won't immediately know if this is a form variable or a querystring or what...

Line wrapping - no big deal
$sqlstring = "SELECT UserName " _
& " , Password " _
& " FROM SomeTable " _
& " WHERE UserName = '" & Request.Form("txtUserName") & "'"


Statement termination?

If MyVar > 50 then
Call DoThis
Else
Call DoThat
End If

No biggie.

VBScript (what most ASP pages are written in) probably comes more naturally to me, but I love PHP also - a nice change of pace.

Try working with data from legacy systems written anywhere to 10 - 20 years ago that have been patched a zillion times! No matter the language there will be much gnashing of teeth!

Phil J.
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

What about checkboxes, and if I remember correctly, radiobuttons, they where a pain in vbscript, is it as simple as Request.Form("radioGroupName") ? if so its definetely better than vbs..

...Bill Gates thinks that a newline means statement termination even if inside a string, that's what most "different" :)
fractalvibes
Forum Contributor
Posts: 335
Joined: Thu Sep 26, 2002 6:14 pm
Location: Waco, Texas

Post by fractalvibes »

Checkboxes - give them all names and values and check for that....
RadioButtons, if you have a cluster of those - give them all the same name and Different values and check for that value. Don't use either that much myself to tell the truth.

Newlines inside a string - I hear you! Hmmm - ok, what if you used a
"_" instead in that string? Yeah, even a VBCrLf will mess it up...

ASP/PHP - both are interesting and worth learning - neither is perfection
and both have their quirks to learn. It would behoove any developer to have a familiarity with both. .Net is a totally different animal from either,
I would advise a beginner to learn the basics of ASP/PHP first.
User avatar
hob_goblin
Forum Regular
Posts: 978
Joined: Sun Apr 28, 2002 9:53 pm
Contact:

Post by hob_goblin »

PHP > ASP

But asp.net, I dont know, they seem about the same speed-wise, asp.net has tons better classes and objects and what-not... PHP's OOP and XML support blow..

But, heres why I still like PHP:

It's free.
It's easier to code in.
It evolves VERY quickly, and can use the .net framework http://www.php.net/dotnet
It gives me more of a technical bare-bones approach instead of the frilly over-savvy microsoft approach.
User avatar
phpPete
Forum Commoner
Posts: 97
Joined: Sun Aug 18, 2002 4:40 pm
Location: New Jersey

Post by phpPete »

Having just spent the better part of 3 months heavily immeresed in .NET, C# and ASP.NET I read with interest all the posts in this thread.

First things first: PHP Rocks!

Now, to the reality of it all: The whole .NET idea and accompanying framework rocks even more. C# is a better JAVA, and ASP.NET is superior to PHP ( I hate saying that ).

A few things i really like about ASP.NET:
-- better session management
-- ASP.NET has fantastic server side caching.
-- it's compiled code, no longer a scripting language
-- the code behind pages make web-apps more like applications
-- the intrinsic separation of presentation from logic
-- better for n-tier apps.
-- and thus much better scalablity

As for C# being a better JAVA, it just is.

And, Visual Studio.NET is a killer ide.
User avatar
phice
Moderator
Posts: 1416
Joined: Sat Apr 20, 2002 3:14 pm
Location: Dallas, TX
Contact:

Post by phice »

Say what you want, but Point-and-click "programming" (such as Visual *) is NOT programming.
Image Image
User avatar
phpPete
Forum Commoner
Posts: 97
Joined: Sun Aug 18, 2002 4:40 pm
Location: New Jersey

Post by phpPete »

Say what you want, but Point-and-click "programming" (such as Visual *) is NOT programming.
You are correct, to a degree. If someone can't build an application w/o a Visual programming tool/language, then I agree. However, as a programmer I'm sure you have a multitude of 'widgets', code snippets etc you have developed for resuse, and that's all the more advanced IDEs and 'Visual' languages do...offer the programmer prefabricated objects. If I'm a carpenter I'm not going to build from scratch every window that goes into a house when there are prefab windows available.

Of course there are those programmers who insist on coding everything in Notepad, now that's productive.
Post Reply