SitePoint Sponsor |
|
User Tag List
Results 1 to 25 of 386
-
Sep 5, 2002, 03:29 #1
- Join Date
- Jul 2001
- Location
- Scotland
- Posts
- 4,836
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Debate - .NET V. PHP: Top 6 Reasons to Use .NET
These comments are in regards to the SitePoint.com article 'Debate - .NET V. PHP: Top 6 Reasons to Use .NET'.
Not bad article, tho it does leave out alot...the advanced caching abilities, integrated web services, code-behinds, user controls, etc.
You'll prolly have to download MDAC 2.7 (http://www.microsoft.com/data/) and I would recommend downloading the full .NET SDK (http://msdn.microsoft.com/downloads/...mpositedoc.xml) tho it is 131meg.
-
Sep 5, 2002, 04:48 #2
- Join Date
- Mar 2001
- Location
- London | UK
- Posts
- 1,140
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
So, I can develop for free? What about the os for my development server? Cheeper?.......Nope.
And one major factor that hits me like a truck is the fact that MS change their development frameworks faster than I change my socks. Around in 3 or 4 years? Probably not.
And I vehemantly object to the article stating that .NET is cross-platform when there is currently only the possibility of working ports. There are many great ideas that never get past 'yeah, that's possible'.
I'm not going to get into a FW about whats best. It's one of those 'ya pays ya money, ya takes ya choice' situations. Me, I'll stick with php, but I have no probs with people using .NET, just don't keep trying to tell me that it's better.Last edited by Mincer; Sep 5, 2002 at 04:53.
-
Sep 5, 2002, 05:18 #3
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by Mincer
So, I can develop for free? What about the os for my development server? Cheeper?.......Nope.
And one major factor that hits me like a truck is the fact that MS change their development frameworks faster than I change my socks. Around in 3 or 4 years? Probably not.
And I vehemantly object to the article stating that .NET is cross-platform when there is currently only the possibility of working ports. There are many great ideas that never get past 'yeah, that's possible'.
I'm not going to get into a FW about whats best. It's one of those 'ya pays ya money, ya takes ya choice' situations. Me, I'll stick with php, but I have no probs with people using .NET, just don't keep trying to tell me that it's better.
And dhtmlgod, I intentionally left out elements such as the datagrid, since they are quite complex, and I quite honestly don't understand them well enough to explain them in a simple manner. I probably did make a mistake in leaving out user controls, though.Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
-
Sep 5, 2002, 05:22 #4
- Join Date
- Mar 2001
- Location
- London | UK
- Posts
- 1,140
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by M. Johansson
I never said it is cross-platform in the article.Originally in the Sitepoint artile
6. It's Cross-PlatformLast edited by Mincer; Sep 5, 2002 at 05:26.
-
Sep 5, 2002, 05:28 #5
- Join Date
- Jun 2001
- Location
- Toronto, Canada
- Posts
- 9,123
- Mentioned
- 2 Post(s)
- Tagged
- 0 Thread(s)
It's cross platform in the same way Java was when it was released. The Unix implementation for Java took nearly 1.5 years from release time for Sun to finish. The only difference is that Microsoft is choosing not to make .NET cross platform, but to encourage and allow it.
A valid enough stance, as it means the open source community can in fact make a better implementation than MS would likely do on their own
-
Sep 5, 2002, 05:29 #6
- Join Date
- Jul 2001
- Location
- Scotland
- Posts
- 4,836
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
My company have been commercially selling ASP.NET websites for about 4months, and in the long run it has worked out cheaper.
Due to being able to easily compile things into DLL's, alot of functionality can easily and quickly be moved onto another. So far, my development (as Lead Developer) has not cost any more, actually, thats a lie. I used to use homesite, which cost $99, but now I use the ASP.NET Web Matrix, and thats free.
The hosting might be slightly more expensive, but it works out cheaper because I spent less hours on the job, sometimes upto 60% less.
For us, moving to the .NET framework has made us more money. Thats what it boils down to.
Show me another way to package up an sections of a site and move them across to another site without changing a single thing, and with no access to the server what so ever, and I'll use it. Only if the language is similar to what I use now as I don't have time or money to learn a new one.
-
Sep 5, 2002, 05:34 #7
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by Mincer
Ok then, you said 'it's cross platform', you just shortened "it is".Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
-
Sep 5, 2002, 05:38 #8
- Join Date
- Mar 2001
- Location
- London | UK
- Posts
- 1,140
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by M. Johansson
EEEP! Darn! Is that the fault of Georgina, or did I really write that? In that case, I'm a partial idiot. I'll check the original article when I get home.
-
Sep 5, 2002, 05:45 #9
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by Mincer
Passing the buck eh? You must be a manager.That way, I wouldn't have to get my coffee myself.
Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
-
Sep 5, 2002, 05:50 #10
- Join Date
- Jul 2001
- Location
- Scotland
- Posts
- 4,836
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I just had my cup taken and filled by our resident German!
-
Sep 5, 2002, 09:27 #11
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
I checked it - my original version just said "Cross Platform" as the header for that section, not "It's cross platform". Georgina messed it up, no me!
Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
-
Sep 5, 2002, 14:28 #12
- Join Date
- Nov 2000
- Location
- Switzerland
- Posts
- 2,479
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Some points I've gotta slap;
ASP.NET is written using "real" OO (Object Oriented) programming languages of your choice. PHP is just a simple scripting language in comparison to .NET languages like C++, VB.NET or C#
Microsoft has released a free development environment for ASP.NET called Web Matrix, which blows all other free development environments for PHP out of the water. It has a built-in Web server, database administration interface FTP integration, and more
Otherwise, this point that MS is encouraging cross platform support is false. I've posted this link before, quoting Bill himself;
When asked about Linux and the Mono project to clone the .Net Framework, Gates said: "they can do quite a bit, but never what we do." He said Microsoft could innovate much faster.
And it's a tragic mistake MS is making. The solution they really need to "beat" is Suns J2EE, to convince corporations to use .NET as the tool to integrate their systems. In web services terms, MS needs uptake of .NET as a server in delivering web services, not just a client consumer. But if .NET wont run on in your production level environment, you're .NOT going to use it, meaning J2EE and IBM Web Sphere are what you'll be using.
ASP.NET has some great features and the big one I think PHP can learn from it's class library. Other than that, as far as web building is concerned, ASP.NET is just ASP v4.
-
Sep 5, 2002, 15:03 #13
- Join Date
- Aug 2002
- Location
- Commonwealth of Pennsylvania
- Posts
- 232
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
5. It's Cheaper to Develop for
Didn't expect that one, did ya? It even surprised me! Due to the fact that ASP.NET is such a powerful application, and it's offered for free (including the code editor, Web server, and FTP client), I actually ended up paying less ($0) than I did for my PHP Development Environment composed of UltraEdit ($35), Bullet Proof FTP ($30) and mySQLfront ($0). With that said, hosting ASP.NET is still more expensive than PHP.
I'm sorry you wasted money
-
Sep 5, 2002, 15:08 #14
- Join Date
- Feb 2001
- Posts
- 302
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by HarryF
Some points I've gotta slap;
Actually PHP already does 90% of what any other OO language does (enough so you'd need to know quite alot about OO before you notice) and that will hit 100% in the next 2-3 releases. What's more is you find people from C++ or Java backgrounds saying they actually prefer PHP's OO support, it being a hybrid of the two and friendly to use.
PHP's OO support is very poor and no one in their right mind who is used to Java or C++ would prefer it's OO over the .net languages. You can't control access to atrributes with private/public/protected etc, something you learn quite early on with OO languages. There is no multiple inheritence, either in it's true form such as in C++ or with interfaces as in Java or C#. Plus no static members or abstract methods. PHP works fine for what it is designed for, but in terms of OO it is a mile behind true OO languages like as C#, J# or C++ and in that reespect there is no comparison.
-
Sep 5, 2002, 15:25 #15
- Join Date
- Nov 2000
- Location
- Switzerland
- Posts
- 2,479
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
You take me out of context, which now leads to irrelevant nit picking. I didn't say [all] "C++ and Java coders prefer PHP" - my point was you'll find some that do, for reasons like it isn't as strict as Java, and is easier to understand than C++
As to the rest of what you've said, saying PHP's OO support is poor is an old myth which doesn't stick. Have a good read of this thread for starters.
As to what's coming any time now to PHP, check out this list of features for the Zend 2 engine.
One special note;
* Destructors.
Having the ability to define destructors for objects can be very
useful. Destructors can log messages for debugging, close
database connections and do other clean-up work.
No mechanism for object destructors existed in the Zend Engine
1.0, although PHP had already support for registering functions
which should be run on request shutdown.
The Zend Engine 2.0 introduces a destructor concept similar to
that of other object-oriented languages, such as Java: When the
last reference to an object is destroyed the object's
destructor, which is a class method name __destruct() that
recieves no parameters, is called before the object is freed
from memory.
Example:
<?php
class MyDestructableClass {
function __construct() {
print "In constructor\n";
$this->name = 'MyDestructableClass';
}
function __destruct() {
print 'Destroying ' . $this->name . "\n";
}
}
$obj = new MyDestructableClass();
?>
Like constructors, parent destructors will not be called
implicitly by the engine. In order to run a parent destructor,
one would have to explicitly call parent::__destruct() in the
destructor body.
5.3 Why doesn't the .NET runtime offer deterministic destruction?
Because of the garbage collection algorithm. The .NET garbage collector works by periodically running through a list of all the objects that are currently being referenced by an application. All the objects that it doesn't find during this search are ready to be destroyed and the memory reclaimed. The implication of this algorithm is that the runtime doesn't get notified immediately when the final reference on an object goes away - it only finds out during the next sweep of the heap.
Futhermore, this type of algorithm works best by performing the garbage collection sweep as rarely as possible. Normally heap exhaustion is the trigger for a collection sweep.
5.4 Is the lack of deterministic destruction in .NET a problem?
It's certainly an issue that affects component design. If you have objects that maintain expensive or scarce resources (e.g. database locks), you need to provide some way for the client to tell the object to release the resource when it is done. Microsoft recommend that you provide a method called Dispose() for this purpose. However, this causes problems for distributed objects - in a distributed system who calls the Dispose() method? Some form of reference-counting or ownership-management mechanism is needed to handle distributed objects - unfortunately the runtime offers no help with this.
5.5 Does non-deterministic destruction affect the usage of COM objects from managed code?
Yes. When using a COM object from managed code, you are effectively relying on the garbage collector to call the final release on your object. If your COM object holds onto an expensive resource which is only cleaned-up after the final release, you may need to provide a new interface on your object which supports an explicit Dispose() method.
-
Sep 5, 2002, 15:53 #16
- Join Date
- Jun 2001
- Location
- Toronto, Canada
- Posts
- 9,123
- Mentioned
- 2 Post(s)
- Tagged
- 0 Thread(s)
Put it this way, of the hundreds of application developers (C++, C, Java, Delphi, etc), I haven't found any that like PHP for any other reason than it's not Microsoft. Every one I've introduced to .NET loves it.
Again, nobody's bashing PHP, but it's definitely not created, or even very often used, as an OO framework or whatever. You don't really have classes, inheritance, etc, though you can choose to use them.
As you said, it's a hybrid, which is both good and bad. Good for smaller, simpler things, bad for massively robust applications.
I'd be interested to see PHP do some of the levels of things being done with .NET already
I don't ever want PHP to die, and I don't believe .NET threatens it at all, because they fulfill 2 different goals and solve (very well in both cases I might add) 2 distinct sets of problems.
-
Sep 5, 2002, 16:01 #17
- Join Date
- Feb 2001
- Posts
- 302
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
Originally posted by HarryF
You take me out of context, which now leads to irrelevant nit picking. I didn't say [all] "C++ and Java coders prefer PHP" - my point was you'll find some that do, for reasons like it isn't as strict as Java, and is easier to understand than C++
As to the rest of what you've said, saying PHP's OO support is poor is an old myth which doesn't stick.
As for destructors I suppose I would prefer to be given the choice, but then given the choice between .net / no destructors and PHP / missing several aspects of OO, I will just suffer no destrcutors.
It's a GUI. If you like using GUIs to write your code for you, so be it. I don't think you'll find many serious programmers who do though. So "blows ... out the the water" is hype - as a text editor, tried Web Matrix and found it lacking.Last edited by neil100; Sep 5, 2002 at 16:05.
-
Sep 5, 2002, 16:23 #18
- Join Date
- Jan 2002
- Location
- Strongsville OH
- Posts
- 1,534
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I picked up asp.net about a month ago and i was not impressed very much, it was nice to seperate the presentation from the logic but to get some results from a database is ridiculous takes about 6-8 lines of code just to get the array of your data you selected to be used. i know datareader takes out a lot of crap etc but still it is more lines of code both way while in php its 2 lines top for me to get the array.
either way i will become 'proficient' in both since i do intend to go freelance web programming. personally i think asp.net is more complex than it needs to be. OOP is generally not needed in web development as harry stated. i like how php has 'its there if you need it' and you are no way attached to it.
-
Sep 5, 2002, 17:49 #19
- Join Date
- Nov 2000
- Location
- Switzerland
- Posts
- 2,479
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
What you are in effect saying is people who are not that comfortable with Java or C++ may prefer PHP and I would agree with that, but that is not what you wrote earlier.
-
Sep 5, 2002, 19:54 #20
- Join Date
- Jun 2001
- Location
- Toronto, Canada
- Posts
- 9,123
- Mentioned
- 2 Post(s)
- Tagged
- 0 Thread(s)
Because it's a pain in the ****.
-
Sep 5, 2002, 20:33 #21
- Join Date
- Apr 2001
- Location
- Canada
- Posts
- 5,458
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Jeremy: I've decided that PHP is the language I'd like to develope with. I just got into it earlier in the year, and I enjoy it enough to reccomend it to other beginners. I took a look at ASP.NET and found it slightly harder to learn. I did do research, found code snippet sites, found tutorials, and in the end, I prefer PHP. I enjoy the losely typer language. I suppost MS. I am not one of the people who will flame them in any way I can. I bought Windows. I bought Office. Heck, I even bought a Sidewinder
If I ever found that I could pick up .NET as easily as PHP, I *would* make the switch. Not that I belive that PHP is in reccession, but rather I belive there are too few ASP.NET developers and I would have a greater chance of succeeding as a ASP.NET programmer.Mike
It's not who I am underneath, but what I do that defines me.
-
Sep 5, 2002, 21:30 #22
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
It's a GUI. If you like using GUIs to write your code for you, so be it. I don't think you'll find many serious programmers who do though. So "blows ... out the the water" is hype - as a text editor, tried Web Matrix and found it lacking.
Otherwise, this point that MS is encouraging cross platform support is false. I've posted this link before, quoting Bill himself;
When asked about Linux and the Mono project to clone the .Net Framework, Gates said: "they can do quite a bit, but never what we do." He said Microsoft could innovate much faster.
.NET was .NOT made to be "easy to pick up", like PHP. .NET was designed to produce scalable, robust, efficent (web) applications. PHP was designed to achieve a desired outcome using the fastest road possible.Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
-
Sep 5, 2002, 21:59 #23
- Join Date
- Apr 2001
- Location
- None
- Posts
- 254
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
A client of mine asked me to take on a project - a database-driven web site, similar to Psoft.net - where people select one of templates and build themselves a web site. He said that I better use ".NET". I asked him why? He said that he thinks it's the way to go because he wants his site to be pretty serious. By the way - he knows nothing about programming languages, not even HTML.
I can build that web site with PHP without any problems. Why would I use .NET, pay much more for hosting etc, and at the end the product will be pretty much the same! Same database connections, same features. It's like using ASP and paying for extra modules (such as upload files) if I can use PHP and spend nothing.
Sorry but I just don't see a reason to start learning .NET because I would design database-driven sites or web apps the same way I currently do with PHP, the only difference would be - Windows hosting (worrying about hackers and viruses), MS-SQL database (costs a lot) and the server would crash more often than Linux.
I think that .NET is the way to go for huge corporations that provide WEB SERVICES, such as Hertz offering cars for rent when people buy online tickets. In my opinion .NET thing is not well suitable for in-house database-enabled web apps/sites, or small to mid-size sites, or even large sites such as Amazon.com because all they use is Oracle and I've been told PHP. All they do is search database, display results, accept payments, and some extra features.
Take FindLaw.com for example - 50.000.000 page views a month - Linux, Apache, Perl. Why use .NET?Last edited by Pweb; Sep 5, 2002 at 22:05.
-
Sep 5, 2002, 23:13 #24
- Join Date
- Jul 2001
- Location
- Italy
- Posts
- 4,514
- Mentioned
- 0 Post(s)
- Tagged
- 0 Thread(s)
I'm using php and I have no plans to use .net, actually...never say never!
My programming enviroment is C, so I use php to build my personal web site.
I have no experience on "high-level" programming but only on "low-level" ( assembler ), that's my working enviroment.
I used C++ in the past but that was an isolated experience.
That's to say that I'm out of territory.
Many good things have been said by people about php OOP.
But I would like to focus on one thing.
HarryF has rightly pointed to new improvements on php OOP, but for what I understand actually oop in php is a "work in progress".
It will change definitevely in version 5.0 which is to be expected to be release next year ( ?!? ), right ?
The main problem for me is this to write a code that is maintainable for one year...a class that will not change.
I would like to have a stable language-reference specifications.
Am I right if I said that C++ language-syntax is stable?
If I write a class with php4.2 I will use a constructor function that has the same name of the class but I will not have a destructor, if I write a class with 4.3 I will have a costructor and a destructor so a class will look slighty different even if the php developers have compability in mind so 4.2 classes are still valid.
With 5.0 It read that it will be a rivolution.
I'm not talking about oop issues or that a good php oop can be written actually too, but about language-issues.
For what I have to do php suits my needs.
I can't say anything about asp/net world.
pippo
-
Sep 5, 2002, 23:58 #25
- Join Date
- Sep 2000
- Location
- Halmstad, Sweden
- Posts
- 7,400
- Mentioned
- 1 Post(s)
- Tagged
- 0 Thread(s)
Pweb, I agree that PHP will work just as well, if not better, on small/mid size sites, and .NET is CERTAINLY not suited for beginners, like PHP is. However, .NET still holds certain advantages over PHP (just as PHP has advantages over .NET) that cannot be disregarded, and that is why I wrote the article.
And about FindLaw - it goes with that as it goes with all other technology; If it aint broke - don't fix it.
Actually PHP already does 90% of what any other OO language does (enough so you'd need to know quite alot about OO before you notice) and that will hit 100% in the next 2-3 releases. What's more is you find people from C++ or Java backgrounds saying they actually prefer PHP's OO support, it being a hybrid of the two and friendly to use.
Another thing that makes collaboration easier is the fact that ASP.NET is strongly typed – i.e. you cannot be as sloppy in your coding as you can with PHP. You must declare scope and type of variables, for instance:
Code:public int NumberOfApples; numberOfApples = 5; // or: public int NnumberOfApples = 5;
I’m not too good at explaining this, as I’ve done very little collaborative coding myself, but I’m sure someone more experienced can help me out.
Mattias Johansson
Short, Swedish, Web Developer
Buttons and Dog Tags with your custom design:
FatStatement.com
Bookmarks