PHP Vs .NET

Discussion in 'Web Development' started by aspguy, May 12, 2009.

  1. aspguy

    aspguy New Member

    Joined:
    May 2, 2005
    Messages:
    58
    Likes Received:
    1
    Trophy Points:
    0
    I Just happen to see this and I was shocked.

    I searched on Monster /naukri and saw this astonishing results

    42 PHP jobs in bangalore India versus 128 .NET jobs.
    Out of 42 many were low paying and internship jobs

    I'll probably get a ton of :cuss: for posting this, but the fact of the matter is "how much you hate MS you cannot live without it"
     
  2. shabbir

    shabbir Administrator Staff Member

    Joined:
    Jul 12, 2004
    Messages:
    15,375
    Likes Received:
    388
    Trophy Points:
    83
    Fact remains Fact no matter how much we hate or love something
     
  3. mgm02

    mgm02 New Member

    Joined:
    Aug 6, 2009
    Messages:
    12
    Likes Received:
    0
    Trophy Points:
    0
    A recent question on Stack Overflow (and subsequent answer that I wrote for it) inspired this post. I had recently been discussing URL rewriting in depth with my brother, and have also been doing some introductory work with the routing engine in ASP.Net MVC, and the question piqued my interest since I had been meaning to look at this more closely for some time.
    The question on Stack Overflow is titled "How do I route images with ASP.Net MVC", but fundamentally the question is really asking "how can I use ASP.Net MVC to re-route URL's to actual physical files, rather than methods of a controller?"
    To be clear, lets address the conceptual differences between routing and url rewriting. Url rewriting takes the requested URL and modifies it before your code ever sees it. As far as your application is concerned, the client requested the rewritten URL. All that URL rewriting does is to change one URL into another URL, based on pattern matching.
    Routing is a different and much more powerful beast. The ASP.Net routing engine maps an URL to a "resource", based on a set of routes. The first route to match the requested URL wins the prize, and sends the request off to the resource it chooses. For the ASP.Net MVC framework (which uses System.Web.Routing under the hood), a resource is something that can handle the request object, which is always a piece of code.
    So where does that leave physical files? If a request is always parsed by the routing engine and then handed off to some function somewhere, how can we ever route a request for an image to actually return the physical image?
    Well, it takes a tiny bit of legwork, but once we're through it, I'm confident you will see the huge advantages that routing has over simple url-rewriting. We will show the equivalent of url-rewriting by handling a request for an image using an URL that doesn't map to a physical path, but be able to return the image anyway.
     
  4. naimish

    naimish New Member

    Joined:
    Jun 29, 2009
    Messages:
    1,043
    Likes Received:
    18
    Trophy Points:
    0
    Occupation:
    Software Engineer
    Location:
    On Earth
    I do agree with you, "how much you hate MS you cannot live without it" :D I just love MS
     
  5. jeklin

    jeklin Banned

    Joined:
    Feb 12, 2010
    Messages:
    15
    Likes Received:
    1
    Trophy Points:
    0
    Hello,

    One of the most confusing decisions that IT policy makers of companies come across is which way to go .NET or PHP. Both have their merits and limitations. Deciding one is entirely dependant upon your budget, technical skills, requirements and your overall corporate methodology.

    PHP is the most popular open source programming language used to build web-sites that rely upon dynamic content. PHP is free and so are almost all of its supporting tools, platforms, databases and even OS. Being Open Source it got good support, code snippets and helps at various on-line open source forums. It even got Zend optimizer which compiles the code and makes code much faster and hence making it almost equivalent to other compiled web programming options. It is fairly easy to get a PHP programmer and many of the times if you have budget constraints, you can get freelancers with excellent skills in PHP.

    .NET is really a framework, that consist of a framework with support of various programming languages e.g. C#, ASP.NET, VB.NET etc. Like many good things except air, water, sun nothing is free in the world and so is .NET However it does come up with excellent support from Microsoft, provides excellent help documentation, has excellent professionals (though none of them are cheap) to sort out any issues. Also since it is a complete framework it is used for things way above than building simple web-sites.

    Thanks.
     

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice