Home
Peter Bloomfield
Cancel

Compiling simple loops

I program weird stuff to unwind. Lately, my pet project has been a custom programming language which I’m calling “avidscript”. It’s a somewhat C-style procedural language which compiles down to byt...

The joy of C++ streams

Programmers sometimes complain about how poorly C++ handles strings. The unfortunate reality is that a language with such direct memory access as C++ can’t realistically handle variable-length stri...

Fixing LNK4098 in Visual C++

Like many C++ linker errors and warnings, LNK4098 is a little vague and cryptic at first. It comes in different flavours, but it will often have other errors with it, such as LNK2005 (“symbol alrea...

moodledata location affects Moodle performance

I’ve been working with Moodle for several years now, primarily as part of the SLOODLE project. However, one thing that has always been a source of frustration is how slow Moodle often seems on my l...

DNS misconfiguration in Plesk

I run a VPS (Virtual Private Server) through the 1&1 webhost, and was trying to create a new subdomain today using the Plesk 9.5.2 admin interface. This is an easy task which I have done many t...

Dynamic types in C++: factories, templates, or lots of switches?

While doing some C++ programming today, I was faced with a design decision. My code had to be able to create and delete objects of various types, dynamically and on-demand at run-time. That’s easy ...

PHP gotcha: Content-Type matters!

I encountered a frustrating problem regarding HTTP content type headers today. It massively broke the design of my site in Firefox, but didn’t seem to affect anything in Internet Explorer. The less...

ADOdb function: GetUpdateSQL

I have been getting myself familiar with ADOdb by using it in a personal web-development project. During my experiments, I ran across a member function called GetUpdateSQL(). In principle, it looks...

What is Standard Deviation?

The term “Standard Deviation” comes up quite a lot in research, statistics, and data analysis. But what exactly does tell us, why it is interesting, and how does it work? The basic idea is fairly ...

Making slugs with JavaScript and regular expressions

You will sometimes want to generate a suitable URL ‘slug’ based on something the user has entered, such as the name of a blog post, or perhaps the name of a file which is being uploaded. In order ...