David Ogilo

menu search

I was approached by Purple to help them create a cutting edge website, which took a mobile first approach and showcases different elements of the company. The website was created using WordPress, which included a custom plugin with a OOP, TDD and CI approach. One of the main functionality was to create an API to post jobs onto the site via a third party system.

For some odd reason, there isn’t an option to add stickies to custom post types in WordPress. In this article I’ll show you how easy is it to add this with some PHP/JS code.

THE SCRIPT

The code below adds the option to make a custom post a sticky or not. If the sticky checkbox isn’t in the DOM, then it adds it in…

I recently created a simple program for the game “rock-paper-scissors”, which was for a job application. I decided to publish the code (including PHPUnit tests) on GitHub so if you want to extend or play around with it, please feel free to. The game has two modes – PVC (Player vs. Computer) and CVC (Computer vs. Computer). It can also store the instance and result of your game(s) incase you want to continue on a later date…

Web Schema offers a way to markup site content that is recognised by search engines. It’s currently only developed for WordPress but will look into supporting Drupal in the future. The plugin is still in beta and can be downloaded from GitHub. I’ll be detailing how to use the plugin below.

HOW TO INSTALL

To install the plugin just move the webschema folder to your plugin directory and activate it in the admin interface. Once that is done, you can access the plugin configuration page in…

When trying to call the twitter media upload resource using PECL OAuth, I noticed the API call was failing. I later found out that the reason was because the wrong content type was sent. The header contained Content-Type: application/x-www-form-urlencoded instead of the requiredContent-Type: multipart/formdata

I recently stumbled upon an issue when trying to set cURL as the request engine on PECL OAuth. For some odd reason I got a warning that the expected data type of OAUTH_REQENGINE_CURL was a long and a…

This function is useful if you want to display how long ago / from now a content was published etc…

I was brought in to work on the back end functionality of the site. Those functionalities included AJAX deep linking, continuous scrolling, a custom Drupal module, client side caching and overall restructuring of the site.

I have read a lot of articles online about how to disable the new admin bar introduced in Wordpress 3.1. From what I read, they have not been done the right way. The code below shows you how…

Whilst adding custom meta boxes to a content type in wordpress, I noticed that when inserting a media file into a custom text editor it always gets added to the content text editor. The reason for this is because the active editor is hard coded in the source code, as shown below in…

Old school browser detected!

Your browser is out of date, which means you can't use any of the site's required features. You can either upgrade your browser or switch to either Mozilla Firefox or Google Chrome