View Full Version : PHP vs RoR?
chacelp
October 18th, 2007, 01:54 PM
What are everyone's thoughts on these two technologies? I am curious because as a web developer I want to know where to focus my efforts in learning these languages.
Which is faster, programming wise? Execution wise?
Which is more robust?
Which is better in a nutshell?
evildrummer
October 18th, 2007, 02:07 PM
I absolutely LOVE programming in Ruby on Rails but it isn't very good for production; it is hard to install apps on most servers and it's speed isn't so great.
PHP is super easy to learn, there are huindreds of resources and it's so easy to use. Learn that first
chacelp
October 18th, 2007, 05:25 PM
^ I agree and I am proficient with PHP. The goal of this post was to see whether I should hone my skills in more advanced php topics and maybe learn a little RoR on the side, or catch up to speed on RoR first and then pick up more php later on. I do enjoy PHP and there is a lot more to learn, but from the sounds of things I could probably pick up RoR fairly easily anyway... is that true?
joran420
October 18th, 2007, 07:39 PM
is RoR necessarilly mutually exclusive from PhP? or could you use a combination of both? I just dont know enough about RoR?
Jeff Wheeler
October 18th, 2007, 07:54 PM
Django isn’t a choice? Pylons? Ruby on Rails is better, faster and more secure than PHP, but everybody knows PHP is awful; it’s the worst of the options by far.
ajcates
October 19th, 2007, 03:00 AM
PHP + code igniter (http://codeigniter.com/) = awesomeness!!
Templarian
October 19th, 2007, 09:25 AM
I've found that most jobs in the development field use PHP so thats probably your best bet.
blazes
October 19th, 2007, 10:39 AM
Knowing php is a must. But I also love RoR. The speed isn't bad if you know how to cache things right.
simplistik
October 19th, 2007, 10:47 AM
Django isn’t a choice? Pylons? Ruby on Rails is better, faster and more secure than PHP, but everybody knows PHP is awful ...
RoR isn't "better" and it's not more secure.
If you have a crappy developer on RoR you'll get just as crappy results, as anything else.
And you can't compare a language on a framework to just a language in general, it's not fair. Of course RoR may be faster to develop in compared to say just PHP. But that's cause someone took a lot of time to do nearly all the work before the user. Ruby, Python, and PHP are all prone to the same human errors, if you're a crappy developer you're gonna be crappy in any language. However, all RDFs such as RoR, Django, CodeIgniter or Cake... so much has been built into it to help reduce those amount of errors.
I'm a PHP person myself and I can build applications ground up just as quick or quicker, and equally as secure than a RoR guy of my same level could.
My :2c:
Jerryscript
October 19th, 2007, 12:27 PM
While I won't weigh in on the VS aspect of this (they both have their +/-), I will say that there is an inherent benefit to learning any new programming or scripting language, and that is the knowledge of various programming techniques. Concentrating on any single language is a short term investment, since all languages evolve. Taking a broader approach to your research will yeild a more thorough understanding of programming techniques, instead of just the structure of a single language, and this broadened understanding will lead to more efficient code.
chacelp
October 19th, 2007, 02:07 PM
^ The last two post were what I am after. Not just an opinion since we all know what those are like... ;) But maybe some information or logic to your opinion is nice.
@Jerryscript: I agree knowledge of an array of technologies is beneficial not just in the computer arena either, and I plan to learn and even experiment some with RoR even though I will probably continue to further my skills in PHP as well.
@simplistik: I am glad someone else favors PHP and can recognize when someone says that PHP is crap that they are one of two things, ignorant when it comes to the possibilities of a language or just highly favors the oposition.
@nokrev: I value your opinion, however I don't necessarily agree with a couple of your statements. Obviously not everyone know that PHP is awful, as a matter of fact so far people seem to favor it over RoR. This isn't to say that there is a definate answer as to what is better, but from the responses that I've been getting they might not even be fair to compare as simplistik stated above.
Jeff Wheeler
October 19th, 2007, 08:23 PM
RoR isn't "better" and it's not more secure.
If you have a crappy developer on RoR you'll get just as crappy results, as anything else.
And you can't compare a language on a framework to just a language in general, it's not fair. Of course RoR may be faster to develop in compared to say just PHP. But that's cause someone took a lot of time to do nearly all the work before the user. Ruby, Python, and PHP are all prone to the same human errors, if you're a crappy developer you're gonna be crappy in any language. However, all RDFs such as RoR, Django, CodeIgniter or Cake... so much has been built into it to help reduce those amount of errors.
I'm a PHP person myself and I can build applications ground up just as quick or quicker, and equally as secure than a RoR guy of my same level could.
My :2c:
You’re absolutely correct — everything you said is completely correct. However, I suppose you pegged the nail on the head in regards to why framework apps are easier: all the hard stuff has already been done.
I think the reason it feels that PHP is inferior is the way people learn; most PHP tutorials teach people to write ****ty PHP, while most framework books and guides teach you to do it “right.”
hl
October 19th, 2007, 08:46 PM
Props to you for finally getting Jeff to actually AGREE to something :P
There's no such thing as a "right" way to do anything though. I don't think it's very easy to teach a way to do something either. It's mostly based on the programmer's logic and problem solving capability. You can teach syntax. You can jam logic, but its usage entirely dependent on the coder's natural logic.
Jeff Wheeler
October 19th, 2007, 08:56 PM
Oh, but I’m sure you recognize what I mean to say: PHP tutorials very rarely teach how to do something in a secure way, and almost always ignore speed and OO unless they’re focusing on one of those ideas. You get my drift, even if you don’t agree with it. :D
Krilnon
October 19th, 2007, 09:09 PM
I'm a PHP person myself and I can build applications ground up just as quick or quicker, and equally as secure than a RoR guy of my same level could.
What makes you say 'or quicker'?
Pasquale
October 19th, 2007, 09:19 PM
http://bodyresearch.net/larynx/im7.jpg
What makes you say 'or quicker'?
hl
October 19th, 2007, 09:22 PM
:lol:
simplistik
October 19th, 2007, 10:09 PM
What makes you say 'or quicker'?
Cause there's that possibility...
Krilnon
October 19th, 2007, 11:19 PM
Cause there's that possibility...
Okay, that works. I thought that there was a chance that you had included it for some other purpose.
@darkmotion: (-:
Jerryscript
October 20th, 2007, 12:20 AM
I think I have the perfect answer to your question, in the form of a question:
Which football team is the best in the NFL?
If you can put away your emotion and logically answer the question, the correct answer is: it depends on the year
Maybe last year PHP was better, maybe this year RoR is better, maybe next year Perl will make a comeback.
The great thing is, due to the inherent competition, and thanks to the emotional attachment of users/developers, we all benefit with improved performance and functionality.
If anyone can definitively state any one language/platform/architecture is the best to learn for the future, well I live in Vegas, and I have a proposition for you! ;)
Krilnon
October 20th, 2007, 12:36 AM
If you can put away your emotion and logically answer the question, the correct answer is: it depends on the year
Even if you're being 'logical', you still have to agree on a definition of 'best', which is generally subjective.
chacelp
October 20th, 2007, 01:05 AM
This is great...
JoshuaJonah
October 20th, 2007, 01:40 AM
Bottom-line. If something gets knarly in yer framework, sometimes you gotta break it down to the actual language your using.
Frameworks are just a pile of classes for easy use, they are not a programming language.
Thats like "designer mode" in dreamweaver, I've never seen a good site that was "designed".
Pasquale
October 20th, 2007, 03:15 AM
designer mode is for jerks.
denizengt
October 20th, 2007, 03:41 AM
PHP by a galactic mile. It's success speaks for itself.
I have yet to see a RoR app that scales *at all*.
Jeff Wheeler
October 20th, 2007, 08:20 AM
I’d like to see a more efficient PHP app (especially more effecient than Django, which is miles ahead of Rails in terms of scalability and speed).
evildrummer
October 21st, 2007, 05:34 AM
^ No-one said Django sucks, just that Rails sucks at any big apps that need to be scaled. Even the twitter makers said they are no facing lots of problems using rails.
Esherido
October 21st, 2007, 09:57 AM
I learned PHP so that I could actually make things and do stuff; then I learned Ruby on Rails so that I could make better PHP. The only really great thing RoR ever did for me was to inspire me to make better PHP; for actually applications, PHP is by far better than RoR IMO. Django is a really good framework, but it's kind of hard to get started using it, and it still has a lot of stuff to be ironed out.
Ordinathorreur
December 10th, 2007, 03:04 AM
oh man, this thread is a keeper! :)
icio
December 10th, 2007, 09:09 AM
I suggest at some point you try out a framework for your language of choice. I was always sceptical myself because I didn't really trust the work that other people did in PHP - and I still don't given the many many tutorials out there, as nokrev said.
But if you find yourself a framework, dip inside the code of it and make sure that it's got some nicely written code - this was the turning point for me - and make sure that it lists security in it's features.
Once I started using the CodeIgniter framework I started to enjoy using PHP considerably more. I didn't have to worry so much about structuring my pages in a certain way and including files at the top of all of my pages to make sure that the user is logged in and I didn't have to have 10 lines or so checking for GET/POST vars and making sure that the user hasn't put in something suspicious ... and not having to think about these things with every single little script is great.
It frees up your mind to think about the actual task at hand and aiming to your objective. Consider also an MVC framework (which CodeIgniter and RoR both are) because it's also a delight to work with.
If I learned another language I'd probably consider Perl.
Esherido
December 10th, 2007, 10:13 AM
^ CodeIgniter is pretty nice, but seeing all of its features and it's MVC power, I do worry a bit about performance. Does anyone have any input about the overall performance of CodeIgniter powered applications? :q:
icio
December 10th, 2007, 01:08 PM
^ CodeIgniter is pretty nice, but seeing all of its features and it's MVC power, I do worry a bit about performance. Does anyone have any input about the overall performance of CodeIgniter powered applications? :q:
It's actually pretty lightweight. That was one of their targets when writing it.
evildrummer
December 10th, 2007, 04:38 PM
CodeIgniter is really good, but for two current projects I am doing I'm using CakePHP, which is also really nice. 1.2 is going to be a really awesome release.
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.