Skip to content

Instantly share code, notes, and snippets.

Thomas Petracco tompec

Block or report user

Report or block tompec

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
tompec / EmailLog.php
Created Jan 9, 2020
Laravel Nova resource for the EmailLog model from
View EmailLog.php
namespace App\Nova;
use Illuminate\Http\Request;
use Laravel\Nova\Fields\Boolean;
use Laravel\Nova\Fields\DateTime;
use Laravel\Nova\Fields\ID;
use Laravel\Nova\Fields\MorphOne;
use Laravel\Nova\Fields\Text;
tompec / mailchimp-newsletter-bulma.html
Created Oct 7, 2017
Simple Bulma template for Mailchimp embedded form with input group
View mailchimp-newsletter-bulma.html
<!DOCTYPE html>
<title>Mailchimp newsletter</title>
<link rel="stylesheet" href="" crossorigin="anonymous">
div.mce_inline_error {
color: red;
tompec / mailchimp-newsletter-bootstrap.html
Last active Apr 14, 2019
Simple Bootstrap template for Mailchimp embedded form with input group
View mailchimp-newsletter-bootstrap.html
<!DOCTYPE html>
<title>Mailchimp newsletter</title>
<link rel="stylesheet" href="" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
div.mce_inline_error {
color: red;
tompec / gist:bc546b2222b233e571bec987904a797b
Created Jun 22, 2017
Redirect IP to domain name in NGINX
View gist:bc546b2222b233e571bec987904a797b
server {
server_name 123.456.789.123;
return 301 $scheme://$request_uri;
tompec / gist:5d2d7b51c918c5c1429c503b9109b57b
Created May 20, 2017
Leverage browser caching for Nginx server
View gist:5d2d7b51c918c5c1429c503b9109b57b
server {
# Leverage browser caching
location ~* \.(jpg|jpeg|png|gif|ico|css|js|pdf)$ {
expires 7d;
tompec / bulma.blade.php
Last active Feb 8, 2020
Bulma blade template for Laravel 5.4 pagination
View bulma.blade.php
@if ($paginator->hasPages())
<nav class="pagination is-centered">
@if ($paginator->onFirstPage())
<a class="pagination-previous" disabled>Previous</a>
<a href="{{ $paginator->previousPageUrl() }}" rel="prev" class="pagination-previous">Previous</a>
@if ($paginator->hasMorePages())
<a class="pagination-next" href="{{ $paginator->nextPageUrl() }}" rel="next">Next</a>
You can’t perform that action at this time.