PHP code example of hopefeda / cookielize

1. Go to this page and download the library: Download hopefeda/cookielize library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

hopefeda / cookielize example snippets


php artisan vendor:publish  --provider=hopefeda\Cookielize\CookielizeServiceProvider

// Example


namespace App\Http\Controllers;

use Illuminate\Http\Request;
use Cookielize;

class TestController extends Controller
{
    public function something()
    {
		if (Cookielize::LocaleSupported('en')) {
			// do something
		}
        return Cookielize::LocaleRoute('en');
    }
}