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
jQuery.validator.addMethod("cnpj", function (cnpj, element) { | |
cnpj = jQuery.trim(cnpj); | |
// DEIXA APENAS OS NÚMEROS | |
cnpj = cnpj.replace('/', ''); | |
cnpj = cnpj.replace('.', ''); | |
cnpj = cnpj.replace('.', ''); | |
cnpj = cnpj.replace('-', ''); | |
var numeros, digitos, soma, i, resultado, pos, tamanho, digitos_iguais; |
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
## | |
# Ubuntu Server 12.04 64bits | |
# Automatiza o acesso SSH | |
# Oh my ZSH | |
# Shorewall | |
# PostFix (Enviar e-mails) | |
# Memcached | |
# Redis | |
# Varnish | |
## |
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
SET @antigaURL = 'http://siteantigo.com'; | |
SET @novaURl = 'http://sitenovo.com'; | |
# Atualiza URL do site nas opções | |
UPDATE wp_options SET option_value = replace(option_value, @antigaURL, @novaURL); | |
# Atualiza URL dos posts (e dentro deles) | |
UPDATE wp_posts SET guid = REPLACE (guid, @antigaURL, @novaURL); | |
UPDATE wp_posts SET post_content = REPLACE (post_content, @antigaURL, @novaURL); | |
UPDATE wp_posts SET post_excerpt = REPLACE (post_excerpt, @antigaURL, @novaURL); |
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
## | |
# Ubuntu Server 12.04 64bits | |
# Automatiza o acesso SSH | |
# Oh my ZSH | |
# Shorewall | |
# PostFix (Enviar e-mails) | |
# Memcached | |
# Redis | |
# Varnish | |
## |
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
# ############### | |
# SETUP LOCAL | |
# ############### | |
cd $LOCAL/$SITE | |
git init | |
git config color.branch auto | |
git config color.diff auto | |
git config color.interactive auto | |
git config color.status auto |