Blog - Michael Campanella Photography

House cleaning for the new year


Posted in Other Thoughts on January 5th, 2017

In the past week I’ve put a lot of work into doing some much needed house cleaning and maintenance on this blog. I’ve had this site since 2010 and I am pretty proud of it. It started out as just a hand coded website before I migrated everything to WordPress. Today only the blog is run on WordPress and it uses a completely custom theme that I coded myself. The site has now gone through at least 5 major revisions over the years.

The most important thing I did was go through and clean up the code base. It’s a really good exercise to go through old code and seeing what can be improved upon or removed. In the case of this website there was a lot of excess code that I was able to remove, stray code from previous iterations or components I no longer used. I was also able to find areas where I could combine code snippets together and remove a lot of unnecessary repeated code.

This was long overdue. It’s by no means an exciting job so I’m really glad that I finally did it and got it out of the way.

The second big thing I did was improve the responsive design of the theme. I had made the blog theme responsive a few years back but there were some elements that scaled a little lesss gracefully than others. Mainly the grid of posts on the index and archive pages. So I finally went back and fixed that.

For the case of simplicity I used Bootstrap. I could have made my own responsive grid but I thought why bother when someone else has already done the hard word. So now the outcome is that the columns scale much more nicely now. You have 3 columns on most laptops, it scales down to two columns on a tablet and, and then scales down to one column on mobile.

With nice and lean code base and a completely responsive layout I set out to do a little bit of restyling to the theme. One thing I have done in the last couple of years is always tried to evolve the design I have on the site, rather than throw everything out and start a new. So there is a cohesion and progression to the site to the look and feel of the site.

I started out by changing all the fonts on the site and moving away from Helvetica which I was using all over the blog. I’ve switched to a combination of Open Sans for regular type and Oswald for headings. I did this in order to try and better match the new blog sections (managed with WordPress) to the rest of the site which is controlled by Photo Shelter. I think overall there is a slightly better cohesion between the two.

I also tried to touch up and work on all the details that I have never been completely satisfied with but never had the time to address. From the posts grid, to the archive page navigation, to single post navigation, and to the footer. I spent time working on all of them making sure there is a cohesion between elements in their design and function.

With that it’s time to charge the camera batteries and get back to work.

Michael

Freelance photographer and photojournalist focusing on sports, news, & entertainment. Available for assignment in Scandinavia and Europe.