Comparing Rails vs. PHP with a non-technical audience

I recently got an interview with a small company that wants to significantly increase its presence on the Internet, including republishing its Flash homepage and opening an e-commerce site. If I held this position, I would be the only staff developer.

I have been working with Rails for several years and have not looked at PHP for quite some time. However, if I were to get a job, I would be able to recommend the structure, as the staff no longer had people who could approach the development.

I think that for many non-programmers, PHP still has a huge recognition of names as a language for creating sites, so it acts as a logical default for many companies.

If I was offered this job, how can I compare the pros and cons of Rails vs PHP (with the appropriate structure) without falling into technical terminology? The key point here is that there are probably much more LAMP developers in this area than Rails developers, and I don’t want my personal preferences to affect the long-term stability of the code base.

Or should I just accept that the PHP / Zend site is as good as the Rails site, even if it is less interesting for development?

(Please, no religious arguments!)

+4
source share
5 answers

I would not argue that Rails is better than PHP, or something like that, because these people do not care. What they care about:

  • that they get a good site (hence, use Rails because you are better off with it) and
  • that this will not be a burden to support (therefore, use PHP because it is easier to find programmers)

Just let them know these facts and prove your point in that direction so that they decide. It's also worth mentioning that Rails is a growing community (if I count blogs ...) and developer accessibility will get better over time.

+12
source

The first thing I have to say is that (imho) you are not right because you started with the output ("I want to do this in Rails"), and now you are looking for an excuse.

Worse, this attitude borders on negligence, because you have an ethical, if not legal duty to care for your client, and these are their needs, which you must first and foremost solve, not yours.

The same problem arose in Continue the classic ASP site or insist on changing the language?

The important point here is that with Rails (usually it means Ruby on Rails, although it could be Groovy, etc.), you are comparing the framework with the language (PHP). There are many frameworks, so many coding speed problems are reduced if they do not disappear at all, if you are comparing Ruby on Rails with PHP + some frameworks or frameworks that you are equally familiar with.

From experience, I can tell you that non-technical users will deal with some or all of the following:

  • Development cost;
  • Host cost;
  • Look and feel;
  • Site functionality;
  • Ability to search for developers;
  • Sustainability;
  • Existing functions; and
  • Risk.

(1) is controversial. Ruby on Rails is probably very fast if you do Ruby things, but can become very difficult if requirements force you to cancel your reservation. Interestingly, Microsoft stacks tend to work the same way (although they usually have more redundancy for the further dissemination of this metaphor).

This appeared in 7 reasons why I switched to PHP after 2 years on Rails . Agree or disagree, such a post makes points that you, at least, will need to consider and / or an address.

(2) I think this is a victory for PHP. PHP hosting is unusually cheap, but not so much. If the site receives a moderate amount of traffic or serious security problems arise, you will either post it on the site or use some form of VPS or dedicated hosting, after which the problem will be erased.

(3) actually no different. Ruby is an oblique two-way prototype (being integrated), etc., while PHP is more open to any Javascript infrastructure (which has advantages and disadvantages), and both can do anything in HTML and CSS.

The same applies to (4). There you cannot do anything in one that you cannot do in another.

(5) - a clear win for PHP. You can’t hire hundreds of developers, but fat, which if you switch or replace, which is easy to find other people with relevant experience is important for non-technical people (and should be important for technical people too).

(6) is either perceived or real gain for PHP. By that I mean Ruby on Rails - at least in my experience - a reputation for resource instability and / or wastefulness. Examples include publications such as Zed Shaw, the famous Rails Is A Ghetto . This is obviously rant, but there are some valid points.

(7) is interesting. Relay mandates (or rather, "have") are the basis of ORM and, like many ORM structures, they can have real problems when working with "outdated" data. I put this in quotation marks because ORM has the unpleasant habit of declaring something that has not been done as a β€œlegacy” (for example, compound keys).

If you have full control over the data model on this site and there is no existing data model to support, then this problem is probably a win for Rails, but the more restrictions you have, the more this will be a gain for PHP lightweight (usually raw SQL).

Can you take a look at Using ORM or plain SQL?

(8) really summarizes all of the above. The company will be very concerned about how predictable the end result is, and a more predictable, less sexual end result often wins.

The last thing I will say is that if you have both Rails and PHP (as you think), and you need to ask what (non-technical) advantages of Rails, maybe you need to reconsider what you do and why you do it are doing.

+20
source

Assuming that for a not-too-distant future, one team is enough, and you do not plan to leave the company at that time, then the argument is simple:

Rails gets a stable website in less time (because you are experienced with it, if not for any other reason), which means higher revenue for the company before. If in the end they need to hire another developer, the increased cost (if any) of finding / hiring someone with Rails experience will be justified.

However, I believe that Rails leads to faster development, reduces errors, simplifies extensibility, and maintains a more convenient code base. This means that the company will actually save time and money on development, now and in the end.

even if it is less interesting to develop?

I would be frank: you like working with Rails. A happy employee is more productive.

+3
source

I do not think branding is important. If a site is something better in PHP, then no argument for rails will look good. If the site is best done on rails (or django), then this should be obvious.

If you become a team with one person, I would simply create it in rails because you are a developer and what you know. Even a non-tech should see that hiring a rails developer to create a site in pure PHP is just plain stupid.

+1
source

To make a case for rails, I just show them the Zend configuration pages.

-3
source

All Articles