Ruby on Rails for Social networking
Page content

Introduction

The Ruby on Rails framework offers an ideal framework for developing community based web sites or social networking sites. It allows for dynamic, customisable content, through PHP and other supported languages, and many popular social networking sites, such as Myspace or Facebook, are based on the Rails framework.

Moving from static content, you can gradually expand the site you are building, through user registration and authentication moving onto image uploads, personal blogs and friendship request systems, in order to build a highly dynamic social networking site.

Why Ruby on Rails is Suitable

There are many aspects to the structure of a social network, such as creating, modifying and maintaining a database in MySQL, using Ajax, being able to use PHP and others. However, Rails provides the flexibility needed when developing a social network, particularly as a framework optimised to be used in the new Web 2.0 standard.

There is also the possibility of using related plug-ins and additional related items which allow for developing such a website with more ease. Sites such as Friendster and Myspace make use of these plug-ins and they have proved hugely successful over time, with their clean layout and simple navigation structure. Additional content also allows for easier customisation on the side of the user, and this is very useful when building a site centred upon a community base.

Ideas on Plug-ins and Deployment

Here is a basic overview of what plugins are available for ROR, and some simple ideas on deployment which should give you some insight on what the development of a social network involves.

Some plug-ins available and other items which are added within your code:

  • Acts_as_commentable: allows for user comments on existing profiles, and can also act as a feedback system for articles.
  • Acts_as_attachment: used when needing to upload user pictures or other related content. A needed addition in any social networking site.
  • Resource_feeder: To add RSS feeds to profile or the main site page.
  • Doing bi-directional, self-referential associations or self-referential friendships in order for users to be able to add friends. An example is provided here: https://blog.hasmanythrough.com/2006/04/21/self-referential-through

Some ideas on deployment include:

  • Having a dedicated server or host which fully supports Ruby on Rails. They are usually more expensive but provide better support for such a site.
  • Test material frequently into your scripts so that you can find errors or faults and correct them easily.

Use brain-storming, to add features and content everyday. Although this will be trimmed over-time, you will ultimately have a feature-rich and lean social network.