Posts Tagged ‘tutorial’

How to Design a Dribbble-Style Homepage Layout

Advertise here with BSA


The popular design network Dribbble has grown substantially in just a few short years. Graphics designers and illustrators from all over the world have flocked onto the web seeking invites. But aside from the exclusivity their layout design has become a prominent factor of the entire branding.

I love the simplistic nature of their gallery-style photo boxes. It matches well with a community of designers excited to share their latest pixels with the world. In this tutorial I’ll go over techniques for constructing a similar design in HTML5 and CSS3. You can build a very similar page structure with just bare-bones essential CSS. Yet when we can utilize new browser-supported properties like box shadows the process becomes much more captivating.

Dribbble home page design layout

Live DemoDownload Source Code

Starting in HTML

To begin let’s build the default HTML template so we have a starting point to work with. The basic HTML5 construct requires a simple doctype declaration. In the code below I’m also including some meta tags along with an external CSS stylesheet.

<!doctype html>
<html lang="en">
<head>
  <meta charset="utf-8">
  <title>Dribbble-Styled Homepage Demo - SpyreStudios</title>
  <meta name="author" content="SpyreStudios">
  <link rel="stylesheet" type="text/css" href="style.css">
</head>

If you notice we don’t need to close the link or meta tags anymore. The syntax <link rel="stylesheet" /> is still valid with a forward slash at the end. However it’s not required in HTML5, so this will save you a bit of typing.

Now let’s move on to building the core body page. I’ve slimmed down the template a bit to include only the header navigation bar along with the notorious thumbnail display. In the top portion I’m isolating the navigation with HTML5′s nav element. We need to use this as a container since the background will span the entire width of the page. However our inner content is set inside a wrapper limited at 710px wide.

<nav>
    <div class="wrap">
		<ul id="menu-l">
			<li><a href="#">Shots</a></li>
			<li><a href="#">Explore</a></li>
			<li><a href="#">Designers</a></li>
			<li><a href="#">Jobs</a></li>
			<li><a href="#">About</a></li>
			<li class="floatr"><a href="#">Sign in</a></li>
		</ul>
	</div>
</nav>

The rest isn’t too exciting, just a simple unordered list of navigation links. Dribbble actually has the sign in link floating off to the right side pushed up next to the search bar. For this I just created a class .floatr to append onto the list item.

Building our Thumbnail Display

Now directly underneath the navigation section I’ve created another div wrapper. This holds a sub-navigation menu with inactive links to sort through the many different shots. I also included a copy of the small heading text displayed on Dribbble’s featured section.

<ul class="subsortnav">
	<li><a href="#" class="sel">Popular</a></li>
	<li><a href="#">Everyone</a></li>
	<li><a href="#">Debuts</a></li>
	<li><a href="#">Playoffs</a></li>
</ul>

<h2><strong>What are you working on?</strong> Dribbble is show and tell for designers. <a href="#">Sign up as a spectator</a></h2>

Now let’s take a quick look at how I’ve setup the shots gallery. Each row displays 3 different shots measuring about 220px in width. The formatting is held inside an ordered list with each new shot attributed inside a list item.

This can get a bit tricky since we’re working with more than just plain text. But HTML lists were built for much more than just navigation menus. And certainly this dribbble gallery is one such example. Check out my code below and we can break down each segment individually.

<ol class="dribbble clearfix">
	<!-- @teaser #001 -->
	<li id="screen-1" class="group">
		<div class="shot">
			<a href="http://dribbble.com/shots/393501-Ampackaging"><img src="shots/01_teaser.jpg" /></a>
		</div>
		<span class="meta"><a href="http://dribbble.com/55His"><img src="photos/55-hi.png" class="avatar" /> 55 Hi's</a></span>
	</li>

To make recognition easier I’ve given each list item an ID of “screen-#” starting at 1. Inside are two different block areas – a div containing the shot image along with a span underneath for the author’s name and avatar photo. Much of the internal HTML looks exactly the same within the OL element. So now let’s turn our focus onto CSS markup.

Styling the Page

