• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar

I Like Kill Nerds

The blog of Australian Front End / Aurelia Javascript Developer & brewing aficionado Dwayne Charrington // Aurelia.io Core Team member.

  • Home
  • Aurelia 2
  • Aurelia 1
  • About
  • Aurelia 2 Consulting/Freelance Work

Learning From Ruby on Rails To Build Better PHP Projects

General · October 4, 2012

I can hear the Rails purists slicing open the soft flesh of their vitamin D-less wrists now. Are you crazy? PHP sucks, lets all build applications using Ruby on Rails because it is after all the better language right? This is not a language debate, this isn’t about one language being better than the other.

Recently I’ve had this obsession with browsing through various RoR projects on Github and came to a realistion about a week ago. The Codeigniter PHP framework which I am an avid user of (as most of you know) is based on the same kind of structure as Ruby on Rails, so I got to thinking — why not learn other RoR projects?

Building a Twitter clone in PHP? Checkout one of the countless Twitter clones done in Rails because that’s what the actual Twitter is built in and people wanted to see if they could replicate the site. Not only do you get to see what controllers and models you need to have (some don’t apply), but you also get the value added of being able to see the database schema (creating a proper database schema is something a lot of people fail at). Database architecture is hard.

Want to see how you should map out a database for a Facebook like social network? Checkout the database schema of Diaspora — although databases are interacted with somewhat differently in Rails compared to Codeigniter, you can see what goes into mapping the database and then check out the controllers and models to see what else makes up the site.

This approach goes for any language application, Rails is similar to Codeigniter so I believe it’s an easier choice if you’re wanting to see how something is done.

Dwayne

Leave a Reply Cancel reply

0 Comments
Inline Feedbacks
View all comments

Primary Sidebar

Popular

  • Testing Event Listeners In Jest (Without Using A Library)
  • How To Get The Hash of A File In Node.js
  • Waiting for an Element to Exist With JavaScript
  • Thoughts on the Flipper Zero
  • How To Get Last 4 Digits of A Credit Card Number in Javascript
  • How To Paginate An Array In Javascript
  • How To Mock uuid In Jest
  • How to Copy Files Using the Copy Webpack Plugin (without copying the entire folder structure)
  • Reliably waiting for network responses in Playwright
  • Wild Natural Deodorant Review

Recent Comments

  • Dwayne on Is Asking Developers How to Write FizzBuzz Outdated?
  • kevmeister68 on Is Asking Developers How to Write FizzBuzz Outdated?
  • Kevmeister68 on Start-Ups and Companies That Embrace Work From Anywhere Will Be More Likely to Survive the Coming Recession in 2023
  • kevmeister68 on What Would Get People Back Into the Office?
  • Dwayne on PHP Will Not Die

Copyright © 2023 · Dwayne Charrington · Log in

wpDiscuz