Jamie Balfour BSc

Welcome to my personal website!

Technology enthusiast

I am very interested in technology, particularly relating to computer science. I am most interested in web design and development.

My main hobby is programming. One of my most well known products from this is ZPE. I also am the sole creator of BalfBlog, BalfBar and BalfSlider.

A little bit about me

In 1997, when I was six years of age, I got my very first computer. I was always very interested in the ins and outs of it and dismantled it to see how it worked.

Years later, in 2016 I received my BSc (with honours) in Computer Science, obtaining a First class degree.

I'd like to welcome you to my website and hope you enjoy using it as much as I have enjoyed building it!

Google Plus
Jamie Balfour BSc
Full stack developer

Personal Blog

When I first started my website in 2010 I never once thought I'd be interested in web development and server stuff. I only actually started my website as a way of getting information about my software out there. I never saw it as a way for me to learn a new technology or to experiment with new things.

As time has gone on, my demand for new stuff on my web server has gone up and now I'm at the stage where I've become not only a competent web developer, but I now have a lot of experience with Linux servers (my job is spent half of the time doing things like server administration in Linux).

So without further ado, the main subject of this post. I bought a VPS package very recently and started a new website.

Well, I will one day transfer this website across to it, but for now I am experimenting with one or two things.

So I decided to compare my current shared hosting package with the VPS package in terms of performance using a PHP script shown below:

time php -r 'for($i = 0; $i < 100000; $i++) echo $i;'

and here's the results:

real 0m0.122s

user 0m0.038s

sys 0m0.078s

real 0m0.880s

user 0m0.144s

sys 0m0.248s

As you can see, the first set of results are much better and that's because they are the VPS results. Despite the VPS package only having 512MB of RAM and 1 core vs 3GB of RAM and 4 cores on the shared package, the performance is still much higher (I was originally concerned there might be a problem with performance here because of the lack of cores).

So there you have it, the difference is quite substantial and may mean that I change my own site to VPS, particularly because it will allow me to experiment with things.

I rushed BalfBlog 2.3 out a few weeks ago and realised the installer which was made on the day of release was just not perfected enough. In the next few weeks I intend to release BalfBlog 2.3. 

I'm also astonished to say that it's changed internal a huge amount. 2.4 and 2.5 aim to make the system more powerful, but in terms of features since I first released 2.3, it has come a long way. The interface has been modified to make it more flexible on mobile and desktop, it now features glyphs on the options, a new help feature, a more powerful API and much more Ajax support. The UI focuses more on a blue look, something taken from my own website but has become a staple part of the BalfBlog interface.

2.3 will also be the last version to include procedural modules. In 2.4 I aim to move all of these modules to a more object oriented design, one that will make the system easier to maintain. As well as that, I've cut out several old JBlogs methods that were being used for very little purpose. For starters, there is no longer the GetPostsForUser or GetXPosts functions, both of these have been solidified by the single GetPosts method, which now accepts an associative map of parameters, these will be documented in due course.

Security has been improved as part of the object oriented design, so it's even easier to protect your dashboard. 

2.4 will focus on finishing off the object oriented features, adding the updater and on validation and sanitisation of data. Either version 2.4 or 2.5 will focus on the addition of a plugin system. The log entries that are stored will also soon be improved, because this feature was an original JBlogs feature from 2014 and hasn't seen any updates since it started. 2.4 will also focus on the integrated messaging system that I've spoken about for a while. Also, multiple categories are also coming. So you can easily categorise posts in two multiple categories. I'm also thinking about adding my own styled custom dialogs rather than using the basic JavaScript alert popups that I use at the moment (and funnily enough I have written my own one already, just not quite got round to putting it in to BalfBlog).

For those who are interested as well, the focus on BalfBlog has detracted from BalfBar (and the rest of my Web Neutral Project) and ZPE. Once I've properly launched BalfBlog 2.3 I will focus on these again for a bit, so no worries. I plan to redo the ZPE page on my website, breaking it down in to a smaller documentation on each individual feature. Also, I'm very happy to say that ZPE has been downloaded 5,000+ times as of April 2017! That's amazing! 

If you are interested in downloading 2.3 please get in touch or wait until the middle of May for the official release! :)

I'm starting to produce a new version of BalfBlog each month, similar to how ZPE works.

