Fix the pln import commands that I broke

This PR will fix the import commands that I broke. It's very large because I merged master into the plnimportercommand branch, to get it current with master. I would have done a rebase, but that would have rewritten history, and that's bad. Only 165521f, 846cac3, and 25aad75 are relevant.

This PR fails the Travis build process, because it uses some PHP 5.4-specific syntax.