Instantly share code, notes, and snippets.

Govert Verschuur verschuur

View GitHub Profile
@verschuur
verschuur / PreventSEOIndexingHeaders.php
Created Nov 16, 2017
Laravel middleware code to add response headers to prevent SEO indexing.
View PreventSEOIndexingHeaders.php
<?php
namespace App\Http\Middleware;
use Closure;
class PreventSEOIndexingHeaders
{
/**
* Handle an incoming request.
@verschuur
verschuur / ViewComposerServiceProvider.php
Last active Nov 16, 2017
Laravel ViewComposerServiceProvider example with several registering options
View ViewComposerServiceProvider.php
<?php
namespace App\Providers;
use Illuminate\Support\Facades\View;
use Illuminate\Support\ServiceProvider;
class ViewComposerServiceProvider extends ServiceProvider
{
/**
@verschuur
verschuur / .htaccess
Created Jan 16, 2017
Handy dandy complete .htaccess
View .htaccess
# ----------------------------------------------------------------------
# | Basic rewrite settings
# ----------------------------------------------------------------------
<IfModule mod_rewrite.c>
<IfModule mod_negotiation.c>
Options -MultiViews
</IfModule>
RewriteEngine On