a blog by Christian Snodgrass
about programming, web and game design, and everything else

Tips & Snippets

Three Column Layout with Divider without Images

In one of my past articles, Two Column Layout with Divider without Images, I introduced a method to create a two column layout, with a divider without needing images. At the end, I mentioned that you can also apply this technique to three columns. How It Works This works exactly the same as the two-column [...]

June 29th, 2011 | No Comments | In HTML/CSS

Changing WordPress Template with template_include

I’m working on this handy little plugin so I can create code demos, so I can demo HTML, CSS, and Javascript pages for my articles, without having to create a page and FTP it up. I want to just be able to create and edit it directly from the WordPress back-end. Lucky for me, it [...]

June 28th, 2011 | No Comments | In Wordpress

Columned Layout with Background and Divider without Images

When I was designing this site, I decided I wanted to have a two column layout with a border dividing the two. The tricky part with multi-column layouts is vertical spacing. Since elements only extend as far as they need to vertically, it is often very tricky to get your columns to both go all [...]

June 25th, 2011 | No Comments | In HTML/CSS

Adding a Code Box with Word Wrap

I’ve been tinkering here and there trying to make an awesome website (how am I doing? ;)). One thing I’ve done is created a handy dandy code block parser to my WordPress, so I can quickly add code in an easy to read format. This way I can spend more time writing and less time [...]

June 25th, 2011 | No Comments | In HTML/CSS, PHP, Wordpress

Keep It Sorted: Binary Search Sort

In a previous article, I discussed binary searching and mentioned that you could modify the function a bit to get the index of where to put the value to keep it sorted. This eliminates the need to sort it on demand and lose all the performance gains of the binary search. The Binary Search Sort [...]

June 19th, 2011 | No Comments | In Flash/ActionScript 3, Javascript, PHP

Gotta Bounce: Google Analytics Bounce Rate

So, you have an awesome site, filled with pages of awesome content. You’re PR is on the rise and you get 5,000 views a day… great! But, are you really giving them what they want when they first get to your site? If you have a high bounce rate, you may not be. What is [...]

June 17th, 2011 | No Comments | In Design

Classics to Remember: Binary Search

If you went to school for programming, you’ve likely seen the binary search algorithm. If you’re self taught, as many great programmers are, you may not have come across it before. What is the Binary Search Algorithm? The binary search algorithm is an algorithm which searches through a collection of sorted values. It does so [...]

June 17th, 2011 | No Comments | In Flash/ActionScript 3, Javascript, PHP

Quick Tip: Adding Commas to Numbers

A common problem that you may run into when you want to output a number is to add commas. It’s much easier to understand 1,000,000 than it is to read 1000000. I haven’t done this in a while so I did a quick search to see what others were doing to tackle this problem. A [...]

June 15th, 2011 | No Comments | In Flash/ActionScript 3, Javascript, PHP

Padding String in Javascript

Yesterday when I was working on a little Javascript for showing all unicode characters yesterday, I needed a way to pad the string. I did a bit of research and came across a very interesting and handy approach. The Typical Approach The typical approach is pretty simple. You create a loop and just add whatever [...]

June 14th, 2011 | No Comments | In Javascript

CSS content and Special Characters

While I was working on this theme, I wanted to use the content CSS property to add some right-pointing double-angle quotation marks (ยป) for my list elements. So, of course, I used the good ole » to add it in. However, it didn’t work! It took me a bit to realize that you can’t use [...]

June 14th, 2011 | No Comments | In HTML/CSS

Back to Top