danielhpavey.uk

A sorta, kinda, web development and design blog...

Load A Joomla! Template File From A Separate View

Wednesday 10 February 2016

Load A Joomla! Template File From A Separate View I am working hard to improve the quality of my php code and one of significant technique is to use the DRY principle. However this can become a little harder to stick to when using a framework / CMS. I mostly work with…

Tags: #joomla #web development #php

Joomla! Template Equals Component

Monday 1 February 2016

Joomla! Template Equals Component I knew that you can modify the output of Joomla! still further by tagging "tmpl=component" onto the end the url. This should then output the content of whatever component you are viewing without the template. You might need to create a component.php file in the root of your template…

Tags: #joomla # web development

Never Design The Home Page First

Thursday 14 January 2016

Never Design The Home Page First This is something I think about doing, but really need to actually start doing it! Pro tip. Never design the homepage first. Always start with a product page, an article or a page where design thinking is really needed.— Joe Leech 红豆 乔 (@mrjoe) January 14,

Tags: #design #inspiration #web design

The Pressing Need to Overtake

Friday 18 December 2015

The Pressing Need to Overtake I cycle. Every day. Well, most working days. I cycle to work. When you cycle a lot it is very easy to develop a sizable chip on your shoulder about motorists. I try to resist this as clearly, not all motorist are evil fuckers... However there are enough who…

Tags: #cycling

2 Hard Things in Computer Science

Thursday 10 December 2015

2 Hard Things in Computer Science I've long been a fan of this quote from Phil Karlton "There are only two hard things in Computer Science: cache invalidation and naming things" However I am an even bigger fan of the slight variation on it: "There are only two hard things in Computer Science: cache

Tags: #web #web development #programming

Recursively count all the files in a directory

Friday 27 November 2015

Recursively count all the files in a directory Every now and then I need to do this... so this is here for reference... find . -type f | wc -l linux - Recursively count all the files in a directory

Tags: #terminal

Git --assume-unchanged Problem When Switching Branches

Friday 20 November 2015

Git --assume-unchanged Problem When Switching Branches I had a problem switching to a different branch when using git --assume-unchanged. I've been using this command as a lazy git ignore and found it quite useful. However, I recently tried to switch a branch when I had marked a config file --assume-unchanged and had…

Tags: #git #web development

Search a Multi-Dimensional PHP Array with Standard PHP Library Recursive Iterator

Wednesday 4 November 2015

Search a Multi-Dimensional PHP Array with Standard PHP Library Recursive Iterator (That's definitely the best blog post title I've ever come up with...) Messing with php arrays often messes with my head... So I needed to search a multi-dimensional array and return the results in an easily accessible format. A bit of research uncovered…

Tags: #php #web development

Super Simple Git Submodule Guide

Tuesday 6 October 2015

Super Simple Git Submodule Guide Hopefully you already have some idea what a git submodule is, but if not: It often happens that while working on one project, you need to use another project from within it. Perhaps it’s a library that a third party developed or that you’re developing separately and…

Tags: #git #web development

PHP DateTime Class - Or why it pays to read the documentation (sometimes!)

Friday 18 September 2015

PHP DateTime Class - Or why it pays to read the documentation (sometimes!) I've always struggled with dates in PHP, more specifically writing dates submitted by a PHP form to a database correctly formatted. I've done a few weird and wacky things to get the dates into the database as proper datetime…

Tags: #php #web development

< Previous Next >