Log last executed Eloquent query as plain SQL in Laravel 5

Here’s the small code snippet needed to quickly log the SQL output for your last executed Eloqent query in Laravel 5. I’ve had to look this up so many times, that I decided to just post it here for my own convenience. If you forget to enable the query log, you’ll notice that it will be empty all the time.

\DB::connection()->enableQueryLog();$query = \DB::getQueryLog();$lastQuery = end($query); 
read more »

Stop using perfect pictures: meaningful, realistic design is more important

As web and app designers, we’ve all been in a situation where we’re looking for the most perfect pictures to go with our beloved fonts and color palettes, only to realise later that our users are messing up our designs with overexposed profile pictures and less than average sunset pictures.

Just like me, you’ve probably avoided typing in long and obscure (but realistic) family names that don’t really fit that rectangle you just drew in Sketch or Illustrator. Entering a short name that fits and looks perfectly is so much more attractive because...

read more »

Beekeeping, there’s an app for that!

On slowing down

It’s been a while since I wrote a blog post and one of the reasons is that I’m living a bit slower than before. My job as a web development lecturer has become quite hectic over the last few years and I needed to take a break from client work to manage it all.

I remember writing about how life is really moving fast and about things you can do to slow down earlier on this blog. That post is already three years old and man, does time fly.

read more »

Userful tools and workflow tips for building mobile apps in HTML, CSS and Javascript

Recently I released a small app called “Stempeltje” that gives store and restaurant owners an easy way to give their clients a digital loyalty card. That way, customers can save up points and exchange those points for free (you know, buy 10 coffees, get one free). If you have a business in Belgium or Holland and you want to use the app, give it a try, it’s free!

As always, building the app started as just a simple idea but ended up taking up way more time and effort than initially estimated. In this post I’d...

read more »

A Laravel seeder for all Belgian cities + postal codes

Just the other day I needed a quick seeder to populate a table in my Laravel project with Belgian postal codes. A quick search gave me all the data in XLS or XML format that would have been easy to import into MySQL, but I really wanted the data to be seeded through Laravel instead. That way, it’s much easier to push the seeder to git and migrate all tables on a server or other machine in the future.

I thought it could be useful to other developers in Belgium as well, so here you go,...

read more »