Skip to content

Instantly share code, notes, and snippets.

View marcosfreitas's full-sized avatar
🔥
Looking forward

Marcos Freitas marcosfreitas

🔥
Looking forward
View GitHub Profile
@zenorocha
zenorocha / mussum-ipsum.sublime-snippet
Created October 2, 2012 18:48
Mussum Ipsum - Snippet para Sublime Text
<!-- Fonte: mussumipsum.com -->
<snippet>
<content><![CDATA[
Mussum ipsum cacilds, vidis litro abertis. Consetis adipiscings elitis. Pra lá , depois divoltis porris, paradis. Paisis, filhis, espiritis santis. Mé faiz elementum girarzis, nisi eros vermeio, in elementis mé pra quem é amistosis quis leo. Manduma pindureta quium dia nois paga. Sapien in monti palavris qui num significa nadis i pareci latim. Interessantiss quisso pudia ce receita de bolis, mais bolis eu num gostis.
Suco de cevadiss, é um leite divinis, qui tem lupuliz, matis, aguis e fermentis. Interagi no mé, cursus quis, vehicula ac nisi. Aenean vel dui dui. Nullam leo erat, aliquet quis tempus a, posuere ut mi. Ut scelerisque neque et turpis posuere pulvinar pellentesque nibh ullamcorper. Pharetra in mattis molestie, volutpat elementum justo. Aenean ut ante turpis. Pellentesque laoreet mé vel lectus scelerisque interdum cursus velit auctor. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Etiam ac mauris lectus, non scelerisque augu
@dwiash
dwiash / modify-woocommerce-breadcrumb.md
Created November 13, 2012 09:26
How to modify breadcrumb appearance in WooCommerce

How to modify breadcrumb appearance in WooCommerce

There are two files you need look around if you want to change your breadcrumb's appearance in WooCommerce. You'll find those files in your WooCommerce plugin directory:

  1. The first file: /woocommerce/woocommerce-template.php, this file contains function definition for woocommerce_breadcrumb()
  if ( ! function_exists( 'woocommerce_breadcrumb' ) ) {

	/**
 * Output the WooCommerce Breadcrumb
@pgchamberlin
pgchamberlin / MutationObserverLogger.js
Created December 5, 2012 17:47
Snippet that logs DOM mutations using the MutationObserver API
<script type="text/javascript">
// See MDN: https://developer.mozilla.org/en-US/docs/DOM/MutationObserver?redirectlocale=en-US&redirectslug=DOM%2FDOM_Mutation_Observers
(function(){
// select the target node
var target = document.querySelector('body');
var MutationObserver = window.MutationObserver || window.WebKitMutationObserver || window.MozMutationObserver;
var i=0;
// create an observer instance
var observer = new MutationObserver(function(mutations) {
@alixaxel
alixaxel / y.php
Last active October 13, 2016 12:41
Why...
<?php
namespace alixaxel;
class y
{
public static function Coalesce()
{
foreach (func_get_args() as $argument) {
if (isset($argument) === true) {
@babrath
babrath / fb_delete_allgroupmembers.js
Last active December 18, 2015 07:00 — forked from adriaanm/fb_delete_allgroupmembers.js
Some javascript code that allows you to automatically delete all members from a facebook group.
// first go to https://www.facebook.com/groups/XXXX/members/
// then paste this in the javascript console
deleteAll = [];
deleteAll.elms = [];
deleteAll.canClick = function (el) {
return (typeof el != 'undefined') && (typeof el.click != 'undefined');
}
deleteAll.load = function() {
@isGabe
isGabe / wordpress-force-login.php
Created June 21, 2013 16:10
WordPress: force log in to view any page, with redirect to requested URL#snippet #WordPress
<?php
/*
* Password protect a WordPress site, with a redirect to the requested URL after successful login
*
* Based on:
* http://wordpress.stackexchange.com/a/64999
* http://kovshenin.com/2012/current-url-in-wordpress/
*
**/
@guimadaleno
guimadaleno / brazilStates.html
Last active June 8, 2019 15:22
Select com os estados do Brasil - Select with Brazilian states
<select>
<option value="">Selecione</option>
<option value="AC">Acre</option>
<option value="AL">Alagoas</option>
<option value="AP">Amapá</option>
<option value="AM">Amazonas</option>
<option value="BA">Bahia</option>
<option value="CE">Ceará</option>
<option value="DF">Distrito Federal</option>
<option value="ES">Espirito Santo</option>
@mcaskill
mcaskill / Function.Array-Group-By.php
Last active January 3, 2024 10:15
PHP : Groups an array by a given key
<?php
if (!function_exists('array_group_by')) {
/**
* Groups an array by a given key.
*
* Groups an array into arrays by a given key, or set of keys, shared between all array members.
*
* Based on {@author Jake Zatecky}'s {@link https://github.com/jakezatecky/array_group_by array_group_by()} function.
* This variant allows $key to be closures.
@wilcorrea
wilcorrea / db.sql
Last active November 10, 2016 16:18
CREATE TABLE `clientes` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`nome` varchar(500) NOT NULL,
PRIMARY KEY (`id`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1
@BBlackwo
BBlackwo / kraken.fish
Created March 1, 2017 08:05
Open GitKraken from the terminal
## Forked from https://gist.github.com/dersam/0ec781e8fe552521945671870344147b
## Also received help from https://twitter.com/gitkraken/status/691675309725368321
## Open GitKraken using the current repo directory.
## This code is for fish shell. The same thing can be done in bash
## by creating an alias with the command below.
## `1>/dev/null` directs logs from the terminal
## `&` allows use of the same terminal instance to do other things