Language English English Español Español Deutsch Deutsch Português Português
🇬🇧 English 🇪🇸 Español 🇩🇪 Deutsch 🇧🇷 Português
Language:EnglishEnglishEspañolEspañolDeutschDeutschPortuguêsPortuguês

Squeezing out Efficiencies

The growth of my cocktail recipe website has been truly scary this year. I am into my second year of >100% year on year growth in the site, I have doubled in volume since January and if anything growth is accelerating.

The plan of course is to keep growing and doing well. I am currently at 2/3 of the bandwidth limit my web hosting company allow me which although cool is very scary when you look at last year’s traffic distribution numbers.

The main point of this note is to encourage you guys to check out your code. I just recoded the displaycocktail.php script on my site (which accounts for 20% of bandwidth and >50% of files served). It turns out this script (which has grown organically and been coded in chunks since 2001) is horribly inefficient. I reduced the lines of code in the script by 55% to just 304 including all HTML and the weight of the page produced by 21% which will reduce my bandwidth usage by 4-5% which is cool and also has halved the SQL queries per page load on that page.

Efficiency is dull but I am hugely glad I did this and am looking forward to running through the rest of the site spring cleaning in Fall. If nothing else it will allow me to have a much smaller, easier codebase to maintain which is definitely good news!!!

Get my marketing cheat sheets at Click Here

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *