Archive for September, 2009

Inspiration – Jan Kallwejt

Posted on: September 29th, 2009 by Shayne

Jan Feliks Kallwejt is freelance graphic designer and illustrator currently based in Barcelona and Warsaw. He focuses on illustration, apparel design and personal art projects. Simple yet sophisticated forms are the essence of his work. He juxtaposes and multiplies them bringing to life the complex and tricky compositions, spiced up with attention to detail. He usually limits color palette, operating within two or three tones. To render the reality he employs multilayered symbolism, occasionally dropping in a dose of perversion where not expected.

kallwejt01

kallwejt02

kallwejt03

kallwejt04

Check out more work by Jan Kallwejt here.

Internationalizing Your ZF Application

Posted on: September 15th, 2009 by Rob Zienert 2 Comments

Today has another pretty interesting blog post lined up. Coincidentally enough, it goes perfectly with my blog post from about two months ago on Internationalizing websites. While that was a more topical post and not so much on actual implementation, I thought I’d make one with specifics regarding Zend Framework. I managed to catch a glimpse of some chat in #zftalk today regarding how to get a URL like http://example.com/en/module/controller/action/params to work.

Apologies in advance about the html entities in the code. I think the syntax highlighter we use should be re-evaluated. :(

Well, fancy that, PRPL released a website with that functionality not long ago on Hospice of the Comforter using Zend Framework and Oakland (my personal library). I feel like this method could be enhanced, but since it already works in my personal library, I may as well use it!

We’ll start off with routing. It was mentioned to possibly use Chain Routes, but for the sake of simplicity, I just have chosen to use a simple Rewrite, as seen below. Take note that routes aren’t even necessary to get this done. If you want the lang to just hang out in the params, that’s cool, too.

 default.route = "/:lang/:module/:controller/:action/*" default.defaults.lang = "en" default.defaults.module = "default" default.defaults.controller = "index" default.defaults.action = "index" 

It’s a very simple route, in fact, it’s the same as the typical modular default route, just with a lang param tacked on the beginning. In future projects, I don’t know if I would’ve appended the language specifically to the beginning of the route for each URL. It seems to me that it’d be better served as an additional param and then stored in user session from there on or always put on the end. I have no strong opinion about this, so it’s really up to your preference.

The next part is getting the application to automatically handle setting up your Zend_Locale and Zend_Translate objects. Since we don’t know what the param is until after routeShutdown, we need a Controller Plugin. The Plugin is setup to already have Zend_Translate and Zend_Locale already in Zend_Registry, so since Zend_Locale already has a Zend_Application Resource created for it, I just made one for Zend_Translate, like so:

class Oakland_Application_Resource_Translate extends Zend_Application_Resource_ResourceAbstract
{
    const DEFAULT_REGISTRY_KEY = 'Zend_Translate';

    /**
     * @var Zend_Translate
     */
    protected $_translate;

    /**
     * Defined by Zend_Application_Resource_Resource
     *
     * @return Zend_Translate
     */
    public function init()
    {
        return $this->getTranslate();
    }

    /**
     * Retrieve translate object
     *
     * @return Zend_Translate
     */
    public function getTranslate()
    {
        if (null === $this->_translate) {
            $options = $this->getOptions();

            if (!isset($options['data'])) {
                throw new Zend_Application_Resource_Exception('No translation source data provided.');
            }

            if (Zend_Registry::isRegistered('translateCache')) {
                Zend_Translate::setCache(Zend_Registry::get('translateCache'));
            }

            $adapter = isset($options['adapter']) ? $options['adapter'] : Zend_Translate::AN_ARRAY;
            $locale  = isset($options['locale'])  ? $options['locale']  : null;
            $translateOptions = isset($options['options']) ? $options['options'] : array();

            $this->_translate = new Zend_Translate(
                $adapter, $options['data'], $locale, $translateOptions
            );

            $key = (isset($options['registry_key']) && !is_numeric($options['registry_key']))
                 ? $options['registry_key']
                 : self::DEFAULT_REGISTRY_KEY;

            Zend_Registry::set($key, $this->_translate);
            Zend_Form::setDefaultTranslator($this->_translate);
        }

        return $this->_translate;
    }
}

If you’re at all familiar with Zend_Application_Resource_Locale, you’ll see a lot of similarities: I actually copied it because it looked so nice. Both of these resources set the objects into Zend_Registry with their key names as "Zend_Translate" and "Zend_Locale": Easy. The only thing that may require modification if you want caching is the Registry option for the translation cache; which I created another (irrelevant for this post) Application Resource to setup multiple cache objects.

Now we’ve got everything setup for our Controller Plugin I mentioned earlier. I named it Oakland_Controller_Plugin_Locale and originally I got the idea from another source, but I’m unable to find where I referenced unfortunately. Regardless, here it is:

class Oakland_Controller_Plugin_Locale extends Zend_Controller_Plugin_Abstract
{
    /**
     * Sets the application locale and translation based on the lang param, if
     * one is not provided it defaults to english
     *
     * @todo Allow default locale to be set by the application config
     *
     * @param Zend_Controller_Request_Abstract $request
     */
    public function routeShutdown(Zend_Controller_Request_Abstract $request)
    {
        $registry = Zend_Registry::getInstance();

        $locale = $registry->get('Zend_Locale');
        $translate = $registry->get('Zend_Translate');

        // Find the lang param. If not set, assign false
        $params = $this->getRequest()->getParams();
        $localeParam = isset($params['lang']) ? $params['lang'] : false;

        // If the lang param is false, we'll get whatever the default language is
        if (false === $localeParam) {
            $localeParam = $locale->getLanguage();
        }

        // As extra precaution, check if a language translation is available.
        // If not, then assign the application default. It really should instead
        // pull from the application.ini for a default language translation instead.
        if (!$translate->isAvailable($localeParam)) {
            $localeParam = 'en';
        }

        $locale->setLocale($localeParam);
        $translate->setLocale($locale);

        Zend_Form::setDefaultTranslator($translate);

        setcookie('lang', $locale->getLanguage(), null, '/');
    }
}

It’s fairly self explanatory, but it checks for the lang param we setup in the route back at the beginning of the post. If it doesn’t exist we assign it to false and can then get the system default language. The second conditional checks to verify whatever language it has been provided exists. I set it up to switch to english instead of throwing an exception so that if a visitor to the site accidentally is linked an invalid URL, it can still provide a seamless user experience. Sure, they may have to select a different language, but at least they’ll be on the proper page, ready to switch languages without having to navigate back.

After that, the Zend_Locale object is setup and assigned to the Zend_Translate object. After that you’re onto smooth sailing with a param-driven i18n website. If you have any ideas on how to make this better, I’m certainly all ears!

Press Release: Hospice of the Comforter

Posted on: September 15th, 2009 by Aaron Martin

Enhanced Resources on www.HospiceoftheComforter.org Include Online Tributes, Americans with Disabilities Act (ADA) Compliance, and English-Spanish Site Conversion

ALTAMONTE SPRINGS, FLA… The newly redesigned Hospice of the Comforter Web site, www.HospiceoftheComforter.org, features expanded content including photo galleries, tribute pages and accessibility tools for Spanish-speaking visitors or visitors with visual impairments.  The redesign incorporated a fresh color palette, original photography of real patients, families and employees, as well as a fully redesigned navigation.

"Our purpose in redesigning our Web site was two-fold,” explains Melissa Silvers, Communications Manager at Hospice of the Comforter. "First, we wanted to increase access to our services by creating a Web site that translated, was easy to navigate and was ADA compliant.  Second, we wanted our users to experience the same warmth and comfort that our care provides, and elements like our photography, tribute pages and photo galleries foster that experience.”

Content More Dynamic, Streamlined

Visitors to the Web site include people seeking information on hospice care and caregiving, volunteering, grief support and donations.  Hospice of the Comforter partnered with Orlando-based digital agency Purple, Rock, Scissors. to develop a site that would provide quick and direct access to all of these resources for all audiences. And if a user is not sure exactly where to look for specific information on www.HospiceoftheComforter.org, the newly developed site-wide search engine will help.

Tribute Pages allow users to easily upload a story, quote and photo of their deceased loved ones. Once the page is published, the tribute page can be shared with loved ones via email, text, Facebook, Twitter and other social media.

"Latest News and Updates” provides regularly updated blogs about a variety of topics including medical perspectives, organizational news, volunteering, financial support and grief support.  Users can also sign up for an electronic newsletter to stay connected.

Aaron Harvey of Purple, Rock, Scissors. shared how the project was unique for their digital agency because through their partnership with Hospice of the Comforter, “We have the privilege of connecting patients with compassionate care, families with support programs, and volunteers with outreach opportunities through an innovative, online medium.”

###

About Hospice of the Comforter

Hospice of the Comforter is the only nonprofit hospice serving patients and their families living with an incurable illness in Orange, Seminole and Osceola counties.  Hospice of the Comforter has provided more than $1.5 million in free care over the past three years and has served more than 18,000 families in Central Florida with physical, emotional and spiritual support.  For more information about how Hospice of the Comforter serves the community, visit www.HospiceoftheComforter.org.

About Purple, Rock, Scissors.

Based in Downtown Orlando, Purple, Rock, Scissors. is a leader in forward-thinking Web solutions and is quickly becoming one of America’s premier digital agencies. In addition to Web design, Purple, Rock, Scissors. offers a wide range of services, including digital strategy and planning, e-commerce strategies, interaction design, social media development, and more. For interviews with the firm’s expert on emerging digital trends, contact Aaron Harvey at 407-936-1749 or aaron@purplerockscissors.com. Learn more at www.PurpleRockScissors.com.

Modular Movement

Posted on: September 14th, 2009 by Rob Zienert

It has been very exciting for me the past couple months in the Zend Framework world. This buzz about modular development with ZF is cool–people are really starting to see the need for reusable modules. Adam Jensen offered up a reusable content module prototype in June and today Pádraic Brady made a great post about self-contained, reusable modules. Exciting times, indeed: I’m sure I can speak for any developer that has tried to sell a client or upper-management on the idea of rolling custom is an uphill battle; even with a library like Zend Framework behind you, it’s just plain expensive–especially when they know very flexible solutions like Drupal exist.

Get some modules

So about a month before 1.8 and Zend_Application was released and I got momentum rolling on [tentatively named] ZFComponents.com to help bring the next wave in for Zend Framework (yep, this blog post is a massive plug for it). To re-state it’s purpose if you haven’t heard of it before now: ZFC will be a resource to exchange your reusable Zend Framework modules to other developers for free (as always and forever). But what is involved in such a resource? Well, it requires a web site, obviously, but further there are no real standards for modular development. Sure, we have a directory structure and autoloaders, but what then?

That’s when I hit a roadblock and the project stagnated for awhile. Enter IRC, #zftalk and Ryan Mauger (Bittarman), who has been very helpful in keeping me on task to getting things done. We decided that the best way forward would be to create a base application which would create standards for developing reusable modules on. From this, I’ve been working on ideas to create reusable modules through configurators, installers and module plugins. While reading Pádraic’s post, I realized that some things should definitely be put into Zend Framework itself. As I sadly take my walk of shame: it hadn’t even occurred to me to contribute code to the library. Needless to say, now I’m all giddy on helping where I can on Pádraic’s proposal, while still keeping my extraneous pieces out and in the base application.

Where are we at?

But what of ZFComponents? Where is that at? Well I’m glad you asked. First, a look at the first-release features. They’re humble, but I think perfect to get running:

  • De-centralized project storage: Keep your repositories where they are (tested GitHub and Google Code so far). All you do to add a project is enter the name, a little description and a link to a public commit feed.
  • Module Ratings: Let other developers know of the real useful modules–as well as the ones that need work.
  • Module Tags: Find similar modules, easier.
  • Module and Developer Browsing: Browse by recently added, recently updated, hottest (most rated in a week), and most popular (highest overall rating).
  • Search: Because it’s necessary.
  • Module Comments: Because ratings can only take you so far.
  • Developer Profiles: See what developers have to say about themselves, the modules they contribute to, their karma and sexy Gravatar picture (maybe).

A fairly beefy feature list to start off with now that I’ve listed it off. So where are we at? Glad you asked!

The code sits happily on my local machine and staging server, and for the most part, buzzing away splendidly but it’s in dire need of some good looks! That’s where my boy Ben Child comes in, one of the designers here at Purple, Rock, Scissors who was most kind to help me with the look and feel: he’s working on it this week! We’re going through wireframing and I’ll hopefully be able to shoot up a few screenshots of concepts later this week sometime.

The community needs YOU!

That’s all good and dandy, but I think the biggest thing holding us back right now is the lack of reusable modules. To make this ridiculous blog post come to a climatic end, I’d like to war cry for Zend Framework developers to start doing what they can contribute to the modular movement (oh, I’m so clever with names).

Bittarman and I have been talking and making plans to create a generic, extendable content module; I’ve been working on a calendar / events module. What about you? These are by no means, "I called it, find your own module," kind of deals. If you’d like to help in any way (ZFComponents, a module, or what have you), I’m sure there is opportunity of it for you. Drop by #zftalk, for lack of a better option, and ask about it (for reference, my name on there is "rizza").

Facebook Lite: Devolution in Progress

Posted on: September 11th, 2009 by Mike

Picture 1

Recently, Facebook has publicly launched Facebook Lite, a calorie-free alternative to the behemoth pile of 3rd party integration chaos that revolutionized the way we socialize online. The internet is already being pummeled by a cacophony of articleswrite-ups, and posts regarding its public launch, including direct attacks on Facebook, criticizing its capitalization on the up-to-the-minute feedback that Twitter currently provides.

Facebook’s recent $50 million purchase of FriendFeed probably helps validate these statements, as Facebook is adopting and integrating new technology that keeps its head in the game with live updates and hive-mind search capabilities.

Facebook Lite Status Updates

Facebook Lite Status Updates

Capitalizing on realtime reciprocal information may be a large influence on many of their design decisions for Facebook Lite, but Facebook has publicly stated that FB-Lite is specifically targeting slower connections, particularly in developing nations, in order to provide a streamlined version of the core Facebook features. Based on the fact that FB-Lite is testing in India, this very well could be the case. Picture 4

Massive Hyperlink Attack

With all this in mind, there’s more beneath the surface that people haven’t picked up on. Facebook has made some strategic moves with FB-Lite that have probably been in the works for quite some time. The UI itself provides a much more usable and enjoyable experience for mobile devices, especially with those larger, fatter hit states on links and buttons. Fat navigation is not just web 2.0 gloss, it’s easier to press with your thumb. Navigation is now clear and concise, assisting with the learning curve of novice users.

The UI has also trimmed redundant body fat. On Facebook Classic, there are duplicate links that access your dashboard, namely the "Facebook" logo, as well as the "Home" link. If you check the URL it points to, it’s actually running separate analytics on each click. They’ve been studying users behaviors, and are adopting a new interface to help clean the clutter.

Picture 2 The duplicate links were probably band-aids for novice users to adapt to the latest Facebook redesign and become acquainted with its new features as of last year. Facebook can now use FB-Lite as their vehicle for implementation testing, especially since it’s marketed in new countries where users aren’t rampant Facebookers.

How a real man browses the internet

How a real man browses the internet

Outside of all this field testing and fine-tuning, FB-Lite is extremely stripped down. Almost all Javascript is practically nerfed, and almost every link is a separate page load. Reminiscent of Facebook 4 years ago, it’s right on point with the target demographic of mobile phones and dial-up. Plus it lets me personally power-browse Facebook in multiple tabs without crushing my CPU.

As technology begins to rapidly evolve, we can see noticeable patterns emerge as the mobile market plays technology catchup. Facebook Lite serves as a harmonious blend between dial-up connections in developing nations and portable media in industrialized ones.

This may be the ultimate stop-gap solution before mobile devices replace netbooks, or it may just be Facebook on training wheels running around a test track. While there will probably not be complete adoption of FB-Lite by most existing users, Kudos to Facebook for keeping the ball rolling on realtime assimilation. Worst case scenario, they’ll just implement the best features into the next version of Facebook Classic while widening their reach on an international user base.

Internet Fubar: Distracting Eliminations

Posted on: September 10th, 2009 by Mike

This Tweetie app ad was so distracting that it was blog-worthy…

The most non-distracting distraction in the world

The most non-distracting distraction in the world

How the hell do they expect me to concentrate with all these amazing offers floating around? What was that saying about selling a refrigerator to eskimos…

IX Hosting’s Virtual Sales Agent

Posted on: September 4th, 2009 by Mike

I’ve seen a lot of things, but this was borderline amazing. I’m not sure if I should feel better or more concerned at this point. I was checking out hosting specs over at IX Hosting, and when I went to close out the page, I was slapped with a nice fat JS alert, accompanied by a digital sales agent. Below is what transpired…

The most obtrusive prompt. ever.

The most obtrusive prompt. ever.

Full Transcript

Grace Says: When you are ready just say ‘Hi’ and we can get started….

You: wow that ambush was epic

Grace Says: Sorry i didn’t quite understand your question, can you rephrase it please..?

You: I was just trying to find server specs for a client who recommends you guys

You: they currently host

Grace Says: Sorry I can’t understand your question. Please can you repeat it for me?

You: are you a bot or running by a script…

Grace Says: You got me, I am a live virtual agent :-) I’m here to offer you this discount really, but I can answer most of your questions too, I hope.

Grace Says: If I can’t and you want to a speak with a live person please go to our Customer Center by Clicking Here

I’m semi-impressed by the fact that they respond properly when they’re called out. I’d just hate to actually think about the amount of time and energy invested in focus groups of irritated users who recommend methods for getting to a real sales rep.