Inside my example style.css you’ll find each of the code blocks split into segments. At first I’m doing some formal browser resets to remove margins and padding, along with re-setting font sizes to the traditional 1.0 scale. By that I mean the 62.5% value creates a ratio of 1.0em = 10px and all font sizes/line height values are even.

/** default styles **/
* { margin: 0; padding: 0; }
html { height: 101%; }

body { font-family: Arial, Tahoma, sans-serif; font-size: 62.5%; line-height: 1; background: #eeeeee; }

a { color: #5484a7; text-decoration: none; }
a:hover { text-decoration: none; color: #356080; }

Such an interesting part of our CSS is handling each dribbble box display. The ordered list element is given a class of “dribbble” and each internal list item holds a shot image and author details.

If you notice I’ve included a secondary class .rowstart on some list items. This is applied to each shot starting on a new row. In this case ID numbers 4, 7, and 10. The class will just clear everything from the previous row so we know the next three boxes will display properly. Also worth noting are some of the slight margin fixes I’ve applied to the author avatar image.

ol.dribbble { list-style: none; }
ol.dribbble li { width: 220px; height: 210px; margin-right: 15px; float: left; }
ol.dribbble li.rowstart { clear: left; }

ol.dribbble li span.meta { font-size: 1.2em; display: block; font-weight: bold; padding-left: 6px; }
ol.dribbble li span.meta a { text-decoration: none; display: block; }
ol.dribbble li span.meta img.avatar { float: left; margin-right: 6px; margin-top: -3px; }

Creating Shots

We are using a class of .shot attached to the internal div element inside each list item. This behaves as a block with a limit of 220px in width and 210px in height.

Ideally this should be enough since none of the author’s names would break onto the second line. However if you wanted to include extra user information or add Dribbble’s social icons you can set the box height to auto. Then using a bottom margin add extra space as needed. Though I feel that using strict size limits will work better across all browsers and resolutions.

ol.dribbble li div.shot {
    display: block;
    clear: left;
    margin-bottom: 8px;
    background: #fff;
    -webkit-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.07);
    -moz-box-shadow: 0 1px 2px rgba(0, 0, 0, 0.07);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.07);
}

A fantastic bit of CSS3 code is from the selector above using drop shadows. This displays a very slight shadow coming out of the right side of each box. The color setting is applied using RGBa which allows reduction in opacity. In this scenario we’ve created a solid black color with only 07% alpha transparency instead of 100%. This gives an ever-so-slight drop shadow that looks stunning in contrast with such a light background.

Live DemoDownload Source Code

Conclusion

I hope this brief tutorial has demonstrated just how easy it is to prototype a layout using CSS3. Even with many of the older properties it’s still a simple process to look over a page design and clone much of the functionality yourself. And with HTML5 specs growing in support web developers have never had it easier! Let us know your thoughts in the post discussion area and be sure to download a copy of the demo source code above.


Advertise here with BSA

Weekly Design News – Resources, Tutorials and Freebies (N.117)


This is our weekly column were we share our favorite design related articles, resources and cool tidbits from the past week. Enjoy :)
If you would like to receive our daily updates and keep up to date with the latest and greatest articles and resources from the design community, you can follow us on Twitter, on Facebookor by subscribing to our RSS feed.

Developing a Responsive Website: Background Images

Developing a Responsive Website: Background Images

Webfont Icons: an Alternative to Images

Webfont Icons: an Alternative to Images

How Commercial Plugin Developers Are Using The WordPress Repository

How Commercial Plugin Developers Are Using The WordPress Repository

HTML5 Reset Version 2

HTML5 Reset Version 2

The All-New CSS3 Click Chart

The All-New CSS3 Click Chart

Animated Web Banners With CSS3

Animated Web Banners With CSS3

Prevent Password Reset WordPress Plugin

Prevent Password Reset WordPress Plugin

iPhone, iPad & Browser Wireframe Templates

iPhone, iPad & Browser Wireframe Templates

Meander Free Font

Meander Free Font

Free Typeface NeoDeco

Free Typeface NeoDeco

Social Media Icons Pack

Social Media Icons Pack

Mini Cards: 15 Credit/Debit Card Icons

Mini Cards: 15 Credit/Debit Card Icons

