Blog

  • Creating AJAX Pagination WITHOUT The Pages

    You may have noticed some changes in the way a few websites work.  For example, if you go to Google Images and do a search, there is no pagination (1, 2, 3, Next, Previous) anymore.  Instead Google loads the images as you need them, e.g. when you scroll down. If you’re looking for more Node.js tutorial I’ve compiled an incredible list that will take you from a Node.js beginner to expert.

    Another example is Facebook’s newsfeed.  I read an excellent article a few months back on their developer blog about this design decision.  By default, Facebook will only load a “full screen” of information with minimal scrolling which triggers a Javascript event.  However, as soon as you start scrolling they begin to fetch and display more content.  In the article, Facebook described this decision as a bandwidth saver.  They found that a lot of people would navigate away from the newsfeed before ever scrolling down or only looking at the top content.  By only showing 10-15 posts, they can keep the size of their newsfeed down oppose to loading 30+ posts that are never going to be read!  File size can easily go down 100s of KBs per page view and when you’re talking about millions of page views per second, that’s a significant number. (more…)

  • IBM’s Watson on Jeopardy, The Final Saga

    In yesterday’s article I focused mainly on Watson.  So, in case you missed the episode last night, BIG SPOILER ALERT, Watson won.  Ken was actually pretty close after Double Jeopardy; in fact he was leading after the Jeopardy round.  If Ken would have bet bigger in Final Jeopardy it wouldn’t have been a gigantic blow out…

    Now, in today’s article I wanted to focus specifically on how incredible Google’s search technology is.  Below are the 5 categories from the Jeopardy round and a sample of questions from each category.  Beneath the question is the answer and whether Watson was wrong.  Beneath the answer is the result of a Google search and how easily and where the answer could be found. (more…)

  • IBM’s Watson On Jeopardy!

    I’ve been a fan of Jeopardy! for quite some time now.  Even more so over the past year.  Now that I am the Father of twins, going out at night just isn’t as easy as it was!  When I first heard about Watson being on Jeopardy, probably about 3 or 4 months ago, I was extremely excited.  Actually watching it over the past two nights has been just as thrilling.

    Learning about the technology behind it, being a geek and trying to think and understand some of the algorithms used, watching it think and tell you it’s best guess and a little bit about the process to find it has been nothing but entertaining. (more…)

  • Building A Scalable Queueing System With PHP

    In today’s article we are going to cover building a queueing system with PHP.  Before we begin, let’s define what a queueing system is.  The best place to start is the dictionary:

    “to line up or wait in a queue”

    Now that we have our definition, let’s define why we would want to build a queueing system.  A queueing system is an excellent tool that will allow us to take a specific process and perform the functionality “offline”, e.g. the process will line up and we will process them one at a time at a later date.  This will probably be easier to explain with an example.

    Imagine an admin area of a website that allows the administrator to send out a mass email to all of their users.  The simple process to building this functionality would be as follows:

    1. Build a form that accepts a subject and a body for the email.
    2. Retrieve the list of users from your database.
    3. Loop through the users and send each person an individual email.

    The above example works nice and fast when there are only a few hundred users.  However, imagine trying to send this email to 10,000 users.  The administrator would be waiting a long time for this process to finish.  Not only that, if they closed the browser, it probably would not finish properly.

    So, the goal of our queueing system is to remove a specific process from running “online” (in a web browser) and running it “offline” with a scheduled task. (more…)

  • Publishing an e-book on Smashwords

    I feel a little bit behind in the times on this one, but I’ll work to catch up quickly.  Over the past year or so I’ve been compiling samples and I put together a book for developing CakePHP websites.  I saught publishing on the book, but unfortunately all of the big name publishers felt that CakePHP is too small of a market.

    After being rejected, I wasn’t too sure what to do with the book.  So, I left it for a while.  Then, earlier this week through some Google searching I stumbled upon the idea of an e-book.  Previously I’ve associated e-books with “Get rich quick schemes” as you see a lot of websites selling e-books along those lines.

    I started investigating this option a bit more and I found some videos about creating e-books with Adobe Indesign and formatting them for the various readers.  This quickly started sounding like a lot of work!  Instead I searched for other solutions.  That’s when I found it: Smashwords.  This is an incredible service.  You upload your Word Document and they automatically convert it for the over 10 e-book options out there!  Not only that, they will sell it and promote it on your behalf. (more…)