As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 9 years ago.
We have a website that originated in 2001, which started with some simple classic ASP scripts that enabled website viewers to dynamically configure products by following a step by step process of choosing product accessories, etc, using Access as the data source. The website expanded eventually to currently keep track of a simple, small encrypted member list with usernames and passwords to enable access to restricted areas of the website.
In the future, we're planning an expansion of the website and the backend will need an overhaul obviously to a more modern, scalable framework. The first inclination is to convert the classic ASP VBscript to VB.net. Another option would be to convert the backend functionality using PHP and MySQL.
Which would be easiest to convert to, simplest to maintain and scalable for a future expansion of functionalities?
It is a matter of preference and what the team is comfortable with. If you are better aligned towards ASP then stick to that and vice virsa. There is no 'right' answer or 'right' language for the job. They both do practically the same thing albeit in different ways.
There's lots of answers. If you already have developers, then a heavy influence would be what they are comfortable with.
If you don't already have a team, then there's lots of factors to consider. You need to learn the different languages, frameworks, platforms, & databases.
Languages. This is the set of core commands that the computer recognizes. Big ones are:
VBScript
VB.NET
C#
PHP
RUBY
Frameworks. Frameworks are large libraries that do a lot of the work for you. The core of the framework will still be one of the above languages, but there are also commands that call library routines. Big ones are:
ASP.NET & ASP.NET MVC (runs VB.NET, C#.NET, & other samller languages)
CAKE (runs PHP)
Ruby on Rails (runs Ruby)
Platforms. This is the type of server running your website. The two big ones are:
Windows (can run almost anything)
Apache (can not run MS products like ASP.NET)
Databases. Several good options here. Big ones are:
MS SQL Server (requires license to be purchased, and also requires
Windows)
MySQL (Free license)
MS Access (wouldn't recommend for anything but the smallest of
projects)
There are many, many more that could be listed. I tried to hit all the big ones.
Now, with all that being said, Ruby on Rails (RoR) is the most used for new development right now (according to Google trends). Lots of online libraries & help can be found.
PHP is huge, but is declining.
If you use ASP.NET, I would recommend using MS SQL Server as the a lot of the wizards fail when using MySQL.
If you use PHP, CAKE, or RoR, then MySQL would probably be more compatible with existing libraries.
Good luck with your upgrade.
IMHO PHP is equivalent to Classic ASP for many reasons, including that it is a scripting language. If you are going to move away from Classic ASP, rather than move horizontally, I would progress by choosing .Net or Ruby.
PHP is the easiest language for writing websites and it does not lack any needed features. Development is faster and cheaper with PHP. There are more PHP coders than .NET on account of the easy learning curve. Other languages may be "faster", but unless you have a very very large scale application this speed difference is irrelevant.
You will probably be making your site from the ground up and the difference in effort to "convert" your code won't matter.
Related
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
We have developed a suite of applications using .NET MVC and are planning to migrate to an open-source platform (due to cost, maintenance, talent, exit strategy, etc.).
We are planning to build web applications (instead of web sites) using Twitter Bootstrap and KnockoutJS (possibly EmberJS but that has a higher learning hurdle). We'd like the following, what platform would you recommend?
API Driven
Ability to integrate with API's easily: Twitter, FaceBook, LinkedIn, etc.
Preferably to have ACL security included as part of framework
MVC framework
Be able to create tables as objects (similar to .NET MVC)
Wide industry adoption & support
Minimum learning curve (we are new to PHP in general)
Relatively easy to debug
We've looked into CakePHP, Zend Framework, NodeJS so far. Any suggestions among these or other suggestions?
Cheers,
Dean
Asp.net mvc 3 works pretty well on mono (and it's not about creating tables as objects, wtf?!) . If you refer to ORM or active record, any platform has them. The only cost with .net is windows hosting, everything else can be free. If you can run mono on a linux server, you solved the problem.
If your team has experience with asp.net why don't you continue leveraging it? Experienced developers are expensive and php is not like c#. Yes php is easy, it's also easy to write crappy code especially when you are not very used with the platform. Maybe php developers are cheaper than .net ones, but I think the value of a developer doesn't consist in what programming languages she knows.
At least personaly, I find it the most easy to develop with asp.net mvc as compared with php. VS is an must-have tool (and no PHP IDE matches it), C# has features php can only dream of and .net mvc is a very easy, elegant framework. For me, trying to do something serious in php is just pain. My productivity just drops with at least 50%, it's just wrestling with the mud. And I started with php, I've written my own mvc framwork in php (who hasn't...).
Plain and simple, if your team is .net based you'll have a lot of headaches when you'll move to php. And I have a feeling they won't be cheap.
You ought to consider a Ruby On Rails stack with Backbone.js+jQuery as your front end JS library.
I've been using KnockoutJS for awhile now, and while I really enjoy the MVVM pattern, it doesn't lend itself to larger front-end projects without the addition of several other JS libraries. I've yet to try Backbone.js, though, so feel free to go ahead with Knockout.
Next to Asp.net MVC 3, which is what my company uses, I'd say Rails has the widest support and fullest feature set.
Stay away from PHP if you can: http://me.veekun.com/blog/2012/04/09/php-a-fractal-of-bad-design
I've programmed for several years in PHP and it doesn't hold a candle to either Rails or Asp.net MVC.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
WordPress, Joomla, and Drupal are all in PHP. These are also by far the most widely used CMSs out there. CMSs in other languages (Plon in Python, Hippo in Java, Radiant in Ruby) only have a small fraction of that popularity. This gap is not as dramatic when it comes to other tools of web development, like frameworks, where many popular powerful frameworks exist in those languages (Django, Rails, Play, Spring Roo..etc.). Is there a particular reason for this?
I would say, at least :
Many think PHP is easy and that anyone can hack some stuff in a PHP application -- which means many will use a PHP CMS thinking they'll be able to fix / adapt stuff if needed.
PHP is free (opened, and costs no money)
same for MySQL and Apache, which are generally used with it.
Those CMSes are free (opened, and cost no money)
They have a important communities
Which means its quite easy to get support
And there are lots of plugins available
There are lots of cheap hosting services that provide PHP
Far less provide JAVA / .NET / Ruby / Python
PHP is a robust language that is forgiving to newbies. In my opinion, a lot of people begin their programming journey through learning the basics in PHP. As PHP has grown, it has become a truly object oriented language that is more than capable of efficiently running CMS. Further, PHP's integration and long history with the most popular web server software in the world, Apache, ensures that the CMS can easily be installed with little work.
PHP's original implementation was released in 1995, the first of its kind. Development of frameworks takes a long time. If you start developing today, it will take you atleast 2 years to reach the level wordpress has reached today given that you "copy" wordpress. RoR was released in 2004 or 5. You can see the difference.
In essence, PHP has been around for a lot longer than a few of those languages (especially Ruby) and it's a vastly more common "base" install on low-end servers. As such, it's inevitably going to be targeted a lot more by people wanting to create such CMSes.
That said, without wishing to comment on the CMSes you list, popular does not necessarily equate to good.
I'm going to say that they're likely as popular as they are because they are written in PHP.
PHP has a very large install base, and is available on nearly every hosting platform, unlike Python & Ruby. The barrier to entry is low for someone setting up a website, when the hosting provider provides a script to install a PHP CMS in a couple of clicks.
As a CMS (or any package) becomes more popular, if it is open source as all those PHP CMS applications are, it will attract more developers which may result in more features and more popularity. Rinse, repeat. Case in point: Drupal.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 11 years ago.
The very famous open source CMS and e-commerce applications, i.e. Wordpress, Joomla, Drupal, Prestashop, are all written in PHP.
But Ruby seems to be awesome (I don't know it that much).
Why is there no such project written in Ruby?
Or would there be one I do not know?
I would say that at least one good reason is that Ruby is not used that much.
As a consequence :
Not many people use Ruby
So not many entreprises will use Ruby for their commercial projects
So not many people will learn Ruby (either at work or at school)
So not many applications are developped in Ruby
So not many web-servers (I'm especially thinking about shared hosting) have Ruby installed
So not many developper will use Ruby -- they want their open-source applications to run everywhere,
and so on ;-)
Just heard of : http://www.locomotivecms.com/
I've not tested it yet but it looks interesting.
I'm actually a php developer, working lot with Joomla, but I'll soon begin learning Ruby (some features just look awesome!, Like redefining operators,...) and Ruby On Rails for personal interest.
CMS-es allow building sites, Frameworks allow building applications.
You don't build a game in Drupal. You won't even think about a large community in Joomla! No-one will even consider building a large communication-platform (chat) with Wordpress.
PHP comes from a differnet ERA. The web-era where we all build off-the-shelve sites. Where user-interaction just started becoming interesting. And where it was hard to get an affordable LAMP stack set up for your latest-greatest idea. I am talking before Y2000.
Now-a-days one can hardly build a website without Twitter connections, Facebook logins and complex backend communication with several services.
Back in the days, these kind of projects were almost always Java. They still are, to a degree. Governments, corporate portals, media: they all have complex, integrated web-environments. PHP will hardly be used for this.
While in theory something like that is possible with a CMS like Drupal, it is certainly not a cost-efficient project. A CMS was simply never meant for that.
A framework like Ruby on Rails allows you to build what your client wants, exactly: nothing more, nothing less. Which means that the end-result is not generic, but extremely opinionated. and as such, not releasable as a tool for the masses.
PHP is cheaper and easier to host on a shared-server - installing mod_php into Apache is easy, and it uses less RAM than Ruby. So more providers provide PHP-hosting, and more less-technical people use PHP software.
Ruby does have some good CMSes - e.g. Radiant or Refinery - and ecommerce solutions e.g. Spree.
CMSs are, at least originally were, end-user products. End user doesn't really care how awesome the language that the software was built on is. On the other hand, PHP has much bigger penetration with hosting sites and deployment of PHP applications mostly comes down to "unzip this to your host, go through the wizard and you're good to go". Ruby got standard way of deployment just recently. Knowing all that, developers were (and arguably still are) choosing PHP over other languages when starting to build mass-marketed products as CMSs are.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 12 years ago.
I have opened a large web project on elance for a social network. I got over 30 bids on my project and many of the providers recommended php even though they had .net knowledge. many have said that php with drupal has many advanteges over the .NET framework but did not say what they were. Its hard to believe that a scripting language has advantages over a compiled language. Am I missing something here.
PHP will run on essentially any server, for free. That's a fairly compelling feature for many folks.
There are lots of pros and cons of both, and it certainly doesn't boil down to scripting vs. compiled (incidentally, opcode caches like APC and things like Facebook's HipHop even the score on that point).
I'd say if someone's recommending PHP over ASP.NET, they code primarily in PHP. If they're recommending ASP.NET over PHP, they code primarily in ASP.NET. There's probably not much more to it than that in the responses you're getting.
Ugg, the weekly PHP vs ASP/.net argument. Let me frame it this way:
Both work. Well, actually.
Neither is really more "enterprise grade" than the other.
.Net developers (at least in my area) tend to make more. That being said, the Government "drank the microsoft Koolaid" and most jobs in my area are for government contractors. It may be different where you are.
PHP really doesn't have a great GUI yet. Not an issue to those of us who are command-line types, but it could be for you.
.net solutions tend to be relatively unified since Microsoft is driving the bus. There's about a million different ways to skin a cat in the PHP world because it is relatively fractured.
In my experience, PHP tends to be better documented with many more how-to's online. If you disagree, you might be a writer for Microsoft's tech net, which is written partially in some alien/geek mashup dialect of English.
MANY php how-tos and forums are frequented by non-native English speakers, and entire projects can be frustratingly impossible to understand because of the language barrier. It seems that Europe has picked up PHP at a higher rate than those of us in the States.
I was indirectly involved in a Microsoft Case Study that I think illustrates the difference. I worked at one Olympic non-profit on a php-based site. They opted to standardize on Microsoft and move to an entirely .net/sqlserver based. I moved over to another nearly identical non-profit (just a different sport) who was embarking on an in-house build of a PHP-based website with nearly identical functionality to the one I left.. The .net website, when completed, cost $1.5 million, involved 16 servers, and required 3 additional full-time staff hires to extend and maintain. The same level of service, programmed in-house by 3 guys on PHP in a shorter amount of time ran on 3 servers (two application, one MySQL DB) and cost about $25k when all was said and done. Microsoft published the .net solution as an official Microsoft Case Study success. You be the judge....when you compare the solutions, I'm not sure they're even. Both serve nearly identical traffic and process very similar amounts of money. I know where my time and money would go.
The most significant advantage of PHP might be that it is free and you can start developing it without having to install too many things. (Apache, PHP and an editor)
After working with the Prado framework for a while, I don't see any big differences with it anymore.
OF Course : Visual Studio makes developing and debugging ASP.NET apps a dream.
I tend to prefer c# development to php development, but both are perfectly valid choices.
One of the main advantages php has over asp.net is just the volume of ready made components, controls, libraries, and frameworks out there that are available for use.
It is entirely possible that your project could be assembled in php much faster than in asp.net if the right tools are available.
It doesn't really matter if you choose PHP or ASP.Net, both can deliver, both have a solid base, both are proven technologies. PHP is a mite cheaper, but ASP.Net is getting there.
Unless you're going to maintain the app for a long time ASP.Net's superior OOP capabilities aren't going to offer you much advantage. But if you've got a non-trival app then the multi-layered ASP.Net approach might be helpful.
Just get the coder you're most comfortable with.
I would choose ASP.NET mainly because of Visual Studios, makes programming a lot easier.
I would choose PHP mainly because of variety of frameworks, such as CodeIgniter.
As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.
Closed 10 years ago.
I'm looking for some quick thoughts about a business application I am looking to build. I'd like to separate the three layers of presentation, domain logic, and data using PHP, Python, and PostgreSQL, respectively. I would like to hear, possibly from other folks who have gone down this path before, if there are problems with this approach, if I am targeting the wrong tools, etc.
I'm looking at PHP because it is widely used, fairly mature, and I can find ample people with skills in PHP interface design.
I'm looking at Python because of the benefits of readable code, because I hear can find more Python programmers that also have subject-matter skills (in this case, finance), and it's an open source language. Plus, it seems easier to code with.
I'm looking at PostgreSQL for the transaction-level features. MySQL is also an option here, but I don't need to debate this aspect.
This is not a web application, although I would like to utilize a browser for the user interface. This is more of an Enterprise Application, but for a small business with moderate numbers of users (maybe 5-10) and a modest number of daily transactions.
What is important is that we are able to upgrade the database or domain logic or interface separate from the other layers in the future.
I'm NOT looking for a buy vs. build debate, as that's a different discussion.
Thanks for any insight
Look at Django.
Python code. A template language that permits some of the same features as PHP -- slightly different syntax.
Model is divorced from view functions ("business rules") and divorced from presentation. This is enforced throughout Django.
One of the common questions is "why can't I do -- some crazy PHP-like thing -- in the Django template?" The answer is that presentation is not processing. Do your processing in the Django view functions. Render the results as HTML in the template.
Also, Django has an ORM layer to divorce you from petty SQL considerations. MySQL or PostgreSQL are more-or-less equivalent from within Django.
Edit
"Maturity" means a lot of things. You specifically mentioned skilled people as a sign of maturity.
Django is pure Python. If you can find Python people, they can learn Django in a few days. They just have to do the tutorials.
A Django-powered site is usually Apache + some glue + Django. The glue can be mod_wsgi or mod_python or mod_fastcgi. You have to manage this configuration with some care because there are several moving parts. This, however, is the same Apache config problem you have with PHP -- nothing new here.
A Django site has one or more Django server instances, each with a settings file, a URL mapping and any number of applications. Pure Python at this point.
A Django application has URL mappings, model and views. All pure Python. Unit tested with the Django extensions to Python's own internal unittest framework.
The model uses an ORM layer. This may, perhaps, be the single most confusing thing in Django. People sometimes design very odd models because they think either too high-level-uber-generic or they think too much in SQL. Django is a middle ground of mostly object-orientation with some SQL consideration. Get this, and you're unstoppable.
A Django application may have templates, which are in their own template language. This would be about the only non-Python thing that's of much interest. You may want to add custom tags -- pure Python.
You'll probably have JavaScript (also true for PHP and every other web application framework). Nothing new here.
Since Django's admin application automatically handles basic CRUD processing, you don't have to write this. You are free to write all the transactional stuff you want. But you don't have to. This leads you to a very, very powerful hybrid.
You write a few complicated, critical transactions. Pure Python, BTW.
You don't write any of the dumb table-maintenance transactions. No code at all is superior to Python or PHP.
After you get your feet wet with the template engine and CSS's, you can tailor the admin interface to look like anything you want. This is HTML/CSS stuff, no Python or PHP.
Bottom line. Most of the skill set is Python. The ORM is -- syntactically -- Python, but requires some care in doing things simply and cleanly. The template is it's own language, but considerably simpler than PHP. The rest is SQL, Javascript, HTML, CSS, Apache and what-not.
Edit
Django Maturity
See http://www.djangoproject.com/community/ for the number of active projects.
Join http://groups.google.com/group/django-users for daily flood of emails from users.
The Django blog stretches back to '05, meaning they had years of solid experience before finally releasing 1.0 in September of '08. Development apparently began in '03.
I'm going to assume that by "business application" you mean a web application hosted in an intranet environment as opposed to some sort of SaaS application on the internet.
While you're in the process of architecting your application you need to consider the existing infrastructure and infrastructure support people of your employer/customer. Also, if the company is large enough to have things such as "approved software/hardware lists," you should be aware of those. Keep in mind that some elements of the list may be downright retarded. Don't let past mistakes dictate the architecture of your app, but in cases where they are reasonably sensible I would pick my battles and stick with your enterprise standard. This can be a real pain when you pick a development stack that really works best on Unix/Linux, and then someone tries to force onto a Windows server admined by someone who's never touched anything but ASP.NET applications.
Unless there is a particular PHP module that you intend to use that has no Python equivalent, I would drop PHP and use Django. If there is a compelling reason to use PHP, then I'd drop Python. I'm having difficulty imagining a scenario where you would want to use both at the same time.
As for PG versus MySQL, either works. Look at what you customer already has deployed, and if they have a bunch of one and little of another, pick that. If they have existing Oracle infrastructure you should consider using it. If they are an SQL Server shop...reconsider your stack and remember to pick your battles.
I can only repeat what other peoples here already said : if you choose Python for the domain layer, you won't gain anything (quite on the contrary) using PHP for the presentation layer. Others already advised Django, and that might be a pretty good choice, but there's no shortage of good Python web frameworks.
I personally agree with the second and the third points in your post. Speaking about PHP, in my opinion you can use Python also for presentation, there are many solutions (Zope, Plone ...) based on Python.
Just skip PHP and use Python (with Django, as already noticed while I typed). Django already separates the layers as you mentioned.
I have never used PgSQL myself, but I think it's mostly a matter of taste whether you prefer it over MySQL. It used to support more enterprise features than MySQL but I'm not sure if that's still true with MySQL 5.0 and 5.1. Transactions are supported in MySQL, anyway (you have to use the InnoDB table engine, however).
Just to address the MySQL vs PgSQL issues - it shouldn't matter. They're both more than capable of the task, and any reasonable framework should isolate you from the differences relatively well. I think it's down to what you use already, what people have most experience in, and if there's a feature in one or the other you think you'd benefit from.
If you have no preference, you might want to go with MySQL purely because it's more popular for web work. This translates to more examples, easier to find help, etc. I actually prefer the philosophy of PgSQL, but this isn't a good enough reason to blow against the wind.
Just to throw it out there... there are PHP frameworks utilizing MVC.
Codeigniter does simple and yet powerful things. You can definitely separate the template layer from the logic layer.