This Week on CodeVisually

We recently launched CodeVisually, our site that focuses solely on resources and tools for web developers and offers a simple solution to painlessly find the resource needed and fast.

Here are our favorite webdev resources from the past week:

Create

Create

CraftMap

CraftMap

ResponsiveSlides.js

ResponsiveSlides.js

impress.js

impress.js

Revolver.js

Revolver.js

PxLoader

PxLoader

W3Clove

W3Clove

CSSrefresh

CSSrefresh

Previous Weekly Design News…

Design News Roundup Archives →



50 Wonderful Black & White Photos with Partial Color Effects


Taking a black and white photograph and adding partial color to certain key points of the shot is one of the most popular techniques amongst professional photographers. You can understand its popularity when you look at the examples we have for you below. This technique can take an otherwise dull image and make it vibrant by highlighting critical areas of beauty. And, as you will also notice, they can at times be very powerful.

At the bottom of this post we have added some tutorials to help you recreate this effect. Hope you enjoy our selection :)

Buddha

Buddha
Source →

In Wonderland

In Wonderland
Source →

A Greed

A Greed
Source →

Sleepwalker

Sleepwalker
Source →

Herbstblatt – fallen leaves

Herbstblatt - fallen leaves
Source →

Colour my life with the chaos of trouble

Colour my life with the chaos of trouble
Source →

Sunset after the rain selective colour

sunset after the rain selective colour
Source →

Princess

Princess
Source →

Times Past By

Times Past By
Source →

Love

Love
Source →

Waiting on a cool breeze!

Waiting on a cool breeze!
Source →

Ladybug

Ladybug
Source →

Bird Eyes

Bird Eyes
Source →

Banana

Banana
Source →

Dewy Pine Leaf Uncurling

Dewy Pine Leaf Uncurling
Source →

Telephone in Selective Colour

Telephone in Selective Colour
Source →

Chondro Selective Color

Chondro Selective Color
Source →

The Boat & The Castle

The Boat & The Castle
Source →

Rim & Caliper on 427R Roush Mustang

Rim & Caliper on 427R Roush Mustang
Source →

El Vendedor de Colores

El Vendedor de Colores
Source →

Torre de los vientos

Torre de los vientos
Source →

Walk This Way

Walk This Way
Source →

A place to rest

A place to rest
Source →

Racing Rainbow

Racing Rainbow
Source →

Gateway Cup St. Louis

Gateway Cup St. Louis
Source →

Colors in B&W

Colors in B&W!
Source →

Kiss Kiss Love

Kiss Kiss Love
Source →

Yellow City

Yellow City
Source →

Fighting to stay alive

Fighting to stay alive
Source →

Montenvers

Montenvers
Source →

Magie Poppins

Magie Poppins
Source →

Orange bicycle

Orange bicycle
Source →

We all livin’ in a blue tractor

We all livin' in a blue tractor
Source →

HHP Homecoming Football

HHP Homecoming Football
Source →

Viento State Park

Viento State Park
Source →

Red Seat

Red Seat
Source →

Butterfly

529
Source →

Goalkeeper

Goalkeeper
Source →

Black and Blue

Black and Blue
Source →

Ground Squirrel

Ground Squirrel
Source →

Romabikepolo

Romabikepolo
Source →

Boston1

Boston1
Source →

Leaves

Leaves
Source →

Catlick

Catlick
Source →

Dandelion Taraxacum

Dandelion Taraxacum
Source →

MyFest

MyFest
Source →

Cold drink. Hot day

Cold drink. Hot day
Source →

A Little Red Car

A Little Red Car
Source →

Cockerel

Cockerel
Source →

Red Bridge

Red Bridge
Source →

Tutorials & Resources

Black and White with a Splash of Colour (Photoshop Tutorial)
Mono, with a Dash of Colour (Photoshop Tutorial)
A Splash of Color in Your Black and White
Black and White… with the occasional splash of colour (Beautiful Examples)
iPhotography App Showcase: 10 Color Splash Creations (Examples)

You might also like…

