PHP Class Spatie\CookieConsent\CookieConsentMiddleware

Show file Open project: spatie/laravel-cookie-consent

Protected Properties

Property Type Description
$app Illuminate\Contracts\Foundation\Application

Public Methods

Method Description
__construct ( Illuminate\Contracts\Foundation\Application $app )
handle ( Illuminate\Http\Request $request, Closure $next ) : mixed

Protected Methods

Method Description
addCookieConsentScriptToResponse ( Illuminate\Http\Response $response )
containsBodyTag ( Illuminate\Http\Response $response ) : boolean
getLastClosingBodyTagPosition ( string $content = '' ) : integer | boolean

Method Details

__construct() public method

public __construct ( Illuminate\Contracts\Foundation\Application $app )
$app Illuminate\Contracts\Foundation\Application

addCookieConsentScriptToResponse() protected method

protected addCookieConsentScriptToResponse ( Illuminate\Http\Response $response )
$response Illuminate\Http\Response

containsBodyTag() protected method

protected containsBodyTag ( Illuminate\Http\Response $response ) : boolean
$response Illuminate\Http\Response
return boolean

getLastClosingBodyTagPosition() protected method

protected getLastClosingBodyTagPosition ( string $content = '' ) : integer | boolean
$content string
return integer | boolean

handle() public method

public handle ( Illuminate\Http\Request $request, Closure $next ) : mixed
$request Illuminate\Http\Request
$next Closure
return mixed

Property Details

$app protected property

protected Application,Illuminate\Contracts\Foundation $app
return Illuminate\Contracts\Foundation\Application