Overview for 'roballen'

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 to…

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…

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 * extracted to a convenient directory…