20 Inspirational and Free Downloadable Photography Magazines →
20 Beautiful Examples of Photoshopped Smoke Art and Technique Tutorials →
30 Creative Photography Examples using the Polar Panorama Effect →
19 Tutorials for Creating Beautiful HDR (High Dynamic Range) Imagery →
24 Examples of Stylish Sabatier (or Solarised) Effect Photography →
20 Amazing Images That Could Be HDR – But are definitely Not →
20 Amazing Examples of Conformal Photography. How do they do this? →



How Profile Photos Can Affect the User Experience


Social networks have grown into the norm in today’s sophisticated Internet. Modern web pages have become very personalized over the past decade including a number of user interface features. One such example is the user profile picture often accompanied by each username.

featured image - bar cafe breakfast style

Web designers don’t often realize how important this profile photo can be. It distinguishes a blend of personality between each member. And this feature also has quite a few other handy applications to the user experience ultimately offering a clearly recognizable icon. Below I’ll go into some examples of how user photos can improve your website’s performance.

Offer a Default Option

When users first sign up for your website it’s best practices to generate some type of generic avatar. Without this your profiles will look strange having some members with custom photos while others are blank. Most CMS systems including Joomla!, WordPress, Pligg, and vBulletin all offer a standard user picture by default.

example default icons through Google+

If you take some time searching through Google you will likely find a few other excellent examples. This default photo gives incentive for new members to customize their profile details. This holds especially true with members who have profiles on a number of other networks – generally I like to keep all my photos consistent between sites.

Display Photos Wherever Reasonable

Some website layouts are a bit cramped for space and just can’t facilitate room for user pictures. But I would advise almost always including a user’s picture on central pages. It can even be argued to match the user’s photo with every instance of their username.

Foursquare  founder Dennis Crowley

This reinforces the idea that each profile link or page comment is connected to a real person. The glyphs will become familiar over time and you can easily distinguish between links to user pages vs article pages.

There are plenty of areas where you may wish to omit the photo, or resize it altogether. Such an example may include a “recently logged in” widget in your sidebar or footer area. In order to display the last 15-25 active users you could setup a small block of avatars in 3-4 rows. But to fit these in place you may need to resize the images a bit.

Apply Unique Sizes

Of course the dimensions and overall size of your default avatar is crucial to the design. Larger photos will have a much deeper impact on visitors as it will certainly catch their attention quickly. On a similar note there will likely be pages that you want to include smaller photos.

This is why it’s always best to store at least 2-3 different sizes of avatars. Start with your largest (say 150×150) and scale down based on your needs. Plan out the user interface ahead of time so you can fit in reasonable dimensions. Just a few alternate areas to consider are within page comments, shared links, and on other friends’ profiles/following list.

New members on Design Shovel - sidebar widget

There are plenty of free scripts and tutorials available which can help you resize avatars automatically. Why spend time rewriting programs from scratch when there are templates you can work off? These scripts will also save room on your server without needing to save 2 or 3 local copies of a similar image.

Pictures in Discussion Threads

Over time the most active members on your website will become more recognized. Along with their usernames, including a personal photograph can become extremely memorable. The social news website Reddit doesn’t use any photos and yet plenty of members are recognized by username alone.

old screenshot from Digg v3 comments thread

But understand this is certainly not the majority! Most blogs, discussion boards, web forums, social networks, and IM apps all utilize some type of user photo for easy identification. Many users eventually become a staple to the website community between repetitive comments, massive followers, and other social activities.

On some websites you’ll even find signatures in discussion threads. These are small areas underneath the post content which is specific to each user. You can customize your signature with a graphic, website links, text, really anything you want. But for more standard blog platforms this is a bit too “over the top” for regular discussions. It’s still interesting to compare the different styles and how they play well with profile photos.

Consider your own Brand

It’s great to get behind this issue from a realistic point of view. Ponder for a moment if you were to sign up for such a similar social network, how would you incorporate your own avatar brand? The answer may differ between networks (ex: Facebook vs Twitter) but ultimately your goal is the same.

You want to be recognized quickly and easily by all your visitors. It’s just as important to the average user that their profile is recognized as quickly as a company or brand. This is why I recommend using a generally larger photo size – maybe square 200px or 250px – to represent each person. Position it in alignment with the user’s name, location, or other important metadata.

