PHPnews.io

Overview for 'roballen'

SSH keys in macOS Sierra

Written by Rob Allen / Original link on Dec. 27, 2016

Now that I've upgraded to macOS 10.12 Sierra, I noticed that SSH required me to enter my passphrase to keys every time I used them. This was a surprise as it's not how 10.11 El Capitan worked.This is how to fix it.Firstly, add your SSH key's passphrase to the keychain using ssh-add -K ~/.ssh/id_rsa…


Handling JSON data errors in Slim 3

Written by Rob Allen / Original link on Nov. 16, 2016

When you send JSON data into a Slim Framework application with a content-type of application/json, then Slim will decode it for you if you use getParsedBody():$app->post("/", function ($request, $response, $args) { $input = $request->getParsedBody(); var_dump($input);exit;});Using curl…


Use curl to create a CouchDB admin user

Written by Rob Allen / Original link on Oct. 5, 2016

This too me longer to find than it should have done, so I'm writing it here for future me.When you install CouchDB, it is in a mode where anyone can do anything with the database including creating and deleting databases. This is called "Admin Party" mode which is a pretty cool name, but not what I…


PHPNW 2016 API Tutorial

Written by Rob Allen / Original link on Sep. 28, 2016

If you're attending my Building Modern APIs in PHP tutorial at PHPNW 2016, please bring a laptop with the following installed:* PHP 7 with the sqlite extension installed* curl command line tool* https://akrabat.com/stuff/2016-09-30-PHPNW-Slim-API-Tutorial.zip extracted to a convenient directoryThan…