Suggestions for a non tech guy to teach himself Ruby on Rails

Hello everyone,

I am not a tech guy by any means. I run a small web app business out of NH and would like to teach myself how to create my own apps with ruby on rails. I took a basic HTML class in college (Graduated in May09), but cant say I remember a whole lot. I have hired a developer to help me with my start up and things have been going well, but I would like to be able to build my own applications in my spare time. I have heard of people teaching themselves (I believe the creator of Ruby on Rails, David taught himself?) and was wondering the best ways to go about it? Any must have books?

I have always been a hands on guy so the goal would be to just start getting my hands dirty, but need some direction. Any help is much appreciated.

Thanks!

Colby

Jrdn wrote:

Hello everyone,

I am not a tech guy by any means. I run a small web app business out of NH and would like to teach myself how to create my own apps with ruby on rails. I took a basic HTML class in college (Graduated in May09), but cant say I remember a whole lot.

Then there's your first step. You must learn HTML and CSS, and be able to hand-code standards-compliant Web pages, before you even think about dynamic Web application development.

I have hired a developer to help me with my start up and things have been going well, but I would like to be able to build my own applications in my spare time. I have heard of people teaching themselves (I believe the creator of Ruby on Rails, David taught himself?) and was wondering the best ways to go about it? Any must have books?

I'm completely self-taught, but I was exposed to programming concepts from an early age. I recommend something like Programming Ruby and/or Try Ruby (both on the Web). You will want to get at least a basic idea of how the language works before working with Rails. This would also be a good time to set up a version control system (I recommend Git).

When you're ready to get started with Rails, read the Rails guides at http://guides.rails.info . Also learn RSpec and Cucumber: you should do all development test-first. At the same time, learn SQL (Rails will abstract it, but you still have to understand it) and read about database normalization.

I have always been a hands on guy so the goal would be to just start getting my hands dirty, but need some direction. Any help is much appreciated.

Thanks!

Colby

Best,

In order to develop with Ruby on Rails, you'll need to understand the following:

HTML, CSS, Ruby, Rails-Framework, Javascript.

Your first step, is understanding Html and Css. Css is going to be a big hurdle for you to grasp because you have to understand the concept of DOCTYPES and how they are used in different browsers. I would start out first with reading two books on html design and css design and make sure they are separately covered books. CSS is easy to understand but because of all of the quirks with browsers, you could find your website looking horrible. You also need to understand how to use css within html to shorten the use of inline styles, which can make search engines hate your site. Some search engines, especially google, will only read a finite amount of lines and then it stops caching the site completely.

Once you feel very solid about html and css, it's time to move on to ruby. Without a fundamental knowledge of ruby, you'll find it difficult to understand the various pieces of rails, namely its objects. Ruby is an object oriented language that is fun to grasp, but if you've never programmed a single piece of code in your life, you may find it difficult to understand. I find Ruby a refreshing language, compared to languages like C++ and PHP.

After you read your first ruby book, dive into a book about ajax which will help you with understanding much of the core javascript that rails heavily utilizes.

After that, find several rails books and begin creating small applications until you get a bigger comfort level. Read the mailing list/boards often for both Ruby and Ruby on Rails, and ask a lot of questions. If you want a starter thread for rails to read more, you can use mine:

Sincerely,

Joel Dezenzio Website Bio: http://jdezenzio.com/ Rails Production Sites: http://ncaastatpages.com

Alpha Blue wrote:

In order to develop with Ruby on Rails, you'll need to understand the following:

HTML, CSS, Ruby, Rails-Framework, Javascript.

Not a bad order. I agree with most of your post, but I think you've got the wrong end of the stick in a couple of places.

Your first step, is understanding Html and Css.

Yes.

Css is going to be a big hurdle for you to grasp because you have to understand the concept of DOCTYPES and how they are used in different browsers.

Not really. There are only a couple of doctypes that you need to know about.

I would start out first with reading two books on html design and css design and make sure they are separately covered books.

Why?

CSS is easy to understand but because of all of the quirks with browsers, you could find your website looking horrible.

Yes. There are lots of good websites on the proper use of CSS.

You also need to understand how to use css within html

Very simple: don't.

to shorten the use of inline styles, which can make search engines hate your site.

That is not why you should avoid inline styles. You should avoid inline styles because, quite simply, HTML is about the logical structure of a document. Physical style information no more belongs in HTML than document content belongs in CSS.

[...]