A good example of this layout is from Digg’s old v3 profile design. Avatar photos were generally aligned to the right with more detailed user information cascading along the left side.

screenshot from older Digg v3 profile page

OAuth Connections

If you feel that custom functionality for user photos is too much to implement you may consider using Open Authentication. With this open API protocol it’s easier than ever to connect into a user’s 3rd party account and pull their data remotely. This includes usernames but more importantly also includes profile photos!

Twitter bird plush doll

The Twitter Developer Center is an excellent example of heavy documentation for OAuth calls. You will need to understand a backend language such as PHP, Ruby, Python, or something similar. It is possible to access user icons through JSON/JavaScript, but it’s certainly not the most recommended method.

San Francisco at Night

Also here’s another article from Google support documenting a basic OAuth call. You can already see how this method would save you time as a developer. But it is also very convenient for your members from a UX perspective. Between Twitter and Facebook it’s likely that most of your new signups will have some option for importing a user picture. This saves your new members the hassle of re-uploading another picture.

Conclusion

These ideas are not exactly new to the web, although they have been adapting steadily over the past few years. OAuth is just one technology which has gotten the ball rolling. It is clear we’re moving towards a cloud-based interconnected transparent system of communication and these protocols are merely a stepping stone in the process.

Overall it is your decision on how to approach personal user data. If you truly feel your website wouldn’t benefit from user photos then you’re likely not missing out on much. But understand the connections which are formed through these recognizable pictures and how they may provide a crucial impact in your community.



What else does HTML5 need to defeat flash? (Part 2)

Advertise here with BSA


In part 1 of this article, we analyzed the technical problems facing HTML5. In part 2, we’re going to discuss the problems facing HTML5 commercially.

Unity:

Microsoft, Google and Apple are clearky the 3 giants of the industry at the moment, and it’s really hard to unify them under a single standard.

“Go, go, go! Fire in the hole!” As Apple declares war on Flash, Microsoft seems willing to watch the fire from the other side of the river. As for Google, it supports HTML5 on the one hand, while on the other it also adds support for Flash in Android. Adobe must find a way to take advantage of the conflict between the giants. The future of HTML5 is at stake.

Let’s suppose that even Adobe is not able to do that. The fighting between the 3 giants would probably ruin the future of HTML5. The famous case of OpenGL is the best example. The initial member of this standard was All-Star Games, but the development and spread was far less rapid than Direct3D due to the endless quarrels around profits. The market is almost entirely taken by opponents, and its application restricted in professional areas.

User acceptance:

No matter how attractive the market promotion is, user acceptance is the final exam standard. At present, HTML5 is not looking like it’s going to be able to bring fundamental change to the desktop in a short period of time, and so there’s a need for a a coexistent relationship with Flash.

The reason for this is that the user doesn’t care about the technology. What they care for is the effect. There is still a long way to go for HTML5 before it reaches the level of effects realized by Flash, and this restricts the willingness of small websites to use canvas. If canvas can’t be popularized then HTML5 is losing a major battle. If the coding problem of video tags can’t be solved, there simply won’t be any way to compete with Flash.

Prediction:

Google, Microsoft, Apple and Adobe are playing cards. Adobe is the banker, and has the best cards. On one hand, the other three want to pull him out of that position. On the other, they don’t want to cooperate with each other. So while establishing an ambiguous relationship with Adobe, Google also has its own plan.

In this game, Adobe dominates the current situation. It seems impossible for HTML5 to take Adobe’s place, because Flash has already taken the ruling position in the traditional desktop market. Even though Flash isn’t perfect, it’s not broken enough to need a replacement. The truth is that the traditional desktop is challenged by new power. There is to be a coexistent period of time between Flash and HTML5 during which the two compete. Adobe has the weapons of Photoshop, Dreamweaver and Fireworks. Webpages cannot be developed without Photoshop, even for the HTML5 webpage. Dreamweaver is the current No.1 choice and canvas applications can be developed usinf Flash CS5.

