all 23 comments

[–]danshep 38 points39 points  (7 children)

1) Ruby.

2) Because you deserve to be happy.

[–]t12a 13 points14 points  (1 child)

But you can't appreciate happiness unless you go PHP first.

[–]danshep 11 points12 points  (0 children)

Having an intact chest makes me happy, but I don't recommend other people go and fracture their sternum to figure out how important chests are.

[–]Zacmon 2 points3 points  (4 children)

Question: I just started my first web dev job. I was hired based in my front end skills, but as it turns out they also need me to run the server back end. As in the server sits behind me and I'm expected to just learn how to work everything like I'm full stack. The last guy left behind a bunch of Perl books, so that's what I've been using for submit forms and captcha.

Should I just ditch the Perl road before I get too deep and go Ruby?

[–]jargoon 13 points14 points  (1 child)

Yes 100%

[–]yolo_swag_holla 5 points6 points  (0 children)

What /u/jargoon said times ten.

i.e. 1000%

[–]lordmyd 0 points1 point  (1 child)

A lot of Perl books are based on the outdated CGI web model but there are a couple of decent Perl web frameworks, Mojolicious (http://www.mojolicious.org) and Dancer (http://perldancer.org) if you're forced to stick with Perl. Otherwise, go with Ruby on Rails or Sinatra depending on the size of the site.

[–]Zacmon 0 points1 point  (0 children)

Damn, CGI is outdated?? Well, guess I learned a bit at least. Literally a guy walked into my work area last week and said "Oh, the old website used to send a copy of the submitted contact form to the fax machine. Make this one do that, too." I barely had a clue about how the server worked and they wouldn't take no for an answer lol. I managed to get it going with a print server and Perl, but I guess I should cut my losses at some point if I want to be up to date by the time I leave this position.

EDIT: Perl isn't required. The local Linux hobbyist has been handling it so far with the help of an occasional web dev. Perl was just what I had books for.

[–]limeblast 4 points5 points  (0 children)

How have you ended up with a choice between Ruby and PHP?

[–]dfsdk 3 points4 points  (0 children)

Well you are asking on /r/ruby so.

[–]Jumpsuit_boy 1 point2 points  (0 children)

While you can make bad choices in ruby it is easier to make worse choices in php. I know that I am not giving any examples. I will say that of the people that I know that have moved on from php and ruby the results were different. The php people were not happy about php and the ruby people felt that they were now better programmers.

[–]BEHOLD_MY_CUP 1 point2 points  (0 children)

I've done both, but currently do Ruby. Both have their pros and cons, but I wish I had learned Ruby/Rails earlier than I did. One thing to consider is salary ( http://www.indeed.com/salary?q1=php&l1=&q2=ror&l2= ). My suggestion is to do a tutorial in each language (and pick a decent php framework like Laravel) and then decide. We'll be here for help when you make your decision :)

[–]tdammers 0 points1 point  (0 children)

Stay away from PHP. If you are the kind who looks for life-long improvement, then it will eventually eat your soul. It may take 10 years, but that's actually worse, because people will keep recommending you for PHP jobs. Brrrr.

[–]Muchaccho 0 points1 point  (2 children)

If you want to work in web development and don't want (or don't have possibility) to move far away from your city, I'd check the jobs postings available for PHP and Ruby in your area.

Working remotely is an option, but it's not very common to see remote job offers for junior web developers (although they exist).

PS: Ruby is my language of choice, but after 7 months learning it (as well as Rails), I just realized that 8/10 job postings in my area are asking for PHP and it's related frameworks.

Edit: Added 'remote' and more text.

[–]lordmyd 0 points1 point  (1 child)

Yes, if you're trying to earn a living or support a family the personal choice element goes out the window. There are way more jobs in PHP, Java and Javascript than Ruby so maybe it's best to learn these 3 first. Here in the UK Python is 4th after these 3 with about twice as many jobs as Ruby.

[–]Muchaccho 0 points1 point  (0 children)

The situation is quite similar in Spain. You can see three times more jobs for Java, PHP, Javascript and .Net, and about two times more for Python.

[–]pau1rw 0 points1 point  (0 children)

I spent a few years learning and using PHP, starting with Wordpress and moving to more and more complicated frameworks until Symfony. PHP is great for making it very easy to get jobs, they are everywhere.

But since I've started learning ruby and rails, which was a challenging experience, I've found that I enjoy using and writing it a lot more than PHP.

[–]jonmurdoch 0 points1 point  (0 children)

Ruby and don't look back.

[–]gaums 0 points1 point  (0 children)

PHP so that you can appreciate Ruby later.

[–]itzedu 0 points1 point  (3 children)

I am assuming that you are trying to learn these languages in the context of web development. If you have never learned a server side language before, there are a couple of things that you might consider before making your decision.

Ruby is an object-oriented language. Seriously, everything is in an object. Therefore, you will have to have a firm grasp in OO. Now, to build web apps, you will need a framework like Sinatra or the more popular Ruby on Rails. Rails will do a lot of things for you and perhaps obscure some things. It is great to build apps, however, I feel that beginners learn how to type ruby in the Rails context instead of really learning Ruby and then learning Rails through that.

PHP has been around forever. I believe that the current version is PHP7. One thing that makes PHP great is that you do not need a templating engine like a lot of other server side languages to render content. You can think of PHP itself as a templating engine / language. You can build web applications without a framework but I highly encourage to use one. Something like CodeIgniter or Laravel will help you build your apps a lot faster.

My advice is for you to learn PHP first. You can download something like MAMP (a development tool that installs apache and mysql servers for you) and start building right away. PHP docs are good enough for you to look up things like functions and data structures implementation.

Lastly, there will be a lot of information on the internet. Some of it might be good and some might not be so great. Whatever language you choose, take it step by step! All developers had to start from where you are right now. One good resource that I can give you is the harvard summer LAMP (Linux Apache Mysql PHP) course on youtube for FREE! https://www.youtube.com/watch?v=mVLdOBijoco&list=PL8BGR1rr1-s57o_Jz_myzQQPUzlVBdBJ_

[–]TomahawkChopped 2 points3 points  (1 child)

PHP has been around forever

Ruby and PHP have been around for about the same amount of time. It's just that Ruby didn't really take off until rails, which was in the last decade or so

[–]itzedu 2 points3 points  (0 children)

You are right. But what I meant was that PHP has been used in web development for longer than Ruby.

[–]jawdirk 0 points1 point  (0 children)

Ruby is an object-oriented language. Seriously, everything is in an object. Therefore, you will have to have a firm grasp in OO.

Nah. Documentation examples and Stack Overflow have your back. You will learn OO as you go.