file

9th February 2016
Extracting a database from a large mysqldump file

Extracting a database from a large mysqldump file

Restoring a single database from a large mysql dump is pretty easy, using the mysql command line client’s –one-database option: mysql -u root -p --one-database db_to_restore < fulldump.sql But what if you don’t want to restore the database, you just want to extract it out of the dump file? Well, that happens to be easy as […]... read the rest »
27th March 2015
The correct way to handle file downloads in PHP

The correct way to handle file downloads in PHP

I’ve seen many download scripts written in PHP, from simple one-liners to dedicated classes. At least half of them share common issues; in many cases programmers simply copy the code from something that works, without even attempting to understand what it really does... read the rest »