Archive for the ‘Web Design’ Category

I’m Such a Nerd - Now a Wine Nerd

Wednesday, April 4th, 2012

I make a living on the internet - that makes me a nerd. I build websites - that also makes me a nerd. And I do local search engine optimization - also the sign of a nerd. I love wine - and with that I’ve again become a nerd!

How much of a wine nerd do you ask? Well, I started a wine blog. I’m officially a wine nerd now. Beyond drinking it I seem to want to write about it.

Introducing the Wine Charlatan.

The Wine Charlatan

On the web nerd side of things the site uses responsive web design to reformat the layout and sizes of things to respond to different device screen sizes. Check it out.. open it on a full sized desktop monitor and grab the side of your browser window and shrink the width down to the size of a smartphone. You’ll see things change for tablet sizes and phone screen sizes.

Centering a Div in IE9 Using margin:auto

Thursday, January 5th, 2012

Almost 2 years ago I after Internet Exploder 8 was released I wrote a post about how to get divs to center properly when using margin:auto in your CSS. Now with the release of IE9 - yet another piece of shit MS browser - I’ve encountered similar issues with getting it to obey centering styles.

For IE8 there were 3 different methods that could be used to make it work;

  • Set Width:100% on the containing element
  • Set Text-Align:Center on the containing element
  • Use Transitional Doc Type

With IE9 the use of the Transitional Doc Type is now obsolete, at least for me as I’m building in HTML5 now. Maybe it still works if you use the Transitional, I don’t know. Nor do I care, so I wont bother testing it. If someone tries it please leave a note in the comments as to whether or not that works.

In my testing the text-align center trick is not working for IE9 - so that’s off the table too. Good, this was a dumb hack anyways. Having to set a broader element with centered text alignment then every other element inside it would need to be reset to left alignment - makes for bloated CSS files.

Solution : Set Width:100% on the Containing Element

So the fix is to set your containing element, the one the centered element is to be centered within, to have a width of 100%. That will get that pesky div to center in Internet Explorer 9.

For example, if your were building a fixed width centered web page that was to be 1024 pixels wide you could set the body to width:100% then set your wrapper div or what have you to width:1024px and then center it with margin:0 auto. So your CSS might look like this;

body {width:100%}
#wrapper {width:1024px;margin:0 auto}

The one extra rule of width:100% does not add much bloat, though it should not be necessary if the asshats on the Internet Exploder dev team could ever get their act together and build a browser that renders as well as FireFox, Chrome, Safari or Opera.

Playing with HTML5 for First Time

Friday, June 24th, 2011

I dabbled with HTML 5 for the first time last week. Built a small website for a Pool Cleaning company in Fort Worth, TX and decide to try using HTML5.

Me likey! Just scratching the basics, not doing any fancy geo-location stuff or anything.

Note, to make the new elements like header, footer, aside, section, article, etc… compatible for Internet Exploder all you need to do is include this HTML5 java script enabler.

On another site I built later for this painter in Kelowna, BC I had forgotten to include that piece of java script. Revealed the finished site to the owner, having failed to do all my cross browser checking, only to realize they were looking at it in IE8 and it was totally broken since it did not recognize nav tags. And with a huge number of people still on IE 8 and IE7, that java shiv is essential.

Appears my CSS Sticky Footer solution also works just fine with HTML5.

Designing and Coding a Mobile Version of your Website

Wednesday, June 23rd, 2010

I wrote a 3 part series on designing and coding up a mobile version of a website over on my other blog.

It also covers how to redirect mobile users from your non-mobile site to your mobile version.

And here are a few mobile sites I’ve done for clients lately; a car detailing shop in Vancouver, BC, and another auto detailer in Calgary, a Psychotherapist in NYC, a security alarm company in Shreveport, Louisiana, a lawyer in Los Angeles (that one is done in Wordpress) and a few more still in the works.

Updated CSS Sticky Footer for 2010 - Works in IE8

Thursday, March 18th, 2010

I finally updated my sticky footer solution! Yay! It now works in Internet Exploder 8 and is working better in Opera. It no longer uses a clearfix hack, overflow:auto does the trick instead.

My old post for the original version has gotten nearly 300 comments so far. Clearly my most popular post on this blog. I am however considering turning comments off for that post. eeek! I get so many requests for help from those having problems getting it to work and I just don’t have the time to reply to them all.

A big thank you goes to Paul O’Brian who offered suggestions that led to this updated version, and as well he has picked up a LOT of my slack in helping out people in the comments section.

The website has been featured a few times in places like Smashing Magazine and other major web design resources. Each time it does I get a big spikes in traffic for a few days directly from those articles as well as a ton of Twitter retweets and Stumble Upon stumbles. The server is bracing for the next round that is sure to come.