Skip to content

Instantly share code, notes, and snippets.

View gabrielfroes's full-sized avatar

Gabriel Froes gabrielfroes

View GitHub Profile
@gabrielfroes
gabrielfroes / slugify.js
Last active February 6, 2024 23:36 — forked from mathewbyrne/slugify.js
Javascript Slugify
/*
Create SLUG from a string
This function rewrite the string prototype and also
replace latin and other special characters.
Forked by Gabriel Froes - https://gist.github.com/gabrielfroes
Original Author: Mathew Byrne - https://gist.github.com/mathewbyrne/1280286
*/
if (!String.prototype.slugify) {
String.prototype.slugify = function () {
@gabrielfroes
gabrielfroes / emailmask.js
Created February 21, 2018 14:57
Javascript Email Mask
/*
Create a Mask in an email address
This function create a mask using a valid email address.
This is usefull when someone need to confirm the email used in a system
Author: Gabriel Froes - https://gist.github.com/gabrielfroes
*/
function emailMask(email) {
var maskedEmail = email.replace(/([^@\.])/g, "*").split('');
var previous = "";
for(i=0;i<maskedEmail.length;i++){
@gabrielfroes
gabrielfroes / Gravatar.php
Created March 19, 2018 17:15
PHP client library for Gravatar
<?php
/*-----------------------------------------------------------------------------
* PHP client library for Gravatar
*
* Author: Gabriel Froes
* Copyright: (c) 2018 RW Studio
* License: BSD 3-Clause License
* See accompanying LICENSE file
*
* Version: 1.0
@gabrielfroes
gabrielfroes / Dockerfile
Created October 5, 2018 14:55
Docker + VS Code #CDFTV #MaoNoCodigo3
FROM php:7.2-apache
RUN docker-php-ext-install mysqli
RUN a2enmod rewrite
@gabrielfroes
gabrielfroes / capuccino-developer.php
Last active December 1, 2021 15:45
Recipe for Developer Daily Capuccino
<?php
/**
* Recipe for Developer Daily Capuccino
*
* @author Gabriel Froes & Vanessa Weber <[email protected]>
* @version 1.0
* @copyright GPL © 2018, youtube.com/codigofontetv
* @access public
* @package CDFTV\Recipes
* @example Classe CapuccinoDev.