Az

Dev

Rails Blog: Part 4

Sun, Jun 22, 2014 | 600 Words

By now you should have a blog with users, administrators and even a tag system as of part 3 in this series, so now we’re onto something for greater aesthetics. In this case, custom URLs for posts and tags. We’ll start by running: rails g migration add_url_to_tags_and_users The above generates a migration that we can open up (usually in db/migrate) and add the following inside the change method: add_column :tags, :url, :string add_column :posts, :url, :string This will add columns for the url component to both the Tag and Post model and we can send these changes to the database with rake db:migrate.

Rails Blog: Part 1

Tue, Jun 10, 2014 | 1200 Words

This is a continuation of the SiteHub project brought up in my Rails Forum Skeleton tutorials (Part 1, Part 2, Part 3, Thoughts), moving on to developing the news-site/blog component that the project will hopefully involve. If you’ve been through those tutorials you’ll likely see some familiar commands and actions, however I’ll do my best to explain everything for newcomers as well. Firstly, I’ll be using Ruby 2.1.1 or greater and Rails 4.

Rails Blog: Part 2

Tue, Jun 10, 2014 | 1200 Words

Continuing on from the first part of the Rails Blog tutorial we’re going to flesh out our blog concept even further. Now we want to create an administrator role who has permissions to edit/delete other’s posts in case they contain unsuitable material or are outdated and the connected account is deleted. There’s a few possible ways of doing this, but what we’re going to do is add a boolean attribute to the user model that signifies whether a user is an administrator.

Rails Forum Skeleton: Part 3

Tue, Jun 10, 2014 | 700 Words

Following on from my last tutorial where we set up users and primitive authentication/access control, we’re going to work on fleshing out the forum aspect further. Let’s start by allowing login and identifying users by a separate value, a “username”. I’ve added username as an attribute to the User model, to do that run rails g migration AddUsernameToUsers username:string then enter rake db:migrate. To get it working as the identifier for accounts you’ll need to go to config/initializers/devise.

Rails Forum Skeleton: Thoughts

Tue, Jun 10, 2014 | 200 Words

With the three tutorials done so far (Part 1, Part 2, Part 3) I’m thinking about letting this series rest. By the time you reach this level, you should hopefully be ready to spread your own wings and begin adding the features you want on your own. If you’re still stuck about how to implement an idea you have, feel free to hit me up at @judges119 or one of my other contact methods and I can look into it with you.

Rails Forum Skeleton: Part 1

Fri, Jun 6, 2014 | 1200 Words

Here’s a quick tutorial on how to create a framework for a forum. It doesn’t get into creating users, authentication or permissions, it’s mostly to show the relationships between entities and shore up the right views. Preface: So in the quest for new projects I’ve considered building an all-in-one website-forum-chatroom package with the goal of creating something that people can download to their server, run an install script and it sets up everything necessary and then allows the user to do post-install customisation (setting up static website pages, creating user permission levels, forum headings, etc).

Rails Forum Skeleton: Part 2

Fri, Jun 6, 2014 | 800 Words

Carrying on from my last tutorial about building the relationships and core view elements for discussions and posts, we’re going to extend our budding forum by adding users and authentication. To start, open Gemfile and down the bottom add gem 'devise' then run bundle install. Devise is an all-in-one authentication system that handles registration, sessions, authentication, recovering accounts, etc. To set up devise (our authentication station), run rails g devise:install. We’ll need to set the config.

Twitter Text Adventure Bot

Tue, Jun 3, 2014 | 400 Words

Some while ago, I wrote the skeleton to a text adventure game that was played by Tweeting at and receiving responses from a Twitter bot. You can find the initial version on my GitHub. The idea was spawned by a friend and I quickly turned it into a working prototype, it was also a good chance to learn about web APIs (with JavaScript/Node.js in particular) and OAuth. It’s initial iteration worked, but was plagued by some major user experience issues.

Initial Ghost Theme

Sat, May 31, 2014 | 200 Words

I decided to play around with theming on the Ghost blogging platform, just dipping a toe in to examine the structure and process. I haven’t delved too far because it seems to be a bit more involved than Dropplet themes, especially with the introduction of the Handlebars templating engine. It’s also still a pretty new platform so I think they’re waiting to introduce new features and fix up some flaws (like the author URL-OH CRAP NOW I KNOW HOW TO DO IT.

Dropplet Theme And HomePage

Fri, May 30, 2014 | 200 Words

So I finally managed to squeeze together some creative neurons and through ritual sacrifice and code creation and exploration I’ve finaly got together a theme for my Dropplets blog and rebuilt my homepage in a similar style. My aim was to create something quite minimalist, but with an organic feel through the use of warmer background tone and a fontface reminiscent of a typewriter’s keystrokes. You can find the theme for a Dropplets blog online on my GitHub and it’s also available (along with my homepage) in the public section on my GitLab.
First - 3 - 4 - 5 - 6 - Last