Flash Player cannot bring direct profit to Adobe, but it symbolizes the standard of the rich media application market. The editor developing Flash is seeing real income. Let’s suppose that in the HTML5 era, the developers still have to choose Adobe products to develop canvas based web interaction. Why then would we need Flash Player? For Adobe, it saves the cost of maintaining a complicated system.

As for Microsoft, it’s a difficult situation. They have the IE card, but they aren’t sure whether it’s a trump card or not. The reason being that IE6 takes a large amount of the market, but the new versions of IE have to compete with former versions. They also have the card of SilverLight, which has a competitive relationship with Flash and HTML5. Support of HTML5 could have a negative effect on SilverLights popularization. Therefore, Microsoft would rather not fully support HTML5. Instead, it will be treated as a supplement of SilverLight.

Apple however has a great plan. They have decided to begin at the mobile platform level, and gradually move to desktop. iPhone is the first successful step. The existence of iPhone proves that Flash is unnecessary in the smart mobile industry. As a matter of fact, the Flash experience in this field is pretty terrible. However, the most important step is iPad. The iPad is almost similar to ordinary computers both in screen size and operation experience. If tablet PCs prove to be comfortable independent of Flash, then why shouldn’t the ordinary PC? If the user gets used to the non-Flash experience of tablet PCs, there’s no hope for Flash anymore. Since iPad came into being, the controversy between Apple and Adobe has escalated, proving the important role of tablet PCs in this battle.

However, is Apple going to realize its dream easily? Apple products perform really well in sales, but aren’t as popular as Microsoft products. The reason being that its culture provides the high-level experience of taste and quality, and that high level experience means a higher price.

Globally speaking, we have developed countries, developing countries and undeveloped countries, where most are without the money to buy Apple products. The people simply can’t pay for the increased quality.

So here comes the question: Is there a company capable of providing a similar experience? What about Microsoft? The answer is no. The reason is that Microsoft provides the service to all people. Its products need to be universal, consistent and not overly expensive. So Microsoft is not motivated to change user experience. They have tried to bring change in Vista, but the result was that XP users got confused and angry.

Maybe, Apple didn’t plan to make iPhones universal at the very beginning. Perhaps focusing on top of the pyramid will guarantee enough income, so does the iPad. It’s not popular enough to challenge the traditional desktop. Users can experience cheaper tablet PCs from other companies, and those tablet PCs will probably support Flash. If things happen in that way, Apple’s plan may end in failure.

As for Google, the result of the war is not too important. As long as users continue using webpages, they doesn’t care whether the web pages are HTML5 or Flash. This doesn’t mean Google is irrelevant though. On the contrary, they are the key factor in this war. Except for YouTube, Google seldom use Flash in their products. Although Flash is functional, it’s not an open product; so Google cannot decide its development direction. An open standard is easier to control for them. Nowadays, the rapid development of Chrome increases Google’s power in HTML5 establishment, but it doesn’t mean they’ll give up on Flash.

Flash is an important tool for Google to restrain Apple. It’s the chip with which Android challenges the iPhone. Last year, Google and Adobe collaborated to put Flash Player plug-ins inside the sandbox within Chrome, which promoted the performance of Flash on safety and resource cost.

Conclusion:

From the above analysis, we can conclude that Flash still controls the market of internet rich media. Its fate in mobile platform will be entirely determined by Google’s attitude.

As for HTML5, there will probably be a rapid development that makes it relatively popular in the next 1 to 3 years. It won’t take the place of Flash though. Instead, they’ll be coexistent for a period of time. Considering of the conflicts among the giants, there isn’t much hope for HTML5. It took so long for browsers to accept the current standard, and it’s going to take a much longer time for them to accept new ones. In this transitional era of Flash to HTML5, there is still a long way to go.

You might also like…

10 Essential Guides, Resources and Tools for Getting Started with HTML5 →
HTML5 and CSS3 Form References, Resources and Tutorials →
10 HTML5-Ready Blank, Bare-Bones and Naked Themes for WordPress →
Beginner’s Study Guide to HTML5 Microformats →
Guide to HTML5′s New Media Tags – Audio and Video →
Coding Flexible Web Layouts in HTML5 and CSS →


Advertise here with BSA