This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
class DateTimeFrench extends DateTime { | |
public function format($format='j M Y'){ | |
$days_full = array( | |
'Monday' => 'Lundi', | |
'Tuesday' => 'Mardi', | |
'Wednesday' => 'Mercredi', | |
'Thursday' => 'Jeudi', |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT id, ROUND( | |
( LENGTH(field) - LENGTH( REPLACE(field, "search", "") ) ) / LENGTH("search") | |
) AS count | |
FROM table |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Jours fériés en France | |
* Source : https://phpsources.net/code/php/date-heure/641_jours-feries-en-france | |
*/ | |
class FrenchHolidays { | |
public static function isHoliday($day=false, $alsacemoselle=false){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Page templates from plugin | |
* Plugin URI: | |
* Description: Page templates from plugin | |
* Version: 1.0.0 | |
* Author: Pierre Lebedel | |
* Author URI: https://www.pierrelebedel.fr | |
*/ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@php | |
if (! isset($scrollTo)) { | |
$scrollTo = 'body'; | |
} | |
$scrollIntoViewJsSnippet = ($scrollTo !== false) | |
? <<<JS | |
(\$el.closest('{$scrollTo}') || document.querySelector('{$scrollTo}')).scrollIntoView() | |
JS | |
: ''; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.flatpickr-calendar { | |
.numInputWrapper { | |
.arrowUp, | |
.arrowDown { | |
width: 20px; | |
padding: 0; | |
&:after { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@import "../../node_modules/@tabler/core/src/scss/tabler.scss"; | |
.table { | |
tfoot { | |
th { | |
color: $table-th-color; | |
background: $table-th-bg; | |
font-weight: var(--#{$prefix}font-weight-bold); | |
text-transform: uppercase; | |
letter-spacing: .04em; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
PUSHER_APP_ID=examplesite-appid | |
PUSHER_APP_KEY=examplesite-appkey | |
PUSHER_APP_SECRET=examplesite-appsecret | |
PUSHER_APP_CLUSTER=mt1 | |
PUSHER_HOST=www.examplesite.com | |
PUSHER_PORT=6001 | |
PUSHER_SCHEME=http | |
LARAVEL_WEBSOCKETS_PORT=443 | |
LARAVEL_WEBSOCKETS_VERIFY_PEER=false |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@servers([ | |
'staging' => '[email protected] -p 22', | |
'production' => '[email protected] -p 22', | |
]) | |
@setup | |
if (empty($server)) { | |
exit('ERROR: envoy run option --server is undefined'.PHP_EOL); | |
} | |
if($server=='production'){ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Providers; | |
use Illuminate\Support\Facades\Blade; | |
use Illuminate\Support\ServiceProvider; | |
final class ViewServiceProvider extends ServiceProvider | |
{ | |
public function boot(): void |
OlderNewer