Skip to content

Commit 46d5d47

Browse files
committed
Added doc on how to use and uses correct namespace
1 parent f0cff71 commit 46d5d47

File tree

1 file changed

+12
-3
lines changed

1 file changed

+12
-3
lines changed

Middleware/Jsonp.php

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,22 @@
22
/**
33
* JSONP Middleware Class for the Slim Framework
44
*
5-
* Simple class to wrap the response of the application in an JSONP callback function.
6-
* The class is triggered when a get parameter of callback is found
7-
*
85
* @author Tom van Oorschot <[email protected]>
96
* @since 17-12-2012
7+
*
8+
* Simple class to wrap the response of the application in a JSONP callback function.
9+
* The class is triggered when a get parameter of callback is found
10+
*
11+
* Usage
12+
* ====
13+
*
14+
* $app = new \Slim\Slim();
15+
* $app->add(new \Slim\Extras\Middleware\JSONPMiddleware());
16+
*
1017
*/
1118

19+
namespace Slim\Extras\Middleware;
20+
1221
class JSONPMiddleware extends \Slim\Middleware
1322
{
1423
public function call()

0 commit comments

Comments
 (0)