PHP Classes

File: resources/views/index.blade.php

Recommend this page to a friend!
  Classes of adam berger   Laravel Privacy User Cookie   resources/views/index.blade.php   Download  
File: resources/views/index.blade.php
Role: Auxiliary script
Content type: text/plain
Description: Auxiliary script
Class: Laravel Privacy User Cookie
Show message to ask user permission to use cookies
Author: By
Last change: Update index.blade.php
Date: 1 year ago
Size: 1,997 bytes


Class file image Download
.cookis-box {
  background: #000000;
  color: #FFF;
  opacity: 0.9;
  width: 80%;
  top: 20px;
  left: 10%;
  z-index: 9999;
  height: 400px;
  position: fixed;/* Stoi w jednym miejscu niezaleznie od strony */
.cookis-box .container {
  text-align: center;
  margin-top: 20px;
  padding-top: 20px;
  padding-bottom: 20px;

.cookis-box .cookie-history{
  padding: 10px;
  cursor: pointer;

<div class="cookis-box">
    <div class="cookis-history">
        <i class="bi bi-clock-history"></i>
    <div class="container">
        <div class="card bg-dark">
            <div class="card-header text-center h2">
                <h2>Polityka Prywatno?ci Cookis</h2>
            <div class="card-body">
                <p class="card-text">Witaj Nieznajomy.</p>
                <p class="card-text">Je?eli chcesz zosta? i przegl?da? dalej stron? to zakceptuj ( Cookie! ).</p>
                <p class="card-text">Ca?y Polityka Prywatno?ci tu: <a href="{{ route("politykaPrywatnosci") }}">Polityka Prywatno?ci</a></p>
            <div class="card-footer">
              <button type="button" class="btn btn-danger py-3 accept-cookis">Zezwalaj na cookis!</button>
    const nameCookis = '{{ $cookis[1] }}';
    const coc = '{{ $cookis[0] }}';

    if(coc != 1 || coc == 'undefined'){
    function setCookis(name) {
                const value = '{{ $cookis[2] }}';
              // Save
                document.cookie = name + '=' + value
                    + '; max-age='+(360 * 24 * 60 * 60)
                    + '; path=/'
                    + '; samesite= Lax';