Nov 25

Date published: 11-25-2013

Rails version: 4.0.0

File upload

Web sites are a very visual form of communication, and so it’s not that uncommon for users to want to add photographs to their sites. Most sites let you load an avatar for your user page, and some sites like flickr and Photobucket are based around hosting images. In this tutorial, we’re going to use a gem called Carrierwave upload photos and display them on a web page.

Photo upload

Photo upload

Continue reading »

Tagged with:
Nov 11

Date published: 11-11-2013

Rails version: 4.0.0

User authentication

Almost every web site these days requires users to log in before accessing content on the site, so it’s important for web developers to understand user authentication. Rails has several open source options for user authentication, but the most popular and one of the most versatile is called Devise. In this tutorial, I’ll show how to install Devise and setup basic authentication to allow the user to log in with their email address. Once we understand how Devise works, we’ll expand it so that with only one field users can log in with either their username or email address.

Sign up screen

Sign up screen

Continue reading »

Tagged with:
preload preload preload