<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2none.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/noitems.css"?><rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:creativeCommons="http://backend.userland.com/creativeCommonsRssModule" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Brian Cray's Blog</title>
	
	<link>http://briancray.com</link>
	<description>You’ve subscribed because you’re ready to take your website to the next level with user experience design, web development, and internet marketing.</description>
	<lastBuildDate>Sun, 07 Feb 2010 19:03:27 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<atom:link rel="hub" href="http://pubsubhubbub.appspot.com" />
	<atom:link rel="hub" href="http://superfeedr.com/hubbub" />
			<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/briancray/blog" /><feedburner:info uri="briancray/blog" /><creativeCommons:license>http://creativecommons.org/licenses/by-sa/3.0/</creativeCommons:license><image><link>http://creativecommons.org/licenses/by-sa/3.0/</link><url>http://creativecommons.org/images/public/somerights20.gif</url><title>Some Rights Reserved</title></image><feedburner:emailServiceId>briancray/blog</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><item>
		<title>The more I know, the less I need: Thoughts on web design</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/IY1WveU3h4M/</link>
		<comments>http://briancray.com/2010/02/03/measuring-simplicity-in-web-design/#comments</comments>
		<pubDate>Wed, 03 Feb 2010 16:36:59 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[conversion optimization]]></category>
		<category><![CDATA[information architecture]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[usability]]></category>
		<category><![CDATA[web analytics]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1679</guid>
		<description><![CDATA[You may have noticed that I&#8217;ve been going through design changes like crazy over the past month or so. That&#8217;s because I&#8217;m tracking almost everything my readers do into web analytics. With the right web analytics tools, you can gain real-time empirical data on your website visitors&#8217; habits in massive quantities.
What I&#8217;m learning may shock [...]]]></description>
			<content:encoded><![CDATA[<p>You may have noticed that I&#8217;ve been going through design changes like crazy over the past month or so. That&#8217;s because I&#8217;m tracking almost everything my readers do into web analytics. With <a href="http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/">the right web analytics tools</a>, you can gain <strong>real-time empirical data on your website visitors&#8217; habits</strong> in massive quantities.</p>
<p>What I&#8217;m learning may shock some of you, and it may confirm ideas for others. It&#8217;s not far from <a href="http://briancray.com/2009/08/26/blog-design-information-overload-progressive-disclosure/">what I&#8217;ve blogged about in the past</a>: Supplemental navigation is, in most cases, visual junk.</p>
<h3>Breakdown of link clicks by area</h3>
<p><img src="http://chart.apis.google.com/chart?chs=440x150&#038;chd=t:70,21,10&#038;cht=p3&#038;chl=Content|Header|Supplemental"></p>
<h3>Interpreting the chart data</h3>
<p>As you can see, supplemental navigation&mdash;including related posts, historical post navigation, popular posts, most commented posts, sidebars, etc&mdash;has accounted for about <em>only 10%</em> of the navigation on my site during several design variations. Of that 10%, historical navigation and related posts <em>alone</em> accounted for about 99%. The rest? Fluff. Garbage.</p>
<p>On the other hand, navigation <em>inside the content area</em> accounted for approximately 70% of clicked links on my site. Header navigation, including menu, logo, search, accounted for 30%.</p>
<h3>Design implications of data</h3>
<p>In short: less is more.</p>
<p>If you visit almost any blog today, you&#8217;ll be bombarded with 5,000 sidebar widgets, gadgets, and gizmos that are there to do what? Lower the bounce rate by increasing page views? Is that an actionable metric? No.</p>
<p>Blogs should be especially ashamed of these design practices, because the user&#8217;s goal is clear in 99% of the time: Read an article.</p>
<p>And the conversions are clear: subscribe, comment, share.</p>
<p>Those conversions are getting lost in too much choice and information overload. Do you want your users to subscribe, or do you want them to get lost in a sea of sidebar gadgets?</p>
<p>If the <a href="http://en.wikipedia.org/wiki/The_Paradox_of_Choice">Paradox of Choice</a> has taught us anything, it&#8217;s that how many choices you provide to users is a serious issue you should confront with every design decision.</p>
<h3>Actionable design recommendations</h3>
<ol>
<li>Start tracking exactly how your users are navigating your site. If you don&#8217;t know how, <a href="http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/">here&#8217;s a good place to start</a>.</li>
<li>Apps like <a href="http://lab.arc90.com/experiments/readability/">Readability</a> and <a href="http://www.hogbaysoftware.com/products/writeroom">WriteRoom</a> exist for a reason: Distractions suck. Eliminate low performing navigation options to increase the performance of effective navigation and user goal completion rates.</li>
<li>Integrate important navigation into your content. Don&#8217;t leave it off to the side where it&#8217;s <a href="http://briancray.com/2009/07/27/eye-tracking-studies-influence-redesign/">unnatural for people to look</a>.</li>
<li>Focus on what you want your design to achieve. Don&#8217;t focus on inflating your stats and ego with page views or lower bounce rates.</li>
</ol>
<h3>Conclusion</h3>
<p>Using information to make design decisions is something that should be practiced more in the web design community. In this case, a little data has provided a significant argument against a common blog design practice. What else could we be doing wrong or could we improve?</p>
<p>I think we&#8217;ll also find what works better for our users, also works better for our conversion rates. Please share your thoughts or data on the subject.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/06/07/rethinking-website-navigation-design/' rel='bookmark' title='Permanent Link: Rethinking website navigation design'>Rethinking website navigation design</a></li>
<li><a href='http://briancray.com/2009/08/26/blog-design-information-overload-progressive-disclosure/' rel='bookmark' title='Permanent Link: Blog design best practice: Scrollbars not sidebars'>Blog design best practice: Scrollbars not sidebars</a></li>
<li><a href='http://briancray.com/2009/07/09/best-long-tail-seo-keywords-web-analytics/' rel='bookmark' title='Permanent Link: My secret to finding the best long-tail SEO keywords with web analytics'>My secret to finding the best long-tail SEO keywords with web analytics</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=IY1WveU3h4M:FUJHiSemkps:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=IY1WveU3h4M:FUJHiSemkps:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=IY1WveU3h4M:FUJHiSemkps:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=IY1WveU3h4M:FUJHiSemkps:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=IY1WveU3h4M:FUJHiSemkps:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/IY1WveU3h4M" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2010/02/03/measuring-simplicity-in-web-design/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		<feedburner:origLink>http://briancray.com/2010/02/03/measuring-simplicity-in-web-design/</feedburner:origLink></item>
		<item>
		<title>How to promote innovation from your web team</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/iI0TtapWNsg/</link>
		<comments>http://briancray.com/2010/01/28/innovative-web-team/#comments</comments>
		<pubDate>Thu, 28 Jan 2010 17:27:26 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[startups]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1674</guid>
		<description><![CDATA[&#8220;Analytics, analytics, analytics, blah, blah, blah.&#8221;
&#8220;Code, code, code, blah, blah, blah.&#8221;
Two people, one a web analytics professional, the other a web developer, awkwardly sip coffee across from each other at a small cafe table that feels like a vast expanse. Their professional focuses seem not to hit any harmonious tones.
Then it happens. The internet marketer [...]]]></description>
			<content:encoded><![CDATA[<p>&#8220;Analytics, analytics, analytics, blah, blah, blah.&#8221;</p>
<p>&#8220;Code, code, code, blah, blah, blah.&#8221;</p>
<p>Two people, one a web analytics professional, the other a web developer, awkwardly sip coffee across from each other at a small cafe table that feels like a vast expanse. Their professional focuses seem not to hit any harmonious tones.</p>
<p>Then it happens. The internet marketer asks <em>the</em> question: &#8220;Do you know what an <abbr>API</abbr> is by any chance?&#8221;</p>
<p>&#8220;Yea, sure. Why?&#8221;</p>
<p>&#8220;I was reading about new stuff in Google Analytics, things like being able to track things other than page views, like when a user plays a video. Apparently you can also build user segments in real-time. But it said something about an <abbr>API</abbr>, and I gave up. Maybe I&#8217;ll look at it later when I have the time.&#8221;</p>
<p>&#8220;Well, I know how to use <abbr>API</abbr>s, maybe I could help!&#8221; Relieved, the web developer realizes they <em>do</em> have something in common.</p>
<p>Over the next few hours they pour over the <a href="http://code.google.com/intl/en/apis/analytics/docs/gaJS/gaJSApi.html">tracking <abbr>API</abbr> documentation</a> together and realize the potential of their combined skill sets as they discuss <a href="http://code.google.com/intl/en/apis/analytics/docs/gaJS/gaJSApiCampaignTracking.html">advanced campaign tracking</a>, <a href="http://code.google.com/intl/en/apis/analytics/docs/gaJS/gaJSApiEventTracking.html">event tracking</a>, and <a href="http://code.google.com/intl/en/apis/analytics/docs/tracking/gaTrackingCustomVariables.html">real-time visitor segmenting</a>.</p>
<p>A month later the company knows more about its online customers and their behaviors/preferences than they could have imagined. A year later they are numero uno in their industry.</p>
<p>This is a classic problem between engineering and marketing. They can do so much together if they could just focus on outcomes instead of differences.</p>
<p>Promote interdisciplinary dialogue in your company. Get people to open up and share what they know across disciplinary lines.</p>
<p>Get your customer service reps talking to your copywriters. Get your social media marketers talking to your web analytics folks. Hell, get your direct mail marketers talking to your web developers. <strong>Truly innovate</strong>.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/' rel='bookmark' title='Permanent Link: Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery'>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery</a></li>
<li><a href='http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/' rel='bookmark' title='Permanent Link: Is your Google Analytics missing page views? Introducing Asynchronous Tracking'>Is your Google Analytics missing page views? Introducing Asynchronous Tracking</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iI0TtapWNsg:QbPKu8Gsd8A:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iI0TtapWNsg:QbPKu8Gsd8A:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iI0TtapWNsg:QbPKu8Gsd8A:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iI0TtapWNsg:QbPKu8Gsd8A:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iI0TtapWNsg:QbPKu8Gsd8A:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/iI0TtapWNsg" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2010/01/28/innovative-web-team/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://briancray.com/2010/01/28/innovative-web-team/</feedburner:origLink></item>
		<item>
		<title>UX Case Study: Designing a user-focused web app</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/lyrJqXhiRUc/</link>
		<comments>http://briancray.com/2010/01/26/ux-case-study-designing-user-focused-web-app/#comments</comments>
		<pubDate>Tue, 26 Jan 2010 19:48:36 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[information architecture]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[research]]></category>
		<category><![CDATA[startups]]></category>
		<category><![CDATA[twitter]]></category>
		<category><![CDATA[usability]]></category>
		<category><![CDATA[web analytics]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1647</guid>
		<description><![CDATA[I wrote this article to give you insight into the complete design process for the redesign of Nearby Tweets. Web app developers and entrepreneurs will hopefully gain some ideas or reinforce their own processes. Users may find it interesting to see what goes into the design of a complex UI. I&#8217;d love your ideas, feedback, [...]]]></description>
			<content:encoded><![CDATA[<p>I wrote this article to give you insight into the complete design process for the redesign of Nearby Tweets. Web app developers and entrepreneurs will hopefully gain some ideas or reinforce their own processes. Users may find it interesting to see what goes into the design of a complex <abbr>UI</abbr>. I&#8217;d love your ideas, feedback, and thoughts at the end of this article! Enjoy.</p>
<h3>Start at the beginning</h3>
<p>In the beginning there was the first iteration of Nearby Tweets, a simple way to connect with local people and businesses on Twitter.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/nbt_old.jpg" alt="Old Nearby Tweets screenshot"></p>
<p>But in product development there is no such thing as perfection, only <a href="http://en.wikipedia.org/wiki/Iterative_design">iterative design</a>&mdash;and customers hold all the answers to a better product. So I reached out to my users as soon as I had a chance with <a href="http://nearbytweets.uservoice.com/">Uservoice</a>. Through Uservoice, my users could vote on features they wanted see in the Nearby Tweets redesign, and vote they did.</p>
<h3>Top user requested changes to Nearby Tweets</h3>
<ol>
<li>Default location</li>
<li>Saved keywords and locations</li>
<li>Pullout drawer was annoying</li>
<li>Manual directory</li>
<li>Mobile version</li>
<li>Auto-refresh tweets</li>
<li>Block users</li>
<li>Block locations</li>
<li>Follow feature</li>
</ol>
<h3>Choosing which features to implement</h3>
<p>While all user requests are valid opportunities, I had to give some thought to my own resources and agenda before to make the right decisions about which requests to accept.</p>
<h4>Sorry mobile version, but you&#8217;ll have to wait</h4>
<p>Since I already had a web presence and I have not completely aligned Nearby Tweets&#8217; web presence with my goals, I am holding off on the mobile version, because that requires many resources and a new round of considerations, which would set me back and throw me off.</p>
<h4>Sorry manual directory, but you&#8217;re for someone else</h4>
<p>There are plenty of apps out there doing manual Twitter directories. I don&#8217;t have the reputation to compete them in that space, but the auto geolocation space is still mine, and that&#8217;s where I&#8217;ll stay for now. (See <a href="http://twellow.com/">Twellow</a>, <a href="http://wefollow.com/">WeFollow</a>, and <a href="http://justtweetit.com/">just tweet it</a>)</p>
<h4>The rest of you, come with me</h4>
<p>The rest of the user-requested features fit within my current agenda for the web platform, which I&#8217;d have to also define more clearly before I started in on the <abbr>UI</abbr> design.</p>
<h3>Narrowing my design scope</h3>
<p>In order to keep myself on track, I laid out three design scope requirements for the Nearby Tweets redesign:</p>
<ol>
<li><strong>Address user concerns.</strong> I released the first version of Nearby Tweets quickly with little user feedback, just to quietly hit the market with a fun, useful project. With this redesign I wanted to garner as much user feedback during the design process as possible. I did so through Twitter, Uservoice, as well as a private and public beta.</li>
<li><strong>Make Nearby Tweets more powerful.</strong> Although the focus of the first version was an advantage, it was very basic with no extended functionality. This time Nearby Tweets would supplement its core functionality with user preferences, and advanced search features.</li>
<li><strong>Maintain Nearby Tweets&#8217; simplicity and focus.</strong> All the while I would retain the simplicity of Nearby Tweets and make any effort to further simplify the Nearby Tweets experience.</li>
</ol>
<h4>Then I came up with my design goal</h4>
<p>Allow users to watch nearby tweets without any work, but allow users to tweak Nearby Tweets when ready.</p>
<h3>Turning concepts into UI design</h3>
<p>To keep Nearby Tweets simple while adding advanced functionality I decided to utilize two UI design concepts: Progressive disclosure and lazy registration.</p>
<h4>Implementing progressive disclosure in the UI</h4>
<blockquote><p>Progressive disclosure defers advanced or rarely used features to a secondary screen, making applications easier to learn and less error-prone. &#8211; <a href="http://www.useit.com/alertbox/progressive-disclosure.html" title="Read the article">Jakob Nielsen</a></p>
</blockquote>
<p>It should be noted that a second screen could be interpreted as hidden functionality that displays on the same screen on demand. That&#8217;s one of the ways I interpreted it anyway, as you&#8217;ll see.</p>
<h5>Tweet options</h5>
<p>The primary focus of each tweet is what&#8217;s said and who said it, so I kept each tweet to just that.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/plaintweet.jpg"></p>
<p>However, users have specifically requested the option to follow people, block people, and block locations. This advanced functionality needs to be available without cluttering each tweet with options used by a minority of the users. In comes progressive disclosure. As a user moves their mouse over each tweet, options to follow people, block people, and block locations becomes available.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/hovertweet.jpg"></p>
<h5>Location and keyword change popups</h5>
<p>The primary focus of an initial visit to Nearby Tweets was to simply watch the Nearby Tweets stream. So the only heading on the home page reads: &#8220;Tweets nearby xxxxx about yyyyy.&#8221; Simple enough.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/nbtheading.png"></p>
<p>But what about when people decide to search a new location or keyword? You&#8217;ll notice that the location and keyword look like links. When the user moves to click the location or keyword to change it, an in-place popup reveals the potential for more functionality.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/nbtheadinghober.png"></p>
<p>To present the user with a search box and everything else for searching would be too much for people just casually moving their mouse across the screen, so without clicking the user simply sees a button to &#8220;Change.&#8221; Clicking on that button further reveals full search capability. The whole box is actually clickable to increase the user&#8217;s click area.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/nbtheadingclick.png"></p>
<p>One thing you&#8217;ll notice on the location popup is a &#8220;use the map&#8221; button. The map is another area of the UI that has two purposes: Give the user a sense of location and provide advanced search functionality through progressive disclosure.</p>
<h5>Location searches using an interactive map</h5>
<p>At first glance the map just sits behind the Nearby Tweets stream and provides the user a visual context for their location, with a translucent white circle indicating the search radius.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/mapbg.jpg"></p>
<p>When users search locations, the Nearby Tweets stream slides away and reveals the map as search controls fade in.</p>
<p>This UI allows the map to take the backseat as a simple, relevant visual background to the Nearby Tweets steam while it&#8217;s not in use, but provide a very powerful search interface on demand.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/mapbgfull.jpg"></p>
<h5>User preferences</h5>
<p>As a classic example of progressive disclosure, users can add saved locations, keywords, and more in the user preferences, which provides the user with the power to make Nearby Tweets work better for them.</p>
<p>Speaking of user preferences, let&#8217;s talk about how it works.</p>
<h4>Implementing lazy registration in the UI</h4>
<p>A user could never touch the user preferences screen, but still get nearly all of its advantages. How? Lazy registration is a <a href="http://konigi.com/notebook/12-excellent-examples-“lazy-registration">growing <abbr>UI</abbr> trend</a> wherein information about the user is stored to make a later registration simpler to complete by auto-completing known information.</p>
<h5>Passive preferences</h5>
<p>Although Nearby Tweets has no registration per say, it does have a preferences page that allows a user registration-like advantages. The &#8220;lazy&#8221; part includes all the preferences the user sets without explicitly setting preferences there.</p>
<ul>
<li>Locations are automatically saved each time the user switches locations</li>
<li>Keywords are automatically saved each time the user searches a location</li>
<li>The main UI allows users to block people and locations</li>
</ul>
<h5>Default location</h5>
<p>Although the user can manually set a default location for Nearby Tweets in user preferences, this isn&#8217;t always necessary. Nearby Tweets attempts to find the user&#8217;s location automatically, making the UI completely passive unless the user chooses to further customize Nearby Tweets.</p>
<h3>Addressing user requests</h3>
<h4>Default location</h4>
<p>Nearby Tweets doesn&#8217;t always find the user&#8217;s location, so users wanted to manually override the <abbr>UI</abbr> with whatever default location they chose. I thought about several ways to achieve this, such as adding a &#8220;set to default&#8221; checkmark beside each saved location, but I thought this would add a lot of links for a misunderstood function without being too verbose.</p>
<p>I settled on keeping the option to set a default in the user preferences. There I would have the space to make it clear how to set a default location. Each saved location can be set as the default location simply by checking the column marked &#8220;default.&#8221;</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/default_location.png"></p>
<h4>Saved keywords and locations</h4>
<p>I chose to use &#8220;recent&#8221; instead of &#8220;saved&#8221; because it more closely reflects the storing behavior of the &#8220;saved&#8221; locations and keywords. Keywords and locations are permanently saved like bookmarks, but rather they work like a browser&#8217;s history.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/savedkeywords.png"></p>
<h4>Auto-refreshing tweets</h4>
<p>The refresh rate of new tweets was something I had a difficult time with. I had to fight between several competing factors: If I make it too slow people will think that Nearby Tweets isn&#8217;t working; If I make it too fast people won&#8217;t be able to read the tweets, thus eliminating usefulness. After tweaking the auto-refresh rate and testing it with a few users, I found the balance to be 3 seconds, which is now the default.</p>
<p>Since not everybody reads at the same rate or thoroughness, the auto-refresh rate can be set in user preferences. Based on analytics the most common times after 3 seconds include 30 seconds, 10 seconds, 5 seconds, and 1 second.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/defaulttimer.png"></p>
<h4>Block users</h4>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/nbtblock.png"></p>
<h4>Block locations</h4>
<p>I also had a difficult time deciding how to implement blocked locations, which works by comparing the tweeter&#8217;s location against the blocked location. The problem arises when a user blocks the location &#8220;Columbus, Ohio&#8221; and the tweeter&#8217;s location is &#8220;Columbus.&#8221; Although a person can clearly see the two locations are the same, &#8220;Columbus, Ohio&#8221; is not equal to &#8220;Columbus&#8221; to a computer.</p>
<p>The question then is do I assume that the user intends to only block exact matches for &#8220;Columbus, Ohio&#8221; or all tweets in &#8220;Columbus&#8221;? To make the software intelligent, I developed it to extract the city name automatically. However, this is an issue when you have the same city name in two locations, such as Columbus, Ohio and Columbus, Georgia. Anyone in Columbus, Georgia who wants to blocks tweets only from Columbus, Ohio will block tweets from any city named incidentally named Columbus. I guess I&#8217;ll have to keep my ears open to user complaints on this issue if it really becomes an issue at all.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/blocklocations.png"></p>
<h4>Follow feature</h4>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/follow_people.png"></p>
<h3>Intended behaviors vs. Actual behaviors</h3>
<p>It&#8217;s one thing to influences behaviors through design, it&#8217;s another to see what really happens. In my redesign of Nearby Tweets I took some questionable, albeit well thought out, usability risks by not following standard <abbr>UI</abbr> patterns.</p>
<p>I&#8217;ve found that Google Analytics is actually the best way to track user behavior, if you know what to do. I&#8217;ve setup my Google Analytics to individually track almost every user interaction with the <abbr>UI</abbr>. For example, I can see whether people are using typed locations, saved locations, or mapped locations. I can tell how many people set default locations, or delete saved locations. I can see it all.</p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/event_cats.png"></p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/event_actions.png"></p>
<p><img src="http://briancray.com/wp-content/uploads/2010/01/event_lables.png"></p>
<p>As the above stats show, people are using the <abbr>UI</abbr> I built. 44% of the people that visit the site use some part of the <abbr>UI</abbr>, excluding visits to other pages. I&#8217;d like to increase that to at least half. Other people may be simply visiting the site and watching the Nearby Tweets stream, which is sufficient for me for now.</p>
<h3>That&#8217;s it!</h3>
<p>I hope you enjoyed this little run down of my redesign process of Nearby Tweets. Please share your ideas, thoughts, and feedback. How would you have done things differently? Has this helped you do anything different in the future?</p>
<p>And if you haven&#8217;t already, be sure to pay <a href="http://nearbytweets.com/">Nearby Tweets</a> a visit and share it with your Twitter network <img src='http://briancray.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/' rel='bookmark' title='Permanent Link: Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery'>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery</a></li>
<li><a href='http://briancray.com/2009/02/23/nearby-tweets-officially-leaves-beta/' rel='bookmark' title='Permanent Link: Nearby Tweets Officially Leaves Beta!'>Nearby Tweets Officially Leaves Beta!</a></li>
<li><a href='http://briancray.com/2009/12/15/user-feedback-clicked-links-linknotify-2/' rel='bookmark' title='Permanent Link: Better user feedback on clicked links with linkNotify 2.0'>Better user feedback on clicked links with linkNotify 2.0</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=lyrJqXhiRUc:EY_bs_4vum8:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=lyrJqXhiRUc:EY_bs_4vum8:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=lyrJqXhiRUc:EY_bs_4vum8:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=lyrJqXhiRUc:EY_bs_4vum8:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=lyrJqXhiRUc:EY_bs_4vum8:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/lyrJqXhiRUc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2010/01/26/ux-case-study-designing-user-focused-web-app/feed/</wfw:commentRss>
		<slash:comments>10</slash:comments>
		<feedburner:origLink>http://briancray.com/2010/01/26/ux-case-study-designing-user-focused-web-app/</feedburner:origLink></item>
		<item>
		<title>Display popular posts based on social media engagement with PostRank Top Posts API</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/fIwe3I1PH0Q/</link>
		<comments>http://briancray.com/2010/01/04/popular-posts-social-media-engagement-postrank-top-posts-api/#comments</comments>
		<pubDate>Mon, 04 Jan 2010 16:19:51 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[rss]]></category>
		<category><![CDATA[Social Media]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1616</guid>
		<description><![CDATA[According to PostRank, &#8220;Over 80% of the engagement with your content doesn&#8217;t happen on your blog.&#8221; That&#8217;s a big deal on many levels. In the context of this post, it confirms that number of comments alone doesn&#8217;t constitute the popularity of your blog posts.
Lucky for us though, PostRank&#8212;a company that monitors and collects social engagement [...]]]></description>
			<content:encoded><![CDATA[<p>According to <a href="https://analytics.postrank.com/">PostRank</a>, &#8220;Over 80% of the engagement with your content doesn&#8217;t happen on your blog.&#8221; That&#8217;s a big deal on many levels. In the context of this post, it confirms that <strong>number of comments alone doesn&#8217;t constitute the popularity of your blog posts</strong>.</p>
<p>Lucky for us though, <a href="http://www.postrank.com/">PostRank</a>&mdash;a company that monitors and collects social engagement data in real-time across the web&mdash;provides powerful <a href="http://data.postrank.com/">Data Services</a> that give developers <a href="http://data.postrank.com/api_mining.html"><abbr>API</abbr></a> access to that social engagement data.</p>
<p>Today I&#8217;ll show you how to use <abbr>PHP5</abbr> to fetch and display your blog&#8217;s most popular posts using <a href="http://apidocs.postrank.com/Top-Posts-API">PostRank&#8217;s Top Posts API</a>.</p>
<p><span id="more-1616"></span></p>
<h3>Requirements</h3>
<ol>
<li>Your blog must publish an <a href="http://www.whatisrss.com/"><abbr>RSS</abbr> feed</a></li>
<li>Grab your PostRank feed hash (<a href="http://blog.postrank.com/getting-started/postrank-top-posts-widget/">directions</a></li>
<li><abbr>PHP5</abbr> is required.</li>
</ol>
<h3 id="firstcode">Fetching the Top Posts API</h3>
<p>This code caches the latest Top Posts <abbr>API</abbr> feed for an hour to maintain your website&#8217;s performance.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">function</span> popular_postrank<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #666666; font-style: italic;">//BASIC REST API URL: http://api.postrank.com/v2/feed/{feed_hash}/topposts?appkey=postrank.com/example</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">//replace this with YOUR feed hash as discussed in the requirements</span>
	<span style="color: #000088;">$postrank_feed_hash</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'3e7883668d6a7406078846eed577d4f8'</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$numposts</span> <span style="color: #339933;">=</span> <span style="color: #cc66cc;">10</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$apikey</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$url</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'http://api.postrank.com/v2/feed/'</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$postrank_feed_hash</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'/topposts?appkey='</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$apikey</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'&amp;format=json&amp;num='</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$numposts</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$cache</span> <span style="color: #339933;">=</span> <span style="color: #990000;">dirname</span><span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">__FILE__</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'/caches/postrank'</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">filemtime</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$cache</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&lt;</span> <span style="color: #009900;">&#40;</span><span style="color: #990000;">time</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">-</span> <span style="color: #cc66cc;">3600</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #990000;">mkdir</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">dirname</span><span style="color: #009900;">&#40;</span><span style="color: #009900; font-weight: bold;">__FILE__</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'/caches'</span><span style="color: #339933;">,</span> <span style="color: #208080;">0777</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$ch</span> <span style="color: #339933;">=</span> <span style="color: #990000;">curl_init</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">curl_setopt</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ch</span><span style="color: #339933;">,</span> CURLOPT_URL<span style="color: #339933;">,</span> <span style="color: #000088;">$url</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">curl_setopt</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ch</span><span style="color: #339933;">,</span> CURLOPT_RETURNTRANSFER<span style="color: #339933;">,</span> <span style="color: #cc66cc;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">curl_setopt</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ch</span><span style="color: #339933;">,</span> CURLOPT_REFERER<span style="color: #339933;">,</span> <span style="color: #000088;">$_SERVER</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'REQUEST_URI'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$data</span> <span style="color: #339933;">=</span> <span style="color: #990000;">curl_exec</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ch</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">curl_close</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$ch</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$cachefile</span> <span style="color: #339933;">=</span> <span style="color: #990000;">fopen</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$cache</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'wb'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">fwrite</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$cachefile</span><span style="color: #339933;">,</span> <span style="color: #000088;">$data</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #990000;">fclose</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$cachefile</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">else</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$data</span> <span style="color: #339933;">=</span> <span style="color: #990000;">file_get_contents</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$cache</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000088;">$json</span> <span style="color: #339933;">=</span> <span style="color: #990000;">json_decode</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$data</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #000088;">$html</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'&lt;ul&gt;'</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">foreach</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$json</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">items</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$item</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$html</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">'&lt;li&gt;&lt;a href=&quot;'</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$item</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">original_link</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'&quot;&gt;'</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$item</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">title</span> <span style="color: #339933;">.</span> <span style="color: #0000ff;">'&lt;/a&gt;&lt;/li&gt;'</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000088;">$html</span> <span style="color: #339933;">.=</span> <span style="color: #0000ff;">'&lt;/ul&gt;'</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">echo</span> <span style="color: #000088;">$html</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></td></tr></table></div>

<h3 id="secondcode">Displaying the popular posts</h3>
<p>Put this anywhere you want to display your top posts.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> popular_postrank<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></td></tr></table></div>

<h3>HTML output</h3>
<p>Calling the above function outputs a simple <abbr>HTML</abbr> unordered  list with the <abbr>CSS</abbr> class name &#8220;popular-posts&#8221;, like so:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
</pre></td><td class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">ul</span> <span style="color: #000066;">class</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;popular-posts&quot;</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/&quot;</span>&gt;</span>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/08/26/free-php-url-shortener-script/&quot;</span>&gt;</span>Free PHP URL shortener script that kicks ass<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/12/02/value-of-wireframing-website-design/&quot;</span>&gt;</span>How wireframing makes your website designs better<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/11/13/signup-process-online-community-best-practices/&quot;</span>&gt;</span>Online community best practices: Effective signup process<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/09/09/fire-the-web-designer/&quot;</span>&gt;</span>Fire the “web designer”<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/09/08/track-inbound-link-referrals-social-media-profiles-twitter-facebook/&quot;</span>&gt;</span>How to track inbound links from your social media profiles (Twitter, Facebook, etc)<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/08/26/free-php-url-shortener-script/&quot;</span>&gt;</span>Free PHP URL shortener script that kicks ass<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/11/30/omnigraffle-wireframing-960-grid-template/&quot;</span>&gt;</span>Wireframing Freebie: 960 grid template for OmniGraffle<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/09/18/web-form-validation-php/&quot;</span>&gt;</span>Smart web form validation with PHP<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
	<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">li</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;http://briancray.com/2009/12/28/simple-image-randomizer-jquery/&quot;</span>&gt;</span>Impossibly simple image randomizer with jQuery<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">li</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">ul</span>&gt;</span></pre></td></tr></table></div>

<h3>Adding it to Wordpress</h3>
<ol>
<li>Add the <a href="#firstcode">popular_postrank() function</a> to /wp-content/themes/{current_theme}/functions.php</li>
<li>Add the <a href="#secondcode">call to the function</a> anywhere you want to display to top posts (likely index.php, archives.php, or single.php)</li>
</ol>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/08/24/delicious-bookmarks-api-php/' rel='bookmark' title='Permanent Link: Display your recent delicious bookmarks with PHP'>Display your recent delicious bookmarks with PHP</a></li>
<li><a href='http://briancray.com/2009/08/21/tweeted-links-twitter-api-php-cache/' rel='bookmark' title='Permanent Link: Use PHP to cache and display your tweeted links'>Use PHP to cache and display your tweeted links</a></li>
<li><a href='http://briancray.com/2009/03/09/interview-social-media-phd-scholar-vivek-kumar-shares-views-on-social-media/' rel='bookmark' title='Permanent Link: Interview: Social Media PhD Scholar Vivek Kumar Shares Views On Social Media'>Interview: Social Media PhD Scholar Vivek Kumar Shares Views On Social Media</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fIwe3I1PH0Q:pjq-nNSrDDc:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fIwe3I1PH0Q:pjq-nNSrDDc:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fIwe3I1PH0Q:pjq-nNSrDDc:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fIwe3I1PH0Q:pjq-nNSrDDc:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fIwe3I1PH0Q:pjq-nNSrDDc:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/fIwe3I1PH0Q" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2010/01/04/popular-posts-social-media-engagement-postrank-top-posts-api/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		<feedburner:origLink>http://briancray.com/2010/01/04/popular-posts-social-media-engagement-postrank-top-posts-api/</feedburner:origLink></item>
		<item>
		<title>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/uDe8LqwkOug/</link>
		<comments>http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/#comments</comments>
		<pubDate>Tue, 29 Dec 2009 20:20:56 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[User experience]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[api]]></category>
		<category><![CDATA[conversion optimization]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[usability]]></category>
		<category><![CDATA[web analytics]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1584</guid>
		<description><![CDATA[<p>In a default Google Analytics setup, the information you have about your users' navigation behaviors and preferences is limited to which pages they viewed and where they came from. But what does that <em>really</em> tell you about how your users behave <strong>inside</strong> your web pages? Not much, and that's where all the juicy behavioral insight comes from.</p>

<!--more-->

<ul>
<li>Are your users using the main menu to navigate or do they use different means to find content?</li>
<li>Do your users scroll through your content and click links in the footer?</li>
<li>Do your users click on an article title or the "continue reading..." link?</li>
<li>Do your users actually go through the items in my dropdown menu, or are they unaware of the dropdown menus?</li>
<li>Do your users follow your related blog entry suggestions?</li>
</ul>]]></description>
			<content:encoded><![CDATA[<p>In a default Google Analytics setup, the information you have about your users&#8217; navigation behaviors and preferences is limited to which pages they viewed and where they came from. But what does that <em>really</em> tell you about how your users behave <strong>inside</strong> your web pages? Not much, and that&#8217;s where all the juicy behavioral insight comes from.</p>
<p><span id="more-1584"></span></p>
<h3>I dare you to answer the following questions with your current Google Analytics setup</h3>
<ul>
<li>Are your users using the main menu to navigate or do they use different means to find content?</li>
<li>Do your users scroll through your content and click links in the footer?</li>
<li>Do your users click on an article title or the &#8220;continue reading&#8230;&#8221; link?</li>
<li>Do your users actually go through the items in my dropdown menu, or are they unaware of the dropdown menus?</li>
<li>Do your users follow your related blog entry suggestions?</li>
</ul>
<p class="center"><img src="http://briancray.com/wp-content/uploads/2009/12/navigationoptions.png"></p>
<h3>I&#8217;ll help you answer some of these questions right now</h3>
<p>Using Google Analytics&#8217; <a href="http://code.google.com/apis/analytics/docs/tracking/eventTrackerGuide.html">Event Tracking</a>, you can begin tracking arbitrary events&mdash;including your users&#8217; behaviors&mdash;<em>inside</em> your web pages.</p>
<p>Before you get started follow these 2 <strong>important steps</strong>:</p>
<ol>
<li>Migrate your Google Analytics tracking code to <a href="http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/">Asynchronous Tracking</a></li>
<li>Move <a href="http://jquery.com/">jQuery</a> to your &lt;head&gt; element (I know, it&#8217;s against <a href="http://developer.yahoo.com/performance/rules.html">optimization standards</a>, but the data payoff is worth it if you use <a href="http://www.mnot.net/cache_docs/">good caching techniques</a>)</li>
</ol>
<h4>The code</h4>
<p>Add this to the &lt;head&gt; element or alongside your current jQuery code (as long as that code is in the &lt;head&gt;).

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	 $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'a'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		<span style="color: #006600; font-style: italic;">// tell analytics to save event</span>
		<span style="color: #000066; font-weight: bold;">try</span> <span style="color: #009900;">&#123;</span>
			_gaq.<span style="color: #660066;">push</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'_trackEvent'</span><span style="color: #339933;">,</span> thisel.<span style="color: #660066;">parents</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'[id!=&quot;&quot;]:first'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">get</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">id</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'clicked'</span><span style="color: #339933;">,</span> <span style="color: #009900;">&#40;</span>thisel.<span style="color: #660066;">text</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> thisel.<span style="color: #660066;">children</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'img:first'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">attr</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'alt'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #000066; font-weight: bold;">catch</span> <span style="color: #009900;">&#40;</span>err<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span>
&nbsp;
		<span style="color: #006600; font-style: italic;">// pause to allow google script to run</span>
		<span style="color: #003366; font-weight: bold;">var</span> date <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> Date<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #003366; font-weight: bold;">var</span> curDate <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">null</span><span style="color: #339933;">;</span>
		<span style="color: #000066; font-weight: bold;">do</span> <span style="color: #009900;">&#123;</span>
			curDate <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> Date<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">while</span><span style="color: #009900;">&#40;</span>curDate<span style="color: #339933;">-</span>date <span style="color: #339933;">&lt;</span> <span style="color: #CC0000;">300</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<h4>Screenshot of Event Categories after installation</h4>
<p>After installing the code above, I can see which sections on my website receive the most clicks (based on the <abbr>ID</abbr> attribute of the element or parent elements).</p>
<p><img src="http://briancray.com/wp-content/uploads/2009/12/eventcategories.png"></p>
<h4>Screenshot of Event Labels after installation</h4>
<p>After installing the code above and drilling down on an Event Category (left), I can see the captions of the links that were clicked, for example, the link text of menu items as seen below.</p>
<p><img src="http://briancray.com/wp-content/uploads/2009/12/eventvalues.png"></p>
<h3>Getting even more user insight with Event Tracking</h3>
<p>This is just the beginning of the rabbit hole, Alice. With proper jQuery knowledge and a thirst for user insight, you can take this technique way further.</p>
<ul>
<li>Track form behavior and mouse behavior.</li>
<li>Track time between user actions</li>
<li>Make design changes, then watch how those design changes affect <em>actual</em> user behavior (similar to asynchronous A/B testing).</li>
</ul>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/' rel='bookmark' title='Permanent Link: Is your Google Analytics missing page views? Introducing Asynchronous Tracking'>Is your Google Analytics missing page views? Introducing Asynchronous Tracking</a></li>
<li><a href='http://briancray.com/2009/03/14/google-analytics-hack-track-outbound-links/' rel='bookmark' title='Permanent Link: Google Analytics Hack: Track Outbound Links In 2 Easy Steps'>Google Analytics Hack: Track Outbound Links In 2 Easy Steps</a></li>
<li><a href='http://briancray.com/2009/12/15/user-feedback-clicked-links-linknotify-2/' rel='bookmark' title='Permanent Link: Better user feedback on clicked links with linkNotify 2.0'>Better user feedback on clicked links with linkNotify 2.0</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=uDe8LqwkOug:4az2A_VelOw:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=uDe8LqwkOug:4az2A_VelOw:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=uDe8LqwkOug:4az2A_VelOw:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=uDe8LqwkOug:4az2A_VelOw:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=uDe8LqwkOug:4az2A_VelOw:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/uDe8LqwkOug" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/feed/</wfw:commentRss>
		<slash:comments>27</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/</feedburner:origLink></item>
		<item>
		<title>Impossibly simple image randomizer with jQuery</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/fh1DGw3z2-Y/</link>
		<comments>http://briancray.com/2009/12/28/simple-image-randomizer-jquery/#comments</comments>
		<pubDate>Mon, 28 Dec 2009 17:39:47 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1575</guid>
		<description><![CDATA[A common design pattern&#8212;if you want to call it that&#8212;is to display a random header image or advertisment on each new pageview. I&#8217;m always looking for ways to simplify code [see 1, 2, 3], and naturally, I tried to do it here.
Today&#8217;s impossibly simple code turns the task of image randomization into a 1-line jQuery [...]]]></description>
			<content:encoded><![CDATA[<p>A common design pattern&mdash;if you want to call it that&mdash;is to display a random header image or advertisment on each new pageview. I&#8217;m always looking for ways to simplify code [see <a href="http://briancray.com/2009/02/10/generate-tinyurls-with-1-line-of-php/">1</a>, <a href="http://briancray.com/2009/08/06/check-all-jquery-javascript/">2</a>, <a href="http://briancray.com/2009/04/25/remove-null-values-php-arrays/">3</a>], and naturally, I tried to do it here.</p>
<p>Today&#8217;s impossibly simple code turns the task of image randomization into a 1-line jQuery code snippet. Awesome.</p>
<p><span id="more-1575"></span></p>
<h3>1. Start with an array of images</h3>
<p>Change the image filenames in the array to the <em>actual</em> filenames. Don&#8217;t include the directory&mdash;filenames only.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #003366; font-weight: bold;">var</span> images <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'image1.jpg'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'image2.jpg'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'image3.jpg'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'image4.jpg'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'image5.jpg'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<h3>2a. Set a random header background with jQuery and CSS background-image</h3>
<p>The following code assumes your header has an <abbr>ID</abbr> of #header and your images directory is just &#8220;/images&#8221;. Change them if necessary.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#header'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">css</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span><span style="color: #3366CC;">'background-image'</span><span style="color: #339933;">:</span> <span style="color: #3366CC;">'url(images/'</span> <span style="color: #339933;">+</span> images<span style="color: #009900;">&#91;</span>Math.<span style="color: #660066;">floor</span><span style="color: #009900;">&#40;</span>Math.<span style="color: #660066;">random</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">*</span> images.<span style="color: #660066;">length</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">+</span> <span style="color: #3366CC;">')'</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>

<h3>2b. Insert a random advertisement with jQuery and DOM injection</h3>
<p>The following code assumes your ad container has an <abbr>ID</abbr> of #ad and your images directory is just &#8220;/images&#8221;. Change them if necessary.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'&lt;img src=&quot;images/'</span> <span style="color: #339933;">+</span> images<span style="color: #009900;">&#91;</span>Math.<span style="color: #660066;">floor</span><span style="color: #009900;">&#40;</span>Math.<span style="color: #660066;">random</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">*</span> images.<span style="color: #660066;">length</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">+</span> <span style="color: #3366CC;">'&quot;&gt;'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">appendTo</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#ad'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></td></tr></table></div>



<p>Related posts:<ol><li><a href='http://briancray.com/2009/09/30/remove-value-javascript-array/' rel='bookmark' title='Permanent Link: How to remove a specific value from a javascript array'>How to remove a specific value from a javascript array</a></li>
<li><a href='http://briancray.com/2009/05/06/twitter-style-alert-jquery-cs-php/' rel='bookmark' title='Permanent Link: How to create a Twitter-style alert with jQuery, CSS, and PHP'>How to create a Twitter-style alert with jQuery, CSS, and PHP</a></li>
<li><a href='http://briancray.com/2009/07/28/increase-form-usability-replace-form-button-submit/' rel='bookmark' title='Permanent Link: Web form usability: Better form submission feedback with jQuery'>Web form usability: Better form submission feedback with jQuery</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fh1DGw3z2-Y:i0HVTnBrvZU:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fh1DGw3z2-Y:i0HVTnBrvZU:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fh1DGw3z2-Y:i0HVTnBrvZU:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=fh1DGw3z2-Y:i0HVTnBrvZU:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=fh1DGw3z2-Y:i0HVTnBrvZU:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/fh1DGw3z2-Y" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/28/simple-image-randomizer-jquery/feed/</wfw:commentRss>
		<slash:comments>15</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/28/simple-image-randomizer-jquery/</feedburner:origLink></item>
		<item>
		<title>Is your Google Analytics missing page views? Introducing Asynchronous Tracking</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/DVXHXDF_I7U/</link>
		<comments>http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/#comments</comments>
		<pubDate>Mon, 21 Dec 2009 06:19:51 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[web analytics]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1534</guid>
		<description><![CDATA[<p>What happens to your Google Analytics if someone leaves the page before it has fully loaded? The page view doesn't get recorded and Google Analytics fails as an accurate source of user data.</p>
<p>Google has fixed missing data issues with <a href="http://code.google.com/apis/analytics/docs/tracking/asyncTracking.html">Asynchronous Tracking</a>. Just read this quote straight from the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncUsageGuide.html#EventHandlers">Asynchronous Tracking documentation</a>:</p>

<blockquote><p>"Even if [a] button is clicked before the browser has finished loading ga.js, the event will be captured and eventually executed. Using traditional tracking, the browser might throw an exception in this situation."</p></blockquote>]]></description>
			<content:encoded><![CDATA[<p>What happens to your Google Analytics if someone leaves the page before it has fully loaded? The page view doesn&#8217;t get recorded and Google Analytics fails as an accurate source of user data.</p>
<h3>Asynchronous Tracking for Google Analytics</h3>
<p>Google has fixed missing data issues with <a href="http://code.google.com/apis/analytics/docs/tracking/asyncTracking.html">Asynchronous Tracking</a>. Just read this quote straight from the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncUsageGuide.html#EventHandlers">Asynchronous Tracking documentation</a>:</p>
<blockquote><p>&#8220;Even if [a] button is clicked before the browser has finished loading ga.js, the event will be captured and eventually executed. Using traditional tracking, the browser might throw an exception in this situation.&#8221;</p>
</blockquote>
<p>While this quote refers to <a href="http://code.google.com/apis/analytics/docs/tracking/eventTrackerOverview.html">event tracking</a>, I believe it applies to any of Google Analytics&#8217; tracking methods, including page views.</p>
<p>Google Analytics Asynchronous Tracking works by <a href="http://code.google.com/apis/analytics/docs/tracking/asyncMigrationExamples.html">queuing up tracking commands</a> for execution when the analytics script finishes loading. Since the Asynchronous Tracking code is put in the &lt;head&gt; of an <abbr>HTML</abbr> document, it will always finish loading in time.</p>
<h3>Comparing traditional vs. Asynchronous Tracking code</h3>
<h4>Traditional tracking code for Google Analytics</h4>
<ul>
<li>Goes at the end of an <abbr>HTML</abbr> document, before <code>&lt;/body&gt;</code></li>
<li>Uses <code>document.write</code> to insert script</li>
<li>Doesn&#8217;t capture events before page load</li>
</ul>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
<span style="color: #003366; font-weight: bold;">var</span> gaJsHost <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;https:&quot;</span> <span style="color: #339933;">==</span> document.<span style="color: #660066;">location</span>.<span style="color: #660066;">protocol</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">?</span> <span style="color: #3366CC;">&quot;https://ssl.&quot;</span> <span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;http://www.&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
document.<span style="color: #000066; font-weight: bold;">write</span><span style="color: #009900;">&#40;</span>unescape<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;%3Cscript src='&quot;</span> <span style="color: #339933;">+</span> gaJsHost <span style="color: #339933;">+</span> <span style="color: #3366CC;">&quot;google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span>
<span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
<span style="color: #000066; font-weight: bold;">try</span><span style="color: #009900;">&#123;</span>
<span style="color: #003366; font-weight: bold;">var</span> pageTracker <span style="color: #339933;">=</span> _gat._getTracker<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;UA-xxxxxx-x&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
pageTracker._trackPageview<span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span> <span style="color: #000066; font-weight: bold;">catch</span><span style="color: #009900;">&#40;</span>err<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></td></tr></table></div>

<h4>Asynchronous Tracking code for Google Analytics</h4>
<ul>
<li>Goes at the beginning of an <abbr>HTML</abbr> document, before <code>&lt;/head&gt;</code></li>
<li>Uses a <abbr>DOM</abbr> injection to insert script (geeks should like that one)</li>
<li>Captures events prior to page load</li>
</ul>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
7
8
9
10
11
12
13
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #339933;">&lt;</span>script type<span style="color: #339933;">=</span><span style="color: #3366CC;">&quot;text/javascript&quot;</span><span style="color: #339933;">&gt;</span>
&nbsp;
  <span style="color: #003366; font-weight: bold;">var</span> _gaq <span style="color: #339933;">=</span> _gaq <span style="color: #339933;">||</span> <span style="color: #009900;">&#91;</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
  _gaq.<span style="color: #660066;">push</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'_setAccount'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'UA-XXXXX-X'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  _gaq.<span style="color: #660066;">push</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'_trackPageview'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
  <span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #003366; font-weight: bold;">var</span> ga <span style="color: #339933;">=</span> document.<span style="color: #660066;">createElement</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'script'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> ga.<span style="color: #660066;">type</span> <span style="color: #339933;">=</span> <span style="color: #3366CC;">'text/javascript'</span><span style="color: #339933;">;</span> ga.<span style="color: #660066;">async</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">true</span><span style="color: #339933;">;</span>
    ga.<span style="color: #660066;">src</span> <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'https:'</span> <span style="color: #339933;">==</span> document.<span style="color: #660066;">location</span>.<span style="color: #660066;">protocol</span> <span style="color: #339933;">?</span> <span style="color: #3366CC;">'https://ssl'</span> <span style="color: #339933;">:</span> <span style="color: #3366CC;">'http://www'</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">+</span> <span style="color: #3366CC;">'.google-analytics.com/ga.js'</span><span style="color: #339933;">;</span>
    <span style="color: #009900;">&#40;</span>document.<span style="color: #660066;">getElementsByTagName</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'head'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#91;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">||</span> document.<span style="color: #660066;">getElementsByTagName</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'body'</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#91;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">appendChild</span><span style="color: #009900;">&#40;</span>ga<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
  <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #339933;">&lt;/</span>script<span style="color: #339933;">&gt;</span></pre></td></tr></table></div>

<h3>Begin using Google Analytics Asynchronous Tracking today</h3>
<p>I became aware of Asynchronous Tracking thanks to <a href="http://www.webresourcesdepot.com/tracking-new-rss-subscribers-with-google-analytics-to-understand-them-better/">this article on Web Resources Depot</a>, and I&#8217;ve been using it since. So far there have been no issues with tracking or loading times. In fact, there seems to be improvements in load times and reporting.</p>
<p>If you <strong>do not</strong> use <a href="http://www.google.com/analytics/features.html#customized_reporting">advanced tracking options</a> such as <a href="http://code.google.com/apis/analytics/docs/tracking/eventTrackerOverview.html">event tracking</a> or <a href="http://code.google.com/apis/analytics/docs/tracking/gaTrackingCustomVariables.html">custom variables</a>, just replace your current tracking code with the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncTracking.html#Snippet">Asynchronous Tracking code</a> (above) and you&#8217;re done!</p>
<p>If you <strong>do</strong> use <a href="http://www.google.com/analytics/features.html#customized_reporting">advanced tracking options</a> make sure you read over the <a href="http://code.google.com/apis/analytics/docs/tracking/asyncMigrationExamples.html">Asynchronous migration examples</a> and migrate all of your tracking code to the new format.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/' rel='bookmark' title='Permanent Link: Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery'>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery</a></li>
<li><a href='http://briancray.com/2009/03/14/google-analytics-hack-track-outbound-links/' rel='bookmark' title='Permanent Link: Google Analytics Hack: Track Outbound Links In 2 Easy Steps'>Google Analytics Hack: Track Outbound Links In 2 Easy Steps</a></li>
<li><a href='http://briancray.com/2009/08/07/track-subscriber-inbound-traffic-google-analytics-wordpress/' rel='bookmark' title='Permanent Link: Wordpress plugin: Track subscriber inbound traffic in Google Analytics'>Wordpress plugin: Track subscriber inbound traffic in Google Analytics</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=DVXHXDF_I7U:8D3rOz5rYwE:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=DVXHXDF_I7U:8D3rOz5rYwE:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=DVXHXDF_I7U:8D3rOz5rYwE:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=DVXHXDF_I7U:8D3rOz5rYwE:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=DVXHXDF_I7U:8D3rOz5rYwE:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/DVXHXDF_I7U" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/20/asynchronous-tracking-google-analytics/</feedburner:origLink></item>
		<item>
		<title>Better user feedback on clicked links with linkNotify 2.0</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/EcLGd63ct4o/</link>
		<comments>http://briancray.com/2009/12/15/user-feedback-clicked-links-linknotify-2/#comments</comments>
		<pubDate>Tue, 15 Dec 2009 15:38:14 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[jquery]]></category>
		<category><![CDATA[navigation]]></category>
		<category><![CDATA[open source]]></category>
		<category><![CDATA[plugins]]></category>
		<category><![CDATA[usability]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1510</guid>
		<description><![CDATA[<p>linkNotify 2.0 is a jQuery plugin that provides better user feedback on clicked links than the browser by displaying a color-changeable progress bar behind the link.</p>]]></description>
			<content:encoded><![CDATA[<p>linkNotify 2.0 is a jQuery plugin that provides better user feedback on clicked links than the browser by displaying a color-changeable progress bar behind the link.</p>
<h3>See linkNotify 2.0 in action</h3>
<p><object width="425" height="344"><param name="movie" value="http://www.youtube.com/v/51sJA_8xAAk&#038;hl=en&#038;fs=1"></param><param name="allowFullScreen" value="true"></param><param name="allowscriptaccess" value="always"></param><embed src="http://www.youtube.com/v/51sJA_8xAAk&#038;hl=en&#038;fs=1" type="application/x-shockwave-flash" allowscriptaccess="always" allowfullscreen="true" width="425" height="344"></embed></object></p>
<h3>Why do I need linkNotify?</h3>
<p>Have you ever seen someone click a link over and over waiting for the next page to load? It&#8217;s a bad habit that&#8217;s actually counter-productive because it causes the next page&#8217;s loading to start over. This user behavior phenomenon occurs because browsers do a bad job giving feedback to the user that their click was successful and the next page is loading.</p>
<p>So what&#8217;s the problem? <em>Feedback proximity</em>.</p>
<p>Users aren&#8217;t looking for feedback where browsers have a progress bar. Users are staring at the page where they clicked and wondering why a new page hasn&#8217;t loaded. <strong>The loading feedback needs to be closer to the action (the click).</strong> That&#8217;s why I&#8217;ve developed linkNotify&mdash;to enhance the feedback of link clicks to improve the user&#8217;s experience of control.</p>
<h3>Changes in version 2</h3>
<table class="styled">
<tr>
<th style="background-color:#fff"></th>
<th>Old version (1.x)</th>
<th>New version (2.0)</th>
<th>Benefit of change</th>
</tr>
<tr class="odd">
<th class="right">Feedback</th>
<td>Clicked link text changes to &#8220;Loading&hellip;</td>
<td>A progress bar behind the clicked link</td>
<td>No more layout issues; Progress bar animation more accurately visualizes progression of time</td>
</tr>
<tr class="even">
<th class="right">Plugin parameter</th>
<td>Loading link text (Loading&hellip; is default)</td>
<td>Progress bar color <span style="background-color:#eeeeee">(#eeeeee is default)</span></td>
<td>Change the progress bar color to match your theme</td>
</tr>
<tr class="odd">
<th class="right">Open in new tab/window</th>
<td>Always activates</td>
<td>Doesn&#8217;t activate if opening in a new window or tab</td>
<td>The old version changed the layout of a page that remained open</td>
</tr>
<tr class="even">
<th class="right">Image links</th>
<td>Always activates</td>
<td>Doesn&#8217;t activate on image links</td>
<td>Looked unnatural when a big image would change to &#8220;Loading&hellip;&#8221;</td>
</tr>
<tr class="odd">
<th class="right">Results</th>
<td>Needs improvement</td>
<td>Awesome</td>
<td></td>
</tr>
</table>
<h3>How to use</h3>
<h4>Using selectors to choose which links to improve with linkNotify 2.0</h4>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'a'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">linkNotify</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// work on all links with the default color of #eeeeee (light grey)</span>
$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#content'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">linkNotify</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// work on all links in the content area only</span>
$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">':not(#menu) a'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">linkNotify</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// work on all links that aren't in the menu</span></pre></div></div>

<h4>Changing the default progress bar color from #eeeeee</h4>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'a'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">linkNotify</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#ff0000'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// red as hex color</span>
$<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'a'</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">linkNotify</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'blue'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// also takes color names</span></pre></div></div>

<h3><a href="http://plugins.jquery.com/files/jquery.linknotify-2.0.js.txt">Download linkNotify 2.0</a></h3>
<h4><a href="http://plugins.jquery.com/files/jquery.linknotify-2.0.js.txt">Download linkNotify 2.0</a></h4>
<p>You can also see the plugin page hosted on jQuery at <a href="http://plugins.jquery.com/project/linknotify">http://plugins.jquery.com/project/linknotify</a></p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/06/09/jquery-plugin-linknotify-inline-link-click-notification/' rel='bookmark' title='Permanent Link: New jQuery plugin: linkNotify() &#8211; An inline link click notification'>New jQuery plugin: linkNotify() &#8211; An inline link click notification</a></li>
<li><a href='http://briancray.com/2009/12/29/understanding-user-behavior-google-analytics-event-tracking-jquery/' rel='bookmark' title='Permanent Link: Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery'>Diving deep into user behavior with Google Analytics, Event Tracking, and jQuery</a></li>
<li><a href='http://briancray.com/2010/01/26/ux-case-study-designing-user-focused-web-app/' rel='bookmark' title='Permanent Link: UX Case Study: Designing a user-focused web app'>UX Case Study: Designing a user-focused web app</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=EcLGd63ct4o:_rf3pUkLkz4:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=EcLGd63ct4o:_rf3pUkLkz4:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=EcLGd63ct4o:_rf3pUkLkz4:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=EcLGd63ct4o:_rf3pUkLkz4:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=EcLGd63ct4o:_rf3pUkLkz4:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/EcLGd63ct4o" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/15/user-feedback-clicked-links-linknotify-2/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/15/user-feedback-clicked-links-linknotify-2/</feedburner:origLink></item>
		<item>
		<title>Javascript snippet: Find the value of a string key in a multidimensional array or object</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/eQxeHrCRA1Q/</link>
		<comments>http://briancray.com/2009/12/07/javascript-find-value-string-key-multidimensional-array-object/#comments</comments>
		<pubDate>Mon, 07 Dec 2009 14:08:59 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1452</guid>
		<description><![CDATA[<p>While building <a href="http://nearbytweets.com/v2">Nearby Tweets v2</a> I had trouble grabbing the proper city/state/country name out of <a href="http://code.google.com/apis/maps/">Google Maps API's</a> <a href="http://code.google.com/apis/maps/documentation/services.html#Geocoding_Structured">Geocoding JSON object</a>. The problem was that the JSON object is structured differently for different places across the world.</p>

<p>After multiple tweaks to pick the right information out of an unpredictable multidimensional structure, I finally decided to <strong>search the object for the keys I wanted</strong> and return their values. That way it wouldn't matter if the structure changed. But alas, I couldn't find a function that searches a multidimensional array or object for a string key and returns the value. So, I had to write my own.</p>]]></description>
			<content:encoded><![CDATA[<p>While building <a href="http://nearbytweets.com/v2">Nearby Tweets v2</a> I had trouble grabbing the proper city/state/country name out of <a href="http://code.google.com/apis/maps/">Google Maps API&#8217;s</a> <a href="http://code.google.com/apis/maps/documentation/services.html#Geocoding_Structured">Geocoding JSON object</a>. The problem was that the JSON object is structured differently for different places across the world.</p>
<p>After multiple tweaks to pick the right information out of an unpredictable multidimensional structure, I finally decided to <strong>search the object for the keys I wanted</strong> and return their values. That way it wouldn&#8217;t matter if the structure changed. But alas, I couldn&#8217;t find a function that searches a multidimensional array or object for a string key and returns the value. So, I had to write my own.</p>
<h3>Javascript source code</h3>
<p>This modifies the String prototype to add the functionality we need. Using the string value of the object it runs on as the string key name, this function takes a multidimensional array or object as its parameter, and returns the first value it comes across (it does not continue to search).</p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #006600; font-style: italic;">// Use: stringvalue.findIn(multi_dimensional_array_or_object)</span>
<span style="color: #006600; font-style: italic;">/***Example: 
    var tofind = 'emotion';
    var person = {'name': 'Bob Loblaw', 'age': '28', 'personality': {'smart': 'yes', 'funny': 'yes', 'emotion': 'happy'} };
    tofind.findIn(person) = 'happy'
***/</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// The code that does it all:</span>
String.<span style="color: #660066;">prototype</span>.<span style="color: #660066;">findIn</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span>multi<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
	multi <span style="color: #339933;">=</span> multi <span style="color: #339933;">||</span> <span style="color: #3366CC;">''</span><span style="color: #339933;">;</span>
	<span style="color: #003366; font-weight: bold;">var</span> val <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">valueOf</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000066; font-weight: bold;">typeof</span> multi <span style="color: #339933;">==</span> <span style="color: #3366CC;">'object'</span> <span style="color: #339933;">||</span> <span style="color: #000066; font-weight: bold;">typeof</span> multi <span style="color: #339933;">==</span> <span style="color: #3366CC;">'array'</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>val <span style="color: #000066; font-weight: bold;">in</span> multi<span style="color: #009900;">&#41;</span>
		<span style="color: #009900;">&#123;</span>
			<span style="color: #000066; font-weight: bold;">return</span> multi<span style="color: #009900;">&#91;</span>val<span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
		<span style="color: #009900;">&#125;</span>
		<span style="color: #000066; font-weight: bold;">else</span>
		<span style="color: #009900;">&#123;</span>
			<span style="color: #000066; font-weight: bold;">for</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">var</span> x <span style="color: #000066; font-weight: bold;">in</span> multi<span style="color: #009900;">&#41;</span>
			<span style="color: #009900;">&#123;</span>
				<span style="color: #003366; font-weight: bold;">var</span> found <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">findIn</span><span style="color: #009900;">&#40;</span>multi<span style="color: #009900;">&#91;</span>x<span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
				<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>found <span style="color: #339933;">!=</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span>
				<span style="color: #009900;">&#123;</span>
					<span style="color: #000066; font-weight: bold;">return</span> found<span style="color: #339933;">;</span>
				<span style="color: #009900;">&#125;</span>
			<span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000066; font-weight: bold;">return</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span></pre></div></div>



<p>Related posts:<ol><li><a href='http://briancray.com/2009/09/30/remove-value-javascript-array/' rel='bookmark' title='Permanent Link: How to remove a specific value from a javascript array'>How to remove a specific value from a javascript array</a></li>
<li><a href='http://briancray.com/2009/04/01/how-to-calculate-the-distance-between-two-addresses-with-javascript-and-google-maps-api/' rel='bookmark' title='Permanent Link: How to calculate distance with javascript and Google Maps API'>How to calculate distance with javascript and Google Maps API</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=eQxeHrCRA1Q:63DFfynvg2o:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=eQxeHrCRA1Q:63DFfynvg2o:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=eQxeHrCRA1Q:63DFfynvg2o:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=eQxeHrCRA1Q:63DFfynvg2o:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=eQxeHrCRA1Q:63DFfynvg2o:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/eQxeHrCRA1Q" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/07/javascript-find-value-string-key-multidimensional-array-object/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/07/javascript-find-value-string-key-multidimensional-array-object/</feedburner:origLink></item>
		<item>
		<title>How wireframing makes your website designs better</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/oemTdzz_zLo/</link>
		<comments>http://briancray.com/2009/12/02/value-of-wireframing-website-design/#comments</comments>
		<pubDate>Wed, 02 Dec 2009 20:01:21 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[User experience]]></category>
		<category><![CDATA[freelancing]]></category>
		<category><![CDATA[information architecture]]></category>
		<category><![CDATA[wireframing]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1440</guid>
		<description><![CDATA[Wireframing in terms of website design means to create a basic &#8220;sketch&#8221; of your website&#8217;s user interface. While many web designers jump straight from client meeting to Adobe Photoshop, or even to creating CSS and HTML prototypes, they are missing important opportunities in the website design process. Wireframing addresses extremely important issues in strategic design, [...]]]></description>
			<content:encoded><![CDATA[<p>Wireframing in terms of website design means to create a basic &#8220;sketch&#8221; of your website&#8217;s user interface. While many web designers jump straight from client meeting to Adobe Photoshop, or even to creating <abbr>CSS</abbr> and <abbr>HTML</abbr> prototypes, they are missing important opportunities in the website design process. Wireframing addresses extremely important issues in strategic design, client adoption, and user-centered design.</p>
<p>The value of wireframing comes down to a simple idea: Wireframing forces you to think about your user interface design decisions in terms of user needs first, instead of in terms of what looks good.</p>
<p><span id="more-1440"></span></p>
<h3>Ideal website design deliverables from start to finish</h3>
<p class="center"><img src="http://briancray.com/wp-content/uploads/2009/12/stagesofwebdesign.png" alt="Stages of website design"></p>
<h3>Removing the wireframe from the website design process</h3>
<p class="center"><img src="http://briancray.com/wp-content/uploads/2009/12/skippedwireframe.png" alt="Stages of website design without wireframing is bad"></p>
<p>Without wireframing your website designs, you&#8217;re vulnerable to these design pitfalls:</p>
<ul>
<li><strong>Lack of focus on strategic UI design.</strong> Taking a website design from conceptual design to UI means considering the strategic value of UI components, which doesn&#8217;t always happen when you&#8217;re considering 48 shades of red.</li>
<li><strong>Client focuses on appearance rather than strategy.</strong> It&#8217;s easy to get caught up in how something looks, and everyone thinks they&#8217;re an expert on looks. Using wireframes helps keep everyone&#8217;s focus on strategic design decisions.</li>
<li><strong>Unable to justify user interface design decisions to stakeholders.</strong> If you&#8217;ve carefully thought about the value of UI components before moving into skinning and prototyping, you&#8217;re armed with the power of reason against inevitable uninformed criticisms.</li>
<li><strong>Changes to page structure are more difficult in later stages.</strong> If you&#8217;ve already tweaked everything to look beautiful in Photoshop, changes to structural issues can quickly turn into massive headaches. Moving things around in a wireframe is super simple.</li>
</ul>
<h3>How to start wireframing</h3>
<p>Starting to wireframe websites can range from something as simple as sketching layout ideas on a napkin to using more advanced wireframing software, such as <a href="http://www.omnigroup.com/applications/OmniGraffle/">OmniGraffle</a> for OS X users or <a href="http://office.microsoft.com/en-us/visio/FX100487861033.aspx">MS Visio</a> for Windows users. Other options include graphing paper, which helps make straight and measured lines, or web-based options such as <a href="http://gomockingbird.com/">Mockingbird</a> or <a href="http://www.balsamiq.com/products/mockups">Balsamiq Mockups</a>.</p>
<p>The important thing is to focus on the strategic <em>why</em> while you sketch things out, and not on what shade of blue you&#8217;ll use or what technology you&#8217;ll use. Usually website designs that have been &#8220;wireframed&#8221; turn out simpler to design and easier to use.</p>
<h3>Conclusion</h3>
<p>Taking time to wireframe your website can save time and headaches further along in the website design process for both you <em>and</em> your clients. On your next website, put a wireframe in front of your client and work together on strategic design decisions <em>before</em> jumping in front of Photoshop. You may be happy with the results.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/09/22/needs-assessment-web-design/' rel='bookmark' title='Permanent Link: Needs assessment: the most important process in web design'>Needs assessment: the most important process in web design</a></li>
<li><a href='http://briancray.com/2009/05/01/9-reasons-single-purpose-website-app/' rel='bookmark' title='Permanent Link: 9 compelling reasons to build a single-purpose website'>9 compelling reasons to build a single-purpose website</a></li>
<li><a href='http://briancray.com/2009/06/07/rethinking-website-navigation-design/' rel='bookmark' title='Permanent Link: Rethinking website navigation design'>Rethinking website navigation design</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=oemTdzz_zLo:skWabpWKXOo:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=oemTdzz_zLo:skWabpWKXOo:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=oemTdzz_zLo:skWabpWKXOo:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=oemTdzz_zLo:skWabpWKXOo:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=oemTdzz_zLo:skWabpWKXOo:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/oemTdzz_zLo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/12/02/value-of-wireframing-website-design/feed/</wfw:commentRss>
		<slash:comments>38</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/12/02/value-of-wireframing-website-design/</feedburner:origLink></item>
		<item>
		<title>Wireframing Freebie: 960 grid template for OmniGraffle</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/hw4Urp5AZPQ/</link>
		<comments>http://briancray.com/2009/11/30/omnigraffle-wireframing-960-grid-template/#comments</comments>
		<pubDate>Mon, 30 Nov 2009 16:12:10 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[Web development]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[freebies]]></category>
		<category><![CDATA[wireframing]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1432</guid>
		<description><![CDATA[I&#8217;m a big fan of increasing efficiency and consistency from conceptual design to implementation. This OmniGraffle template has helped me quite a bit in that regard, and I decided to share it with others.

Installation

Download Website (960 grid).gtemplate OmniGraffle template (Apple OS X only)
Move from Downloads to /Users/xxxxx/Library/Application Support/OmniGraffle/Templates/ where xxxxx is your OS X username
When [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m a big fan of increasing efficiency and consistency from conceptual design to implementation. This OmniGraffle template has helped me quite a bit in that regard, and I decided to share it with others.</p>
<p><span id="more-1432"></span></p>
<h3>Installation</h3>
<ol>
<li>Download <a href="http://dl.dropbox.com/u/2360597/Website%20%28960%20grid%29.gtemplate">Website (960 grid).gtemplate</a> OmniGraffle template (Apple OS X only)</li>
<li>Move from Downloads to <strong>/Users/<em>xxxxx</em>/Library/Application Support/OmniGraffle/Templates/</strong> where <em>xxxxx</em> is your OS X username</li>
<li>When starting a new document in OmniGraffle, select Website (960 grid) as your template</li>
</ol>
<p class="center"><img src="http://briancray.com/wp-content/uploads/2009/11/960gridfeatures.png" alt="Features of 960 grid Omnigraffle template"></p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/02/value-of-wireframing-website-design/' rel='bookmark' title='Permanent Link: How wireframing makes your website designs better'>How wireframing makes your website designs better</a></li>
<li><a href='http://briancray.com/2010/01/04/popular-posts-social-media-engagement-postrank-top-posts-api/' rel='bookmark' title='Permanent Link: Display popular posts based on social media engagement with PostRank Top Posts API'>Display popular posts based on social media engagement with PostRank Top Posts API</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=hw4Urp5AZPQ:lMIqwRq9-uc:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=hw4Urp5AZPQ:lMIqwRq9-uc:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=hw4Urp5AZPQ:lMIqwRq9-uc:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=hw4Urp5AZPQ:lMIqwRq9-uc:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=hw4Urp5AZPQ:lMIqwRq9-uc:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/hw4Urp5AZPQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/11/30/omnigraffle-wireframing-960-grid-template/feed/</wfw:commentRss>
		<slash:comments>11</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/11/30/omnigraffle-wireframing-960-grid-template/</feedburner:origLink></item>
		<item>
		<title>Online community best practices: Effective signup process</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/qxkPYxiE6rQ/</link>
		<comments>http://briancray.com/2009/11/13/signup-process-online-community-best-practices/#comments</comments>
		<pubDate>Fri, 13 Nov 2009 14:13:28 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[conversion optimization]]></category>
		<category><![CDATA[forms]]></category>
		<category><![CDATA[information architecture]]></category>
		<category><![CDATA[online communities]]></category>
		<category><![CDATA[usability]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1309</guid>
		<description><![CDATA[This article focuses on providing new members with an effective join/signup process. Although some of these principles may seem obvious, I&#8217;ve gone through plenty of membership signup forms that still suck. So hence the post.

4 elements of an effective online community signup process
1. Easy to use web form design
As Luke Wroblewski put it in Web [...]]]></description>
			<content:encoded><![CDATA[<p>This article focuses on providing new members with an effective join/signup process. Although some of these principles may seem obvious, I&#8217;ve gone through plenty of membership signup forms that still suck. So hence the post.</p>
<p><span id="more-1309"></span></p>
<h3>4 elements of an effective online community signup process</h3>
<h4>1. Easy to use web form design</h4>
<p>As Luke Wroblewski put it in <a href="http://www.uie.com/articles/form_design_wild/">Web Form Design in the Wild, Part II</a>, &#8220;Forms control the gates of membership.&#8221; Never take form design with a grain of salt. Filling out web forms requires the highest level of user commitment and are the most complex UI elements of a website.</p>
<p>Although people kill time browsing the Web, they don&#8217;t kill that time by looking for the next web form to fill out. In fact, you and I, as well as every other user out there in the world avoid web forms like the plague. So if your signup form is complicated then go ahead and call it quits. Complex forms are the bane of conversion.</p>
<p>Here are a few quick tips to make your web forms easier to use:</p>
<ul>
<li>Make form fields and labels align vertically, not horizontally</li>
<li>Make form field size relative to the expected input length</li>
<li>If it must be a long form, break it into logical sections (a quick card sort can help do that)</li>
<li>Show an example of expected input</li>
<li>Don&#8217;t force the user to follow formats (like xxx-xxx-xxxx). Format input after submission programmatically</li>
<li>Make the call to action, or submit button, very easy to find</li>
<li>Avoid CAPTCHA by using better data validation. Deleting a few spam accounts is better than pissing users off from the start</li>
</ul>
<h4>2. Lazy registration</h4>
<p>Lazy registration is a relatively new concept to the scene, made possible by increasing levels of interactivity on the Web. What is lazy registration? While guests use the features available to them, their behaviors and preferences are stored in cookies. When guests finally register because your online community website kicks ass, some of the information is already filled out from the cookies.</p>
<p>An example of lazy registration is if a guest posts a comment and inputs their name and email address, that information is stored in a cookie. When he signups because he wants a profile and access to member-only benefits, the signup form will draw that information from cookies, saving users valuable time and keystrokes.</p>
<h4>3. Partial commitment</h4>
<p>Partial commitment is a persuasion strategy as old as dirt. It&#8217;s the reason why you&#8217;re more likely to keep hearing &#8220;yes&#8221; if a person has been responding with &#8220;yes.&#8221; It&#8217;s the reason why that tricky car salesman asks you to take a test drive. Commitment in little chunks at a time simply works. While some of these tricks <em>are</em> unethical exploitations, getting partial commitment to increase online community signups on the web is not only an effective sales technique, it&#8217;s good for users, too.</p>
<p>The benefit to users is somewhat related to the idea of <a href="http://www.useit.com/alertbox/progressive-disclosure.html">progressive disclosure</a> in that users only need what they need in each moment to complete a task because any more is overwhelming. In terms of online community commitment, users don&#8217;t want to spend time writing a biography to join your online community. They want to do the minimum required to start playing. They&#8217;ll give you more information as they find another benefit they want to unlock.</p>
<p>If you&#8217;re thinking, &#8220;I&#8217;ll give them a complete form, but mark only a few fields as required,&#8221; you should know that users tend to fill out all fields and ignore requirements. Just give them the bare minimum fields required to sign up initially, and all other fields available to fill out at their leisure.</p>
<h4>4. Build confidence</h4>
<p>As with any commitment, people need confidence in their decision. When submitting personal information over the web, users need to be confident that their information is <strong>protected and respected</strong>.</p>
<p>The most important thing is to address their concern for privacy, which is usually done through a privacy policy. Most privacy policies are failures because they are stuffed down into the footer&mdash;a place where users never look when filling out forms&mdash;and they are full of legal jargon gobbledygook. When has legal jargon gobbledygook ever made <em>you</em> feel comforted?</p>
<p>Good privacy policies are short, written in plain speak, and very easy to find&mdash;like a link at the top of the form. Give the link to your privacy policy a teaser, such as &#8220;We have a privacy policy to keep your information private. [link to privacy policy].&#8221;</p>
<p>Other elements of building user confidence include</p>
<ul>
<li>Well designed UI</li>
<li>Consistent branding from page to page</li>
<li>A secure form (use a lock icon above the form, don&#8217;t rely on the https in the address bar to tell the story)</li>
<li>Pull quotes from current members</li>
<li>Reinforcement of membership benefits</li>
</ul>
<h4>Bonus tip: Confirmation</h4>
<p>Although you&#8217;ve led your new members through an effective signup process, your followup/confirmation e-mail is just as important. Followup e-mails play key roles in the signup process:</p>
<ul>
<li>Users feel confident that they successfully completed the process</li>
<li>Users have a record of their username and password (because they&#8217;ll forget it almost certainly)</li>
<li>Users are reminded of their account later as they browse their inbox</li>
<li>Followups are great opportunities to progressively &#8220;sale&#8221; additional benefits of membership. Provide them with ideas of what they can begin doing</li>
</ul>
<h3>Conclusion</h3>
<p>Your signup form may be the most crucial part of your online community. You should be doing everything you can to insure an easy signup process that makes the user feel safe.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/07/31/online-community-best-practices-reward-top-users/' rel='bookmark' title='Permanent Link: Online community best practices: Reward your top users'>Online community best practices: Reward your top users</a></li>
<li><a href='http://briancray.com/2009/03/05/guidelines-for-highly-effective-websites/' rel='bookmark' title='Permanent Link: Guidelines for highly effective Websites'>Guidelines for highly effective Websites</a></li>
<li><a href='http://briancray.com/2009/07/27/eye-tracking-studies-influence-redesign/' rel='bookmark' title='Permanent Link: 3 eye tracking studies that influenced my latest redesign'>3 eye tracking studies that influenced my latest redesign</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qxkPYxiE6rQ:-OptE88JQNc:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qxkPYxiE6rQ:-OptE88JQNc:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qxkPYxiE6rQ:-OptE88JQNc:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qxkPYxiE6rQ:-OptE88JQNc:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qxkPYxiE6rQ:-OptE88JQNc:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/qxkPYxiE6rQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/11/13/signup-process-online-community-best-practices/feed/</wfw:commentRss>
		<slash:comments>16</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/11/13/signup-process-online-community-best-practices/</feedburner:origLink></item>
		<item>
		<title>A focusing of Brian Cray’s blog content</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/zs2zeA4AjNQ/</link>
		<comments>http://briancray.com/2009/10/28/focusing-brian-crays-blog-content/#comments</comments>
		<pubDate>Wed, 28 Oct 2009 14:24:16 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1329</guid>
		<description><![CDATA[I haven&#8217;t posted in a while. In fact it&#8217;s been 18 days. That&#8217;s a long time in the blogging world.
Why has it been so long you ask? The past few weeks I&#8217;ve been cranking out Nearby Tweets v2, and today it hit private beta stage. By the way feel free to request private beta access [...]]]></description>
			<content:encoded><![CDATA[<p>I haven&#8217;t posted in a while. In fact it&#8217;s been 18 days. That&#8217;s a long time in the blogging world.</p>
<p>Why has it been so long you ask? The past few weeks I&#8217;ve been cranking out Nearby Tweets v2, and today it hit private beta stage. By the way feel free to <a href="http://nearbytweets.com/v2/">request private beta access to Nearby Tweets v2</a>.</p>
<p>So what&#8217;s next? Time to start providing valuable content to readers through my blog again, but with a little shift.</p>
<p><span id="more-1329"></span></p>
<p>Going forward my freelance services will be rebranded and focused on social experience design, which is basically helping businesses design and implement social strategies for the web. My blog&#8217;s content will receive a similar rebrand and focus on content that matches social experience design.</p>
<p>So that&#8217;s what&#8217;s new. Are you interesting in receiving content about designing and implementing social strategies for the web, such as online communities, social networks, and open APIs?</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/05/01/9-reasons-single-purpose-website-app/' rel='bookmark' title='Permanent Link: 9 compelling reasons to build a single-purpose website'>9 compelling reasons to build a single-purpose website</a></li>
<li><a href='http://briancray.com/2009/08/26/blog-design-information-overload-progressive-disclosure/' rel='bookmark' title='Permanent Link: Blog design best practice: Scrollbars not sidebars'>Blog design best practice: Scrollbars not sidebars</a></li>
<li><a href='http://briancray.com/2009/07/31/online-community-best-practices-reward-top-users/' rel='bookmark' title='Permanent Link: Online community best practices: Reward your top users'>Online community best practices: Reward your top users</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=zs2zeA4AjNQ:ZhtjXnaep7c:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=zs2zeA4AjNQ:ZhtjXnaep7c:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=zs2zeA4AjNQ:ZhtjXnaep7c:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=zs2zeA4AjNQ:ZhtjXnaep7c:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=zs2zeA4AjNQ:ZhtjXnaep7c:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/zs2zeA4AjNQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/10/28/focusing-brian-crays-blog-content/feed/</wfw:commentRss>
		<slash:comments>8</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/10/28/focusing-brian-crays-blog-content/</feedburner:origLink></item>
		<item>
		<title>Disappearing “Scroll to top” link with jQuery and CSS</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/C5gqpca6CSE/</link>
		<comments>http://briancray.com/2009/10/06/scroll-to-top-link-jquery-css/#comments</comments>
		<pubDate>Tue, 06 Oct 2009 14:30:59 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[css]]></category>
		<category><![CDATA[jquery]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1317</guid>
		<description><![CDATA[Seen in many forms, such as &#8220;Back to top,&#8221; &#8220;Top of page,&#8221; or &#8220;Scroll to top,&#8221; these links provide a way for users to jump to the top of the page, back to navigation and other handy stuff.
This tutorial will help you build a scroll to top link, or whatever you call it, that appears [...]]]></description>
			<content:encoded><![CDATA[<p>Seen in many forms, such as &#8220;Back to top,&#8221; &#8220;Top of page,&#8221; or &#8220;Scroll to top,&#8221; these links provide a way for users to jump to the top of the page, back to navigation and other handy stuff.</p>
<p>This tutorial will help you build a scroll to top link, or whatever you call it, that <strong>appears when the user scrolls down</strong>, and <strong>disappears when users reach the top of the page</strong> using a combination of <abbr>CSS</abbr> and <a href="http://jquery.com/">jQuery</a> (a free javascript framework). You&#8217;ll need to <a href="http://docs.jquery.com/Downloading_jQuery#Current_Release">download jQuery</a> if you aren&#8217;t using it already.</p>
<p><span id="more-1317"></span></p>
<p class="demolink"><a href="http://briancray.com/tests/topofpage/index.html">Demo</a></p>
<p>You can either <em>view the demo source</em> if you&#8217;re an advanced developer, or read on and I&#8217;ll go through the <abbr>CSS</abbr>, jQuery, and <abbr>HTML</abbr> code separately below.</p>
<h3>The HTML (inside the &lt;body&gt;)</h3>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">body</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;top&quot;</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #808080; font-style: italic;">&lt;!-- put all of your normal &lt;body&gt; stuff here --&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">div</span> <span style="color: #000066;">id</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;message&quot;</span>&gt;&lt;<span style="color: #000000; font-weight: bold;">a</span> <span style="color: #000066;">href</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;top&quot;</span>&gt;</span>Scroll to top<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">a</span>&gt;&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">div</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">body</span>&gt;</span></pre></div></div>

<h3>The CSS</h3>

<div class="wp_syntax"><div class="code"><pre class="css" style="font-family:monospace;"><span style="color: #cc00cc;">#message</span> a
<span style="color: #00AA00;">&#123;</span>
	<span style="color: #808080; font-style: italic;">/* display: block before hiding */</span>
	<span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">block</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">display</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">none</span><span style="color: #00AA00;">;</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* link is above all other elements */</span>
	<span style="color: #000000; font-weight: bold;">z-index</span><span style="color: #00AA00;">:</span> <span style="color: #cc66cc;">999</span><span style="color: #00AA00;">;</span> 
&nbsp;
	<span style="color: #808080; font-style: italic;">/* link doesn't hide text behind it */</span>
	opacity<span style="color: #00AA00;">:</span> .8<span style="color: #00AA00;">;</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* link stays at same place on page */</span>
	<span style="color: #000000; font-weight: bold;">position</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">fixed</span><span style="color: #00AA00;">;</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* link goes at the bottom of the page */</span>
	<span style="color: #000000; font-weight: bold;">top</span><span style="color: #00AA00;">:</span> <span style="color: #933;"><span style="color: #cc66cc;">100</span>%</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">margin-top</span><span style="color: #00AA00;">:</span> <span style="color: #933;">-80px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* = height + preferred bottom margin */</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* link is centered */</span>
	<span style="color: #000000; font-weight: bold;">left</span><span style="color: #00AA00;">:</span> <span style="color: #933;"><span style="color: #cc66cc;">50</span>%</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">margin-left</span><span style="color: #00AA00;">:</span> <span style="color: #933;">-160px</span><span style="color: #00AA00;">;</span> <span style="color: #808080; font-style: italic;">/* = half of width */</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* round the corners (to your preference) */</span>
	-moz-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">24px</span><span style="color: #00AA00;">;</span>
	-webkit-border-radius<span style="color: #00AA00;">:</span> <span style="color: #933;">24px</span><span style="color: #00AA00;">;</span>
&nbsp;
	<span style="color: #808080; font-style: italic;">/* make it big and easy to see (size, style to preferences) */</span>
	<span style="color: #000000; font-weight: bold;">width</span><span style="color: #00AA00;">:</span> <span style="color: #933;">300px</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">line-height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">48px</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">height</span><span style="color: #00AA00;">:</span> <span style="color: #933;">48px</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">padding</span><span style="color: #00AA00;">:</span> <span style="color: #933;">10px</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">background-color</span><span style="color: #00AA00;">:</span> <span style="color: #cc00cc;">#000</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">font-size</span><span style="color: #00AA00;">:</span> <span style="color: #933;">24px</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">text-align</span><span style="color: #00AA00;">:</span> <span style="color: #993333;">center</span><span style="color: #00AA00;">;</span>
	<span style="color: #000000; font-weight: bold;">color</span><span style="color: #00AA00;">:</span> <span style="color: #cc00cc;">#fff</span><span style="color: #00AA00;">;</span>
<span style="color: #00AA00;">&#125;</span></pre></div></div>

<h3>The jQuery</h3>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;">$<span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #006600; font-style: italic;">// run this code on page load (AKA DOM load)</span>
&nbsp;
	<span style="color: #009966; font-style: italic;">/* set variables locally for increased performance */</span>
	<span style="color: #003366; font-weight: bold;">var</span> scroll_timer<span style="color: #339933;">;</span>
	<span style="color: #003366; font-weight: bold;">var</span> displayed <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #339933;">;</span>
	<span style="color: #003366; font-weight: bold;">var</span> $message <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'#message a'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #003366; font-weight: bold;">var</span> $window <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span>window<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #003366; font-weight: bold;">var</span> top <span style="color: #339933;">=</span> $<span style="color: #009900;">&#40;</span>document.<span style="color: #660066;">body</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">children</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">position</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">top</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #009966; font-style: italic;">/* react to scroll event on window */</span>
	$window.<span style="color: #000066;">scroll</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
		window.<span style="color: #660066;">clearTimeout</span><span style="color: #009900;">&#40;</span>scroll_timer<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
		scroll_timer <span style="color: #339933;">=</span> window.<span style="color: #660066;">setTimeout</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> <span style="color: #006600; font-style: italic;">// use a timer for performance</span>
			<span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>$window.<span style="color: #660066;">scrollTop</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&lt;=</span> top<span style="color: #009900;">&#41;</span> <span style="color: #006600; font-style: italic;">// hide if at the top of the page</span>
			<span style="color: #009900;">&#123;</span>
				displayed <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #339933;">;</span>
				$message.<span style="color: #660066;">fadeOut</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">500</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span>
			<span style="color: #000066; font-weight: bold;">else</span> <span style="color: #000066; font-weight: bold;">if</span><span style="color: #009900;">&#40;</span>displayed <span style="color: #339933;">==</span> <span style="color: #003366; font-weight: bold;">false</span><span style="color: #009900;">&#41;</span> <span style="color: #006600; font-style: italic;">// show if scrolling down</span>
			<span style="color: #009900;">&#123;</span>
				displayed <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">true</span><span style="color: #339933;">;</span>
				$message.<span style="color: #000066;">stop</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">true</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">true</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">show</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span>.<span style="color: #660066;">click</span><span style="color: #009900;">&#40;</span><span style="color: #003366; font-weight: bold;">function</span> <span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span> $message.<span style="color: #660066;">fadeOut</span><span style="color: #009900;">&#40;</span><span style="color: #CC0000;">500</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
			<span style="color: #009900;">&#125;</span>
		<span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">100</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<h3>Full source</h3>
<p><strong>To view the full source code</strong> together in one file, go to the <a href="http://briancray.com/tests/topofpage/index.html">demo</a> and view the source code there.</p>
<h3>Conclusion</h3>
<p>You&#8217;re all done! Combine the <abbr>HTML</abbr>, <abbr>CSS</abbr>, and jQuery code together into one file, or separate them out into your existing external stylesheet and javascript files. Don&#8217;t forget to put your <abbr>CSS</abbr> inside the &lt;head&gt; element and your javascript (jQuery) right before the &lt;/body&gt; tag, always.</p>
<p class="demolink"><a href="http://briancray.com/tests/topofpage/index.html">See the end result</a></p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/06/09/jquery-plugin-linknotify-inline-link-click-notification/' rel='bookmark' title='Permanent Link: New jQuery plugin: linkNotify() &#8211; An inline link click notification'>New jQuery plugin: linkNotify() &#8211; An inline link click notification</a></li>
<li><a href='http://briancray.com/2009/05/06/twitter-style-alert-jquery-cs-php/' rel='bookmark' title='Permanent Link: How to create a Twitter-style alert with jQuery, CSS, and PHP'>How to create a Twitter-style alert with jQuery, CSS, and PHP</a></li>
<li><a href='http://briancray.com/2009/07/28/increase-form-usability-replace-form-button-submit/' rel='bookmark' title='Permanent Link: Web form usability: Better form submission feedback with jQuery'>Web form usability: Better form submission feedback with jQuery</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=C5gqpca6CSE:gJLpYeswsps:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=C5gqpca6CSE:gJLpYeswsps:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=C5gqpca6CSE:gJLpYeswsps:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=C5gqpca6CSE:gJLpYeswsps:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=C5gqpca6CSE:gJLpYeswsps:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/C5gqpca6CSE" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/10/06/scroll-to-top-link-jquery-css/feed/</wfw:commentRss>
		<slash:comments>26</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/10/06/scroll-to-top-link-jquery-css/</feedburner:origLink></item>
		<item>
		<title>How to remove a specific value from a javascript array</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/qmcYm5Fd23c/</link>
		<comments>http://briancray.com/2009/09/30/remove-value-javascript-array/#comments</comments>
		<pubDate>Wed, 30 Sep 2009 20:16:03 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[javascript]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1311</guid>
		<description><![CDATA[I couldn&#8217;t find a short and sweet answer to this one, so I made an answer and I&#8217;m sharing it here if you need it. Enjoy!


// from this
var arr = &#91;'remove', 'specific', 'value', 'from', 'javascript', 'array'&#93;; // 6 items
&#160;
// to this (&#34;specific&#34; value removed)
var arr = &#91;'remove', 'value', 'from', 'javascript', 'array'&#93;; //  5 items
&#160;
// [...]]]></description>
			<content:encoded><![CDATA[<p>I couldn&#8217;t find a short and sweet answer to this one, so I made an answer and I&#8217;m sharing it here if you need it. Enjoy!</p>
<p><span id="more-1311"></span></p>

<div class="wp_syntax"><div class="code"><pre class="javascript" style="font-family:monospace;"><span style="color: #006600; font-style: italic;">// from this</span>
<span style="color: #003366; font-weight: bold;">var</span> arr <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'remove'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'specific'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'value'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'from'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'javascript'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'array'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">// 6 items</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// to this (&quot;specific&quot; value removed)</span>
<span style="color: #003366; font-weight: bold;">var</span> arr <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'remove'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'value'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'from'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'javascript'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'array'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span> <span style="color: #006600; font-style: italic;">//  5 items</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// use this (removes &quot;specific&quot;)</span>
arr.<span style="color: #660066;">splice</span><span style="color: #009900;">&#40;</span>arr.<span style="color: #660066;">indexOf</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">'specific'</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
&nbsp;
<span style="color: #006600; font-style: italic;">// full example</span>
<span style="color: #003366; font-weight: bold;">var</span> arr <span style="color: #339933;">=</span> <span style="color: #009900;">&#91;</span><span style="color: #3366CC;">'remove'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'specific'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'value'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'from'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'javascript'</span><span style="color: #339933;">,</span> <span style="color: #3366CC;">'array'</span><span style="color: #009900;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #003366; font-weight: bold;">var</span> value_to_remove <span style="color: #339933;">=</span> <span style="color: #3366CC;">'specific'</span><span style="color: #339933;">;</span>
arr.<span style="color: #660066;">splice</span><span style="color: #009900;">&#40;</span>arr.<span style="color: #660066;">indexOf</span><span style="color: #009900;">&#40;</span>value_to_remove<span style="color: #009900;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #CC0000;">1</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
&nbsp;
<span style="color: #006600; font-style: italic;">// note: to support IE (anger rising as I type), you'll need this (thanks James!):</span>
<span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">!</span>Array.<span style="color: #660066;">prototype</span>.<span style="color: #660066;">indexOf</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
  Array.<span style="color: #660066;">prototype</span>.<span style="color: #660066;">indexOf</span> <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>elt <span style="color: #009966; font-style: italic;">/*, from*/</span><span style="color: #009900;">&#41;</span>
  <span style="color: #009900;">&#123;</span>
    <span style="color: #003366; font-weight: bold;">var</span> len <span style="color: #339933;">=</span> <span style="color: #000066; font-weight: bold;">this</span>.<span style="color: #660066;">length</span> <span style="color: #339933;">&gt;&gt;&gt;</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #003366; font-weight: bold;">var</span> from <span style="color: #339933;">=</span> Number<span style="color: #009900;">&#40;</span>arguments<span style="color: #009900;">&#91;</span><span style="color: #CC0000;">1</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">||</span> <span style="color: #CC0000;">0</span><span style="color: #339933;">;</span>
    from <span style="color: #339933;">=</span> <span style="color: #009900;">&#40;</span>from <span style="color: #339933;">&lt;</span> <span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span>
         <span style="color: #339933;">?</span> Math.<span style="color: #660066;">ceil</span><span style="color: #009900;">&#40;</span>from<span style="color: #009900;">&#41;</span>
         <span style="color: #339933;">:</span> Math.<span style="color: #660066;">floor</span><span style="color: #009900;">&#40;</span>from<span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
    <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>from <span style="color: #339933;">&lt;</span> <span style="color: #CC0000;">0</span><span style="color: #009900;">&#41;</span>
      from <span style="color: #339933;">+=</span> len<span style="color: #339933;">;</span>
&nbsp;
    <span style="color: #000066; font-weight: bold;">for</span> <span style="color: #009900;">&#40;</span><span style="color: #339933;">;</span> from <span style="color: #339933;">&lt;</span> len<span style="color: #339933;">;</span> from<span style="color: #339933;">++</span><span style="color: #009900;">&#41;</span>
    <span style="color: #009900;">&#123;</span>
      <span style="color: #000066; font-weight: bold;">if</span> <span style="color: #009900;">&#40;</span>from <span style="color: #000066; font-weight: bold;">in</span> <span style="color: #000066; font-weight: bold;">this</span> <span style="color: #339933;">&amp;&amp;</span>
          <span style="color: #000066; font-weight: bold;">this</span><span style="color: #009900;">&#91;</span>from<span style="color: #009900;">&#93;</span> <span style="color: #339933;">===</span> elt<span style="color: #009900;">&#41;</span>
        <span style="color: #000066; font-weight: bold;">return</span> from<span style="color: #339933;">;</span>
    <span style="color: #009900;">&#125;</span>
    <span style="color: #000066; font-weight: bold;">return</span> <span style="color: #339933;">-</span><span style="color: #CC0000;">1</span><span style="color: #339933;">;</span>
  <span style="color: #009900;">&#125;</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>



<p>Related posts:<ol><li><a href='http://briancray.com/2009/12/07/javascript-find-value-string-key-multidimensional-array-object/' rel='bookmark' title='Permanent Link: Javascript snippet: Find the value of a string key in a multidimensional array or object'>Javascript snippet: Find the value of a string key in a multidimensional array or object</a></li>
<li><a href='http://briancray.com/2009/04/25/remove-null-values-php-arrays/' rel='bookmark' title='Permanent Link: Remove NULL values from PHP arrays with 1 line'>Remove NULL values from PHP arrays with 1 line</a></li>
<li><a href='http://briancray.com/2009/12/28/simple-image-randomizer-jquery/' rel='bookmark' title='Permanent Link: Impossibly simple image randomizer with jQuery'>Impossibly simple image randomizer with jQuery</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qmcYm5Fd23c:OYIPTgeHAU4:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qmcYm5Fd23c:OYIPTgeHAU4:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qmcYm5Fd23c:OYIPTgeHAU4:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qmcYm5Fd23c:OYIPTgeHAU4:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qmcYm5Fd23c:OYIPTgeHAU4:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/qmcYm5Fd23c" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/30/remove-value-javascript-array/feed/</wfw:commentRss>
		<slash:comments>14</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/30/remove-value-javascript-array/</feedburner:origLink></item>
		<item>
		<title>Needs assessment: the most important process in web design</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/iOat4JJvYQQ/</link>
		<comments>http://briancray.com/2009/09/22/needs-assessment-web-design/#comments</comments>
		<pubDate>Tue, 22 Sep 2009 17:18:17 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[freelancing]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1306</guid>
		<description><![CDATA[Every client who comes to you for a website knows why they want a website, even if they can&#8217;t clearly articulate that &#8220;why.&#8221; But understanding that why is the most important part of a website design. Why?

Strategic design decisions
You&#8217;ll be in trouble from the very beginning as you sit down in front of your monitor [...]]]></description>
			<content:encoded><![CDATA[<p>Every client who comes to you for a website knows why they want a website, even if they can&#8217;t clearly articulate that &#8220;why.&#8221; But understanding that why is the most important part of a website design. Why?</p>
<p><span id="more-1306"></span></p>
<h3>Strategic design decisions</h3>
<p>You&#8217;ll be in trouble from the very beginning as you sit down in front of your monitor and ask yourself &#8220;What should this design look like?&#8221; You won&#8217;t have an answer, because you know that designs drive behavior, and you don&#8217;t know what behavior to design for.</p>
<p>Knowing what your clients want from their websites makes strategic design decisions simple to answer, because the following question need only be answered: &#8220;How can I design this part so that users do more of what my client wants?&#8221;</p>
<h3>Measurement</h3>
<p>When it comes time to propose additions, changes, or complete redesigns, how will you justify your proposal? A simple &#8220;You need a fresh look&#8221; barely gets by anymore. Websites aren&#8217;t novelty.</p>
<p>Knowing what your clients want out of their websites gives you something to measure, and more importantly, gives you something to justify continued work. For example, if you know a client wants leads generated from their website, you can measure how many leads are currently being generated, and offer design optimizations or an A/B test to increase lead generation rates. While your client may not want to pay for a redesign, <em>they do</em> want more leads and they&#8217;re willing to pay for them.</p>
<h3>Client satisfaction</h3>
<p>Anytime I hear a client talking about a bad past experience, it feels like their previous consultant designed a brochure website and left them dry. When I hear happy businesses talking about their web consultants, they always focus on how &#8220;my website has improved my business.&#8221; How can you show that you&#8217;re improving your clients business if the website doesn&#8217;t have a <em>purpose</em>?</p>
<p>Clients become happy clients when you prove to them that you have improved their business. It all begins with knowing what clients want out of their websites, designing for it, measuring it, and proving that you&#8217;ve given them more of what they wanted.</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/09/16/clients-pay-more-web-services/' rel='bookmark' title='Permanent Link: Getting your clients to pay more for web services'>Getting your clients to pay more for web services</a></li>
<li><a href='http://briancray.com/2009/12/02/value-of-wireframing-website-design/' rel='bookmark' title='Permanent Link: How wireframing makes your website designs better'>How wireframing makes your website designs better</a></li>
<li><a href='http://briancray.com/2009/05/01/9-reasons-single-purpose-website-app/' rel='bookmark' title='Permanent Link: 9 compelling reasons to build a single-purpose website'>9 compelling reasons to build a single-purpose website</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iOat4JJvYQQ:O9YSaFAe20M:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iOat4JJvYQQ:O9YSaFAe20M:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iOat4JJvYQQ:O9YSaFAe20M:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=iOat4JJvYQQ:O9YSaFAe20M:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=iOat4JJvYQQ:O9YSaFAe20M:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/iOat4JJvYQQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/22/needs-assessment-web-design/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/22/needs-assessment-web-design/</feedburner:origLink></item>
		<item>
		<title>Smart web form validation with PHP</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/Z1WdqlRxIPA/</link>
		<comments>http://briancray.com/2009/09/18/web-form-validation-php/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 15:16:13 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Web development]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1288</guid>
		<description><![CDATA[Since I&#8217;ve been working on my CMS the past few days I&#8217;ve been on a little PHP trip. I&#8217;ll probably be writing a few PHP posts over the next week or so, intermingled with other topics of course.
This tutorial should help you build smarter web forms with PHP and save you a ton of time.

Let&#8217;s [...]]]></description>
			<content:encoded><![CDATA[<p>Since I&#8217;ve been working on my <abbr>CMS</abbr> the past few days I&#8217;ve been on a little <abbr>PHP</abbr> trip. I&#8217;ll probably be writing a few <abbr>PHP</abbr> posts over the next week or so, intermingled with other topics of course.</p>
<p>This tutorial should help you build smarter web forms with <abbr>PHP</abbr> <em>and</em> save you a <strong>ton</strong> of time.</php>
<p><span id="more-1288"></span></p>
<p>Let&#8217;s start with web form sanitization.</p>
<h3>Sanitize all user input through a standard PHP function</h3>
<p>User input sometimes has unnecessary whitespace, so we&#8217;ll <a href="http://us2.php.net/trim">trim</a> that off. We&#8217;ll also check if <a href="http://us.php.net/manual/en/security.magicquotes.what.php">magic_quotes_gpc</a> is automatically adding backslashes to user input and remove as necessary.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000088;">$hasgpc</span> <span style="color: #339933;">=</span> <span style="color: #990000;">get_magic_quotes_gpc</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">foreach</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$field</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #000088;">$value</span> <span style="color: #339933;">=</span> <span style="color: #990000;">trim</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$hasgpc</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$value</span> <span style="color: #339933;">=</span> <span style="color: #990000;">stripslashes</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000088;">$filtered_post</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$field</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$value</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span></pre></div></div>

<h3>Add user input verification</h3>
<p>To verify user input, we&#8217;ll first add meta information about each web form input field to its <em>name</em> property.</p>
<h4>Adding field properties to each field on the web form display side</h4>
<p>Notice the use of the underline to separate a field&#8217;s properties in the name.</p>

<div class="wp_syntax"><div class="code"><pre class="html4strict" style="font-family:monospace;"><span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">form</span> <span style="color: #000066;">method</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;post&quot;</span> <span style="color: #000066;">action</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;myscript.php&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;username_required_alphanumeric&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #000000; font-weight: bold;">input</span> <span style="color: #000066;">type</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;text&quot;</span> <span style="color: #000066;">name</span><span style="color: #66cc66;">=</span><span style="color: #ff0000;">&quot;email_required_emailaddress&quot;</span>&gt;</span>
<span style="color: #009900;">&lt;<span style="color: #66cc66;">/</span><span style="color: #000000; font-weight: bold;">form</span>&gt;</span></pre></div></div>

<h4>Verifying form input using on the web form submission side</h4>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000088;">$hasgpc</span> <span style="color: #339933;">=</span> <span style="color: #990000;">get_magic_quotes_gpc</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">foreach</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$_POST</span> <span style="color: #b1b100;">as</span> <span style="color: #000088;">$field</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #666666; font-style: italic;">/* first we extract the actual intended field name */</span>
&nbsp;
	<span style="color: #000088;">$fieldinfo</span> <span style="color: #339933;">=</span> <span style="color: #990000;">explode</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'_'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$field</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// turn the posted field name into an array of properties</span>
	<span style="color: #000088;">$field</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array_shift</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$fieldinfo</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// take the first element as the intended field name</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">/* do the standard stuff we discussed above */</span>
&nbsp;
	<span style="color: #000088;">$value</span> <span style="color: #339933;">=</span> <span style="color: #990000;">trim</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$hasgpc</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$value</span> <span style="color: #339933;">=</span> <span style="color: #990000;">stripslashes</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #000088;">$filtered_post</span><span style="color: #009900;">&#91;</span><span style="color: #000088;">$field</span><span style="color: #009900;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$value</span><span style="color: #339933;">;</span>
&nbsp;
	<span style="color: #666666; font-style: italic;">/* new stuff to verify user input based on $fieldinfo */</span>
&nbsp;
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">array_search</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'required'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$fieldinfo</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #990000;">empty</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">TRUE</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">array_search</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'emailaddress'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$fieldinfo</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #339933;">!</span><span style="color: #990000;">preg_match</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'|^[a-z0-9._%+-]+@[a-z0-9.-]+\.[a-z]{2,4}$|i'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">TRUE</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
	<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #990000;">array_search</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'alphanumeric'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$fieldinfo</span><span style="color: #009900;">&#41;</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #990000;">preg_match</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'|[^a-z0-9]|i'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$value</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#41;</span>
	<span style="color: #009900;">&#123;</span>
		<span style="color: #000088;">$error</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">TRUE</span><span style="color: #339933;">;</span>
	<span style="color: #009900;">&#125;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">/* if there were errors in the web form, send the user back to make changes */</span>
<span style="color: #b1b100;">if</span><span style="color: #009900;">&#40;</span><span style="color: #000088;">$error</span><span style="color: #009900;">&#41;</span>
<span style="color: #009900;">&#123;</span>
	<span style="color: #990000;">header</span><span style="color: #009900;">&#40;</span><span style="color: #0000ff;">'Location: '</span> <span style="color: #339933;">.</span> <span style="color: #000088;">$_SERVER</span><span style="color: #009900;">&#91;</span><span style="color: #0000ff;">'HTTP_REFERER'</span><span style="color: #009900;">&#93;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
	<span style="color: #990000;">exit</span><span style="color: #339933;">;</span>
<span style="color: #009900;">&#125;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">/*
at this point the form has been cleaned and validated.
reference the fields with $filtered_post, such as $filtered_post['username']
*/</span></pre></div></div>

<h3>Things to consider about this method</h3>
<ul>
<li>This tutorial is supposed to emphasize web form sanitization and validation with <abbr>PHP</abbr>. <strong>You can greatly improve the user feedback on errors versus what I&#8217;ve used above</strong>. In fact I compell you to for the user&#8217;s sake. One way to do this is to pass the errors back in the session and display them above the web form. I&#8217;d also recommend sending back the submitted values so the user doesn&#8217;t have to retype them.</li>
<li>While this method kicks ass, it has its limitations. The one I thought of is that a field cannot be named the same thing as a filter. For example, <code>&lt;input type="text" name="emailaddress_required_emailaddress"&gt;</code> wouldn&#8217;t work.</li>
<li>Starting with <abbr>PHP 5.2.0</abbr> you can use <a href="http://us2.php.net/manual/en/function.filter-var.php">filter_var()</a> to validate fields instead of <a href="http://us3.php.net/manual/en/function.preg-match.php">regular expressions</a> as used above.</li>
<li>A few people have pointed out that this is not the most secure method of form validation because someone can hack the form field names. Keep that in mind if you decide to use this method of form validation.</li>
</ul>
<p>If you have any questions or comments, feel free to leave them below!</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/07/28/increase-form-usability-replace-form-button-submit/' rel='bookmark' title='Permanent Link: Web form usability: Better form submission feedback with jQuery'>Web form usability: Better form submission feedback with jQuery</a></li>
<li><a href='http://briancray.com/2009/11/13/signup-process-online-community-best-practices/' rel='bookmark' title='Permanent Link: Online community best practices: Effective signup process'>Online community best practices: Effective signup process</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=Z1WdqlRxIPA:fyix145PAtM:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=Z1WdqlRxIPA:fyix145PAtM:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=Z1WdqlRxIPA:fyix145PAtM:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=Z1WdqlRxIPA:fyix145PAtM:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=Z1WdqlRxIPA:fyix145PAtM:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/Z1WdqlRxIPA" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/18/web-form-validation-php/feed/</wfw:commentRss>
		<slash:comments>17</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/18/web-form-validation-php/</feedburner:origLink></item>
		<item>
		<title>Getting your clients to pay more for web services</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/FiUBFOKlsDM/</link>
		<comments>http://briancray.com/2009/09/16/clients-pay-more-web-services/#comments</comments>
		<pubDate>Wed, 16 Sep 2009 14:31:36 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[freelancing]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1283</guid>
		<description><![CDATA[There&#8217;s a problem when your new client tells you &#8220;I want a website.&#8221; This might be music to your ears because it means money in your bank, but it represents an undercurrent that&#8217;s sweeping away the web&#8217;s potential, and your potential earnings.
Reading into the phrase &#8220;I want a website,&#8221; I hear &#8220;I want a website [...]]]></description>
			<content:encoded><![CDATA[<p>There&#8217;s a problem when your new client tells you &#8220;I want a website.&#8221; This might be music to your ears because it means money in your bank, but it represents an undercurrent that&#8217;s sweeping away the web&#8217;s potential, and your potential earnings.</p>
<p>Reading into the phrase &#8220;I want a website,&#8221; <em>I</em> hear &#8220;I want a website and I don&#8217;t really know why.&#8221; Since your client doesn&#8217;t know why, they will pay for a website designed by the lowest bidder because all bidders make websites.</p>
<p><span id="more-1283"></span></p>
<p>But not all bidders solve problems.</p>
<p>Professional and experienced web professionals don’t build websites. They <em>solve business problems</em> using the web. If your client says &#8220;I want to build a better relationship with my customers&#8221; they will pay for the person who can best solve their problem, which probably won&#8217;t be the lowest bidder.</p>
<p>It&#8217;s the web professional&#8217;s job to educate the &#8220;I want a website&#8221; crowd on the benefits of having a website before providing an estimate. Through initial discussion identify their business problems and then outline how you plan to solve them. Make sure your clients know all that you&#8217;re <em>actually</em> doing for them. I bet cost will become less of an issue.</p>
<p>If you&#8217;re the web professional who at this point is saying &#8220;That might be true for bigger clients, but I deal with many small businesses that are always thinking about cost,&#8221; let&#8217;s build problem/solution scenarios for a good ol&#8217; fashioned mom and pop shop.</p>
<p>A website:</p>
<ul>
<li>Generates new leads = increased profit</li>
<li>Cross- and upsells current customers = increased profit</li>
<li>Answers frequently asked questions for customers = decreased cost (someone has to be available to answer customer questions otherwise)</li>
<li>Raises perceived brand value = increased profit</li>
</ul>
<p>You see, once you build that website they&#8217;ll begin sending <em>everyone</em> to their website. <strong>It&#8217;s now their primary marketing &#038; sales channel.</strong> Over time much of their new business will be driven from their website. Are you clients not willing to pay more for <em>that</em>?</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/09/22/needs-assessment-web-design/' rel='bookmark' title='Permanent Link: Needs assessment: the most important process in web design'>Needs assessment: the most important process in web design</a></li>
<li><a href='http://briancray.com/2009/12/02/value-of-wireframing-website-design/' rel='bookmark' title='Permanent Link: How wireframing makes your website designs better'>How wireframing makes your website designs better</a></li>
<li><a href='http://briancray.com/2009/06/18/why-web-based-products-successful/' rel='bookmark' title='Permanent Link: Why some web apps are successful and others aren&#8217;t'>Why some web apps are successful and others aren&#8217;t</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=FiUBFOKlsDM:1F29j9Lb8Aw:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=FiUBFOKlsDM:1F29j9Lb8Aw:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=FiUBFOKlsDM:1F29j9Lb8Aw:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=FiUBFOKlsDM:1F29j9Lb8Aw:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=FiUBFOKlsDM:1F29j9Lb8Aw:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/FiUBFOKlsDM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/16/clients-pay-more-web-services/feed/</wfw:commentRss>
		<slash:comments>12</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/16/clients-pay-more-web-services/</feedburner:origLink></item>
		<item>
		<title>Fire the “web designer”</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/qQnG_jbOGlI/</link>
		<comments>http://briancray.com/2009/09/09/fire-the-web-designer/#comments</comments>
		<pubDate>Wed, 09 Sep 2009 17:48:37 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[User experience]]></category>
		<category><![CDATA[freelancing]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1255</guid>
		<description><![CDATA[You&#8217;ve hired the wrong guy. After reading David Airey&#8217;s ]]></description>
			<content:encoded><![CDATA[<p>You&#8217;ve hired the wrong guy. After reading David Airey&#8217;s <a href=http://www.davidairey.com/forget-about-design/">forget about design</a> and Andrew Maier&#8217;s <a href="http://www.uxbooth.com/blog/user-experience-designer-vs-creative-director/">User Experience Designer vs. Creative Director</a> I&#8217;ve come to the conclusion that the role &#8220;web designer&#8221; is a cheap ass effort to fudge a graphic designer into a role requiring two entirely separate fields of knowledge.</p>
<p>Web teams still need graphic designers to communicate visually appealing messages. And graphic designers moving from a print team to a web team <em>should stay graphic designers</em>. What&#8217;s needed to compliment a web team&#8217;s graphic designer is someone to account for the complexities of <a href="http://en.wikipedia.org/wiki/Human–computer_interaction">human-computer interaction (<abbr>HCI</abbr>)</a>. Surely a manager in any field can&#8217;t expect staff to adopt a completely opposite, complex knowledge base overnight.</p>
<p><span id="more-1255"></span></p>
<p>Welcome the missing link: <em>User experience designer</em>.</p>
<p><a href="http://en.wikipedia.org/wiki/User_experience_design">User experience design</a> is a blend of <a href="http://en.wikipedia.org/wiki/Usability">usability</a>, <a href="http://en.wikipedia.org/wiki/Information_architecture">information architecture (<abbr>IA</abbr>)</a>, and <a href="http://en.wikipedia.org/wiki/User_interface_design">user interface (<abbr>UI</abbr>) design.</a></p>
<p>A web-based user experience designer is charged with learning about users and creating interfaces that match website goals and user needs. They deliver interaction specs and simple mockups to the graphic designer as a framework for user-centered visual communication. Then, of course, the web developer makes the interaction work.</p>
<p>Don&#8217;t mix up the two roles, user experience designer and graphic designer. Neither should do the others&#8217; job. They should never be blurred into &#8220;web designer.&#8221;</p>
<p>If you&#8217;re going to make the leap into a more complex communication channel, account for its complexities or it&#8217;ll bite you in the ass when your competitors &#8220;get it.&#8221;</p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/04/28/10-signs-professional-web-design/' rel='bookmark' title='Permanent Link: 10 signs of professional web design (Or why you should drop your amateur web designer)'>10 signs of professional web design (Or why you should drop your amateur web designer)</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qQnG_jbOGlI:6RbAeH2rB6w:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qQnG_jbOGlI:6RbAeH2rB6w:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qQnG_jbOGlI:6RbAeH2rB6w:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=qQnG_jbOGlI:6RbAeH2rB6w:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=qQnG_jbOGlI:6RbAeH2rB6w:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/qQnG_jbOGlI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/09/fire-the-web-designer/feed/</wfw:commentRss>
		<slash:comments>48</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/09/fire-the-web-designer/</feedburner:origLink></item>
		<item>
		<title>How to track inbound links from your social media profiles (Twitter, Facebook, etc)</title>
		<link>http://feedproxy.google.com/~r/briancray/blog/~3/3UQ1YimEMmQ/</link>
		<comments>http://briancray.com/2009/09/08/track-inbound-link-referrals-social-media-profiles-twitter-facebook/#comments</comments>
		<pubDate>Tue, 08 Sep 2009 13:14:18 +0000</pubDate>
		<dc:creator>Brian Cray</dc:creator>
				<category><![CDATA[Internet marketing]]></category>
		<category><![CDATA[conversion optimization]]></category>
		<category><![CDATA[inbound marketing]]></category>
		<category><![CDATA[Social Media]]></category>
		<category><![CDATA[web analytics]]></category>

		<guid isPermaLink="false">http://briancray.com/?p=1228</guid>
		<description><![CDATA[You can track referrals from Facebook or Twitter in Google Analytics, but what if you want to track specific links within your social media profiles to measure different variations or placements within your profiles?
For example what if I want to track how many people open briancray.com by clicking on my Twitter profile link? That&#8217;s what [...]]]></description>
			<content:encoded><![CDATA[<p>You can track referrals from Facebook or Twitter in <a href="http://www.google.com/analytics/">Google Analytics</a>, but what if you want to track specific links within your social media profiles to measure different variations or placements within your profiles?</p>
<p><strong>For example</strong> what if I want to track how many people open briancray.com by clicking on my <a href="http://twitter.com/">Twitter</a> profile link? That&#8217;s what this tutorial is about and it can be applied to any social media profile, whether it&#8217;s <a href="http://www.facebook.com/briancray">Facebook</a>, <a href="http://www.linkedin.com/in/briancray">LinkedIn</a>, or <a href="http://knowem.com/">the myriad of others</a>.</p>
<p><span id="more-1228"></span></p>
<h3>Step 1: Create trackable link</h3>
<p>Visit <a href="http://www.google.com/support/analytics/bin/answer.py?hl=en&#038;answer=55578">Google&#8217;s <abbr>URL</abbr> Builder</a> to build a <abbr>URL</abbr> that can be separately tracked in Google Analytics. Fill in the spaces as pictured below (changed to reflect your site and social media profile of choice, of course).</p>
<p><img src="http://briancray.com/wp-content/uploads/2009/09/step1.png" alt="Setting up Google URL Builder Tool to track social media profile referrals"></p>
<h3>Step 2: Shorten trackable link</h3>
<p>Google&#8217;s <abbr>URL</abbr> Builder makes a long <abbr>URL</abbr> even longer. To make it appear less daunting let&#8217;s shorten it. In the picture below I used <a href="http://bit.ly/">bit.ly</a>, which seems like the best choice.</p>
<p><img src="http://briancray.com/wp-content/uploads/2009/09/step2.png" alt="Shortening your tracking URL"></p>
<h3>Step 3: Add shortened trackable link to social media profile</h3>
<p>You&#8217;ve got your trackable link and it&#8217;s been shortened. All you have to do now is add it to your various social media profiles!</p>
<h3>Step 4 (completed next day): Track your URL in Google Analytics</h3>
<p>Because we used Google&#8217;s URL Builder, everytime someone clicks on that link Google will automatically track it in Google Analytics. Just go to <strong>Traffic Sources &raquo; Campaigns</strong> in Google Analytics and there you&#8217;ll find your referrals (Or you won&#8217;t if noone actually clicks the link).</p>
<p>Depending on your traffic, give Google Analytics about a day to begin reporting the referrals. They won&#8217;t show up immediately.</p>
<p><img src="http://briancray.com/wp-content/uploads/2009/09/Screen-shot-2009-09-08-at-8.57.53-AM.png" alt="Campaign tracked link in Google Analytics"></p>


<p>Related posts:<ol><li><a href='http://briancray.com/2009/08/07/track-subscriber-inbound-traffic-google-analytics-wordpress/' rel='bookmark' title='Permanent Link: Wordpress plugin: Track subscriber inbound traffic in Google Analytics'>Wordpress plugin: Track subscriber inbound traffic in Google Analytics</a></li>
<li><a href='http://briancray.com/2009/03/09/interview-social-media-phd-scholar-vivek-kumar-shares-views-on-social-media/' rel='bookmark' title='Permanent Link: Interview: Social Media PhD Scholar Vivek Kumar Shares Views On Social Media'>Interview: Social Media PhD Scholar Vivek Kumar Shares Views On Social Media</a></li>
<li><a href='http://briancray.com/2009/03/14/google-analytics-hack-track-outbound-links/' rel='bookmark' title='Permanent Link: Google Analytics Hack: Track Outbound Links In 2 Easy Steps'>Google Analytics Hack: Track Outbound Links In 2 Easy Steps</a></li>
</ol></p><div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=3UQ1YimEMmQ:OBA-9xS2i2w:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=3UQ1YimEMmQ:OBA-9xS2i2w:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/briancray/blog?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=3UQ1YimEMmQ:OBA-9xS2i2w:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/briancray/blog?a=3UQ1YimEMmQ:OBA-9xS2i2w:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/briancray/blog?i=3UQ1YimEMmQ:OBA-9xS2i2w:gIN9vFwOqvQ" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/briancray/blog/~4/3UQ1YimEMmQ" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://briancray.com/2009/09/08/track-inbound-link-referrals-social-media-profiles-twitter-facebook/feed/</wfw:commentRss>
		<slash:comments>28</slash:comments>
		<feedburner:origLink>http://briancray.com/2009/09/08/track-inbound-link-referrals-social-media-profiles-twitter-facebook/</feedburner:origLink></item>
	</channel>
</rss>
