From 184dae595cbc004a2d206526fdef7973031918f2 Mon Sep 17 00:00:00 2001 From: PJ Dietz Date: Fri, 1 Feb 2013 21:38:23 -0500 Subject: [PATCH] Add license to README Fix typos Update composer install sample code to reflect new version --- README.md | 20 +++++++++++++------- composer.json | 2 +- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index d47b83d..176189d 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ Add an entry for "pjdietz/wellrested" to your composer.json file's **require** p ```json { "require": { - "pjdietz/wellrested": "dev-master" + "pjdietz/wellrested": "1.*" } } ``` @@ -43,7 +43,7 @@ Examples ### Responses -Use a Response instance to build a response and send output. The Request class makes it easy to set the status code, add headers, and set the response body. +Use a Response instance to build a response and send output. The Response class makes it easy to set the status code, add headers, and set the response body. ```php $resp = new \pjdietz\WellRESTed\Response(); @@ -56,9 +56,9 @@ exit; ### Requests -Use the Request class read information about the request sent to the server. You can ready the headers, method, and message body. +Use the Request class to read information about the request sent to the server. You can read the headers, method, and message body. -Request provides a singlton instance representing the request sent to the current script. +Request provides a singleton instance representing the request sent to the current script. ```php $rqst = \pjdietz\WellRESTed\Request::getRequest(); @@ -92,7 +92,7 @@ if ($resp->statusCode === 201) { WellRESTed also provides several classes to facilitate working with resource-based URIs. You can create your own regular expressions to match the URIs, or you can use URI templates. -Here's an example of a Router subclass which examines the request URI, compares it against a series of URI templates, and matches the request to a particular Handler class. +Here's an example of a Router subclass. The subclass examines a request URI, compares it against a series of URI templates, and matches the request to a particular Handler class. For more information on URI templates, see [RFC 6570](http://tools.ietf.org/html/rfc6570). @@ -107,7 +107,7 @@ class MyRouter extends \pjdietz\WellRESTed\Router parent::__construct(); // Match any request to the URI "/things/" - // Send it to a handler to collections of thing objects. + // Send it to a handler for collections of thing objects. $this->addRoute(Route::newFromUriTemplate('/things/', 'ThingCollectionHandler')); // Match any request to "/things/" followed by a variable. @@ -122,7 +122,13 @@ class MyRouter extends \pjdietz\WellRESTed\Router ``` -More explamples +More Examples --------------- For more examples, see the project [pjdietz/wellrested-samples](https://github.com/pjdietz/wellrested-samples). + + +Copyright and License +--------------------- +Copyright © 2013 by PJ Dietz +Licensed under the [MIT license](http://opensource.org/licenses/MIT) \ No newline at end of file diff --git a/composer.json b/composer.json index 7fdb744..f7efe7d 100644 --- a/composer.json +++ b/composer.json @@ -1,7 +1,7 @@ { "name": "pjdietz/wellrested", "description": "Simple PHP Library for RESTful APIs", - "keywords": ["php", "rest", "restful", "api"], + "keywords": ["rest", "restful", "api", "curl", "http"], "homepage": "https://github.com/pjdietz/wellrested", "type": "library", "authors": [