Once you feel very solid about html and css, it's time to move on to ruby. Without a fundamental knowledge of ruby, you'll find it difficult to understand the various pieces of rails, namely its objects.

Yup.

Ruby is an object oriented language that is fun to grasp, but if you've never programmed a single piece of code in your life, you may find it difficult to understand. I find Ruby a refreshing language, compared to languages like C++ and PHP.

I completely agree.

After you read your first ruby book, dive into a book about ajax which will help you with understanding much of the core javascript that rails heavily utilizes.

Absolutely not! Start building conventional (non-Ajax) Web applications. Get comfortable with that first. Build at least one conventional app before you try Ajax. Otherwise, you will fall into the all-too-common trap of excessive reliance on JavaScript.

After that, find several rails books and begin creating small applications until you get a bigger comfort level. Read the mailing list/boards often for both Ruby and Ruby on Rails, and ask a lot of questions. If you want a starter thread for rails to read more, you can use mine:

New to Rails? Read This - Rails - Ruby-Forum

Sincerely,

Joel Dezenzio Website Bio: http://jdezenzio.com/ Rails Production Sites: http://ncaastatpages.com

Best,

You were saying the same thing as I was with regards to use of inline styles. I just used the wrong word. I used within when I meant with. I avoid inline styles like the plague. The only time I use inline styles is when I'm forced to with mailers and html content types. But, that's a different subject.

The reason why I mentioned a non-combination book with html/css and not going for that approach is just by preference. I've read a lot of html and css books and combination books. There's very few out there that really get into the developer mindset. Learning css can be difficult, especially if you don't understand browsers. Here's an example question..

Would you consider IE to be the least standard CSS 2.1 browser?

I bet it would surprise many to find out that it's actually the only browser that is fully 2.1 compliant with IE8. The only reason why people still have trouble with IE8 is because of compatibility modes which automatically forces the browser to behave as if it's IE7. And, then there's the possibility of throwing a browser into quirks mode.

Sure, you can use sites like this:

http://jigsaw.w3.org/css-validator/

.. which automatically checks and validates your css and can even remove duplicated css code and even clean it up.

.. and you can use this:

.. which will validate your html by doctype

The problem with most combination books is that they are outdated for css. Find a good css 2.1 book and learn about css. Don't mix it all together. However, you need to understand html before you can understand css. That's my opinion on the matter.

By the way, one of my favorite IE8 codebits is this one here:

<meta http-equiv="X-UA-Compatible" content="IE=8"/>

This one line tells IE8 that your site does not require any compatibility modes and makes IE8 not use compatibility mode for pages that have this, regardless if the user has compatibility mode set.

I haven't even gone into detail about 16% of the world still using IE6 which was done in a poll 6 months ago. I bet the 16% are probably all developers like us too just testing out our own sites.

As for javascript, ajax is a great book on its own. I know how you feel about non-conventional sites Marnen but the fact is most major sites use ajax, rails uses ajax, and it's something everyone who designs with rails needs to understand. It's really a no-brainer that you would learn how to design sites without ajax because that's what you are doing when you are first discovering html. It's progression. By the time you get to ajax, you will already know how to design non-conventional sites.

Alpha Blue wrote: [...]

As for javascript, ajax is a great book on its own. I know how you feel about non-conventional sites Marnen

No, apparently you don't. I love Ajax in its proper context. I've developed complex Ajax applications. I'd love to do so again. But I simply do not believe that it is at all appropriate for a Web developer to learn to use Ajax before understanding what can be done without it.

Ajax is a very useful advanced technique. It is not for beginning Web developers.

but the fact is most major sites use ajax,

Most major sites don't have beginner developers.

rails uses ajax,

No. Rails includes canned Ajax helpers. If I were doing an Ajax application in Rails, I would not use these helpers, because they commit the cardinal sin of using inline JS. I understand that this will be fixed in Rails 3, but till then I hand-code all my JavaScript, and I avoid Rails' JS helpers like the piece of garbage they are.

and it's something everyone who designs with rails needs to understand.

Not until they can handle non-Ajax development. That comes first. The fact that Rails contains Ajax helpers is a red herring: Rails contains lots of things that beginners needn't bother with.

It's really a no-brainer that you would learn how to design sites without ajax because that's what you are doing when you are first discovering html. It's progression.

I agree, but you seemed to be advocating something different.

By the time you get to ajax, you will already know how to design non-conventional sites.

You would hope. But I've seen too much unnecessary and poor-quality JS to believe that everyone realizes this.

Best,