This will allow me to add new features every month that make huge changes to the way you can use BalfBlog.

Here are a list of new features set for the middle of May:

  • New custom alert boxes
  • Validation on forms (something I have wanted to have for a while but as I've rebuilt it, everything has changed so much)
  • CSS, JavaScript and PHP tidy up
  • A central database query generator
  • A tidy up of the IA of the system
  • User preferences
  • All Ajax posting will also have an equivalent non-Ajax version and vice-versa.

A huge change has recently made BalfBlog even more object oriented, now the whole core of the system is being divided up into smaller classes, all of which are included appropriately when needed. This makes it easier to develop in BalfBlog.

BalfBlog needs to maintain its focus and not get lost the way that some other CMSes have. The focus must be on getting it to the level where it allows you to produce articles and blog effectively and not stray from that. Plugins will soon be available to improve features but not detract from the original aim.

Morning everyone. Today and tomorrow I will be doing some essential site maintenance that will take down every subdomain hosted on my website. Some of the more popular ones are clickit.jamiebalfour.com and code.jamiebalfour.com. blog.jamiebalfour.com will still redirect you to my blog.

I'm hoping to minimise the effect of these updates but I realise that BalfBlog and ZPE both depend on code.jamiebalfour.com to check for updates so they will not work at the present time.

The last few weeks have made my website more secure and more performant. I have spent a lot of time making my site work with cron jobs so now my site it is even easier to make a cron job as well as improving my own admin portal, automatically backing up the site every month, backing up MySQL databases automatically and so much more. Most of the stuff I am doing is all about refactoring code and making my site more efficient. I'm also preparing to move to a different server with the possibility of VPS being enabled, so I want my site to be able to 'just move' to that server with minimal disruption by making scripts that do all the resetting up again for me.

All subdomains should be up and running for now. FTP, SFTP and SSH for these subdomains is also re-enabled. 

We are here now! Version 2.3 of BalfBlog will officially be launched today, and more importantly hosted on a website other than my own!

That's right! BalfBlog will now be hosted on a website that's not related to me!

In a just in time way, I managed to complete the installer for 2.3 just this morning which makes a huge difference to the way that BalfBlog is installed. 2.3 also focuses on adding templating back into BalfBlog, which makes it so easy to make posts fit into your website. 

With 2.4, BalfBlog will hopefully get a new, proper name and an updater that will update all files automatically.

The update went reasonably well. Since I built the installer on the day I released 2.3, I did not imagine it would perfect in every use case, so I have decided to re-release version 2.3 in the next few weeks. That means that version 2.4 is still a long way away. I also decided since polls were not perfect to remove them from 2.3 and leave them to 2.4 (I also want to change the way that they work altogether).

I'm very happy to announce that this week I will release version 2.3 of BalfBlog.

That's really it. But what BalfBlog 2.3 brings is a huge update, by far the biggest update since BalfBlog changed from JBlogs or perhaps since it changed to having it's own backend. 2.3 has brought so much that I don't have time to skip through the changelog to find all of the features it brought. I will name a few of the key features however:

  • 2.3 moves to a more modular and better design of blogging system. 
  • Polls! They were created so long ago and yet I am now finally releasing this feature. It's not quite perfect but it should do for now.
  • User biographies - write about yourself and become a narcissist.
  • A lot, lot more Ajax - that means when you press a submit button, in most cases you will not leave the page to do this
  • A new Administration section
  • Move from PHP associative array and constants to a JSON file for the settings.
  • Better subscriber and user management
  • Export tools have been improved.
  • New information section
  • Moved from MySQLi to PDO, making the blog more efficient
  • Template system has been brought back, allowing you to completely change the way a post is displayed
  • New help desk feature allows remote login to help you setup and maintain your installation
  • More flexible content management system
  • Option to switch to CKEditor instead of TinyMCE.
  • An update to the new post, update and delete backend appearance
  • Soon to have a logo (hopefully in time for this release)

If you are interested in the next version of BalfBlog, let me know by getting in touch, I know the next version has one new website which is going to commit to using it instead of something like WordPress or Joomla which is great!

Version 1.5.3 will now change the way that the break function works. In fact, it will no longer be a function at all, since a function implies it has a return value (and functions that return nothing will return void). Break has always been a special function, mainly because of it's purpose, but also because of the fact that it cannot ever return anything, just like the return function did before it became a staple part of the compiler.

Break has followed suit in the step to promote it from being an interpreted function to a compiled keyword, just as return did back some time ago. Not only did this improve the speed at which return was processed, but it also made it even more difficult to overwrite it. 

My question to myself is now, when will version 1.5.3 stop getting updates and when will I actually release it? Well, the answer to that is that I aim to make this a perfect distribution, fixing all bugs that exist currently and adding as many of the promised features as I can. I anticipate the start of April 2017 for this update to be launched on my website, but until then you can always try out the unstable beta versions from the link on the page.

Also, as part of the update and refactoring of the Zenith Engine, I have made version 1.5.3 a lot smaller and a lot faster. I may explain where the performance gains come from in a blog post, but probably not. Overall, 1.5.3 is one of the biggest updates to ZPE since version 1.5. It also ditches GSON in favour of JBSON.
I have released version 1.5.3 on to my website for download. I have also begun work on version 1.5.4 which aims to change quite a lot of the underlying data structures.

Notice anything different about my blog? No, you don't. And actually, this change came on the front end for a change. Yup, that's right. An unnoticeable change that no one would be aware of unless they are hosting using BalfBlog 2.3's latest update, which currently only I have. 

So what is it?

Templates are finally back

What this means is you no longer follow the styling of BalfBlog in the front end at all, let your site do the work is now completely true. You can design a post template very easily by just editing the appropriate template. I have provided several basic templates with the default installation and these will soon be editable from the dashboard.

There are currently just two templates, introduction and post. These templates will be supplemented by a third one soon for single post view and further on I will perhaps change the way that the journal mode works to use one of these as well. This gives flexibility over the way posts are represented far more than before.

I will push this change live to my other BalfBlog installations very soon. Also, the standard GeneratePosts has been moved to GeneratePosts2 and the new GeneratePosts follows this template scheme.

After a long thought process, I am very happy to finally be bringing the index accessor to ZPE . A lot of languages that ZPE aspires to transpile to also have this, so it's fairly important.

It looks like this:


Currently assignment to this is not possible, but it will be soon. I am going to deprecate the list_get_at_index and the equivalent for associative arrays. 

Also in the latest vesion of ZPE is the early stages of Typo - ZPEs runtime type checker (it will also be in compile time too) and the new feature which will allow you to produce web pages utilising ZPE. 

The latter feature is more of a side project than a major one.

Also, I'm glad to say in the next few hours I will continue the ZPE refactor that takes a lot of ZPE 1.3 out of the code. The big refactor has minimised code from 15,000 lines to just under 9,000 overall, but the structure is miles better.

I also hate to say it, but ZPE is running low on byte codes, with only 160 left at the present point in time (meaning that 96 have been used). 20 more of these are reserved for special purposes.

When I started to write BalfBlog under the name JBlogs in 2014 I began using the now deprecated mysql commands. After some time messing about I switched to the much faster and more powerful mysqli commands. 

This was the first big change in the history of the code in BalfBlog. Moving to PDO from MySQLi was another big change (probably about the sixth big change in the history of BalfBlog) and I claim it has many performance improvements.

The improvements do not come from querying the database because I know outright that MySQLi is better for that since PDO adds a layer of abstraction over the databases. No, they come from preventing running the query twice - which is an obvious waste of resources.

Now that I use PDO, this is no longer required since the way that binds are done is much better. Creating prepared statements is so easy and this is where the performance gains come from. 

Also, I will point out as it seems a good time. Performance is being thouroughly tested at this point in time under many use cases. PDO definitely seems the way to go however, and it will also allow me to easily switch around database commands to allow other databases to be used in the future. 

Also, not every part of the dashboard has converted yet, but most have.

Site accessibility

A lot of the original functionalities that once existed here have been removed.

This page was generated in 0.33 seconds using 6291456 bytes. Slow? Let me know.

To use project mode, the window must be greater than 920 pixels in width.
Click here to disable Project Mode.
This site uses cookies to deliver its services, to personalise ads, to store preferences and to analyse traffic. Information about your use of this site is shared with other companies. By using this site, you agree to its use of cookies.
Contact me
Contact Jamie Balfour

Get in touch with me via this form.