Alex Rivera | Logout

Is Rails hard to understand for a PHP developer?

Asked 2009-11-11T23:36:10.003
9

i know nothing about ruby but a lot about php.

when you code in ror...do you actually understand what is going on under the surface if you are a beginner? and do you HAVE TO understand it or is it good enough just to know enough to build something fast?

Looking for experiences from people who have made the transition.

Edit
Report

3 Answers

8

IMO having gone from C# to Ruby on Rails back to C#, is that you can get by with simple apps that fully meet the Rails "opinions" without knowing what goes on. However, you'll run into roadblocks the minute you have to do something that's not a trivial CRUD task or need to implement a CRUD task in a different way than the normal render a form, user hits post, basic scaffolded create controller action way. Once you hit that, you'll need to learn more of Ruby itself to figure out exactly what Rails is doing.

answered 2009-11-11T23:53:41.930
1

Get the book (+1 to Eric). Also check out http://railscasts.com/

answered 2009-11-11T23:47:54.077
0

Taking the questions in order -

These days I understand a fair bit of what's going on inside the framework - not something that was at all true when I began working with Rails (although I had been dabbling with Ruby for a few years previously)

You don't have to understand Rails, but it really, really helps to understand the MVC (Model-View-Controller) pattern. You can get a long way very quickly, but as with most things, producing something really high quality is going to require the hard work.

There are substantial differences in philosophy between Ruby and PHP as languages (IMO). Ruby is more consistent in syntax but its strong OO background means there's a non-trivial learning curve to negotiate. I think it's worth it, YMMV, why not take it for a test drive?

answered 2009-11-12T00:00:40.453

Your Answer