diff --git a/README.md b/README.md index ecc8e39..eac492b 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ Update your `composer` require block: # Usage ```php -use pubsubhubbub\subscriber\Subscriber; +use \Pubsubhubbub\Subscriber\Subscriber; $hub_url = "http://pubsubhubbub.appspot.com"; $callback_url = "put your own endpoint here"; diff --git a/composer.json b/composer.json index f92be53..c5c88d0 100644 --- a/composer.json +++ b/composer.json @@ -15,6 +15,6 @@ "php": "~5.4 || ~7.0" }, "autoload": { - "psr-4": { "pubsubhubbub\\subscriber\\": "src/" } + "psr-4": { "Pubsubhubbub\\Subscriber\\": "src/" } } } diff --git a/example.php b/example.php index dc1dbea..6624943 100644 --- a/example.php +++ b/example.php @@ -7,13 +7,15 @@ include("./src/Subscriber.php"); +use \Pubsubhubbub\Subscriber\Subscriber; + $hub_url = "http://pubsubhubbub.appspot.com"; $callback_url = "put your own endpoint here"; $feed = "http://feeds.feedburner.com/onlineaspect"; // create a new subscriber -$s = new Pubsubhubbub\Subscriber\Subscriber($hub_url, $callback_url); +$s = new Subscriber($hub_url, $callback_url); // subscribe to a feed $s->subscribe($feed);