ssh <server>
This file contains 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 | |
function cpm_create_order($customer_data, $the_customer) { | |
global $woocommerce; | |
$product_id = $customer_data['sub_product']; | |
$variation_id = $customer_data['sub_variation']; | |
$user_first_name = $customer_data['first_name']; | |
$user_last_name = $customer_data['last_name']; | |
$user_email = $customer_data['user_email']; | |
$billing_email = $customer_data['user_email']; | |
$billing_state = $customer_data['cpm_state']; |
This file contains 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
#!/bin/bash | |
# usage: "newgit some/path" | |
newgit() { | |
### SETTINGS ### | |
# this is the root of all your git folders | |
local LOCAL_GIT_ROOT=~/web | |
# this is your ssh [user]@[host] |
This file contains 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
var gulp = require('gulp'); | |
// Include Our Plugins | |
var jshint = require('gulp-jshint'); | |
var sass = require('gulp-sass'); | |
var concat = require('gulp-concat'); | |
var uglify = require('gulp-uglify'); | |
var minifyCSS = require('gulp-minify-css'); | |
var rename = require('gulp-rename'); | |
var yuidoc = require("gulp-yuidoc"); |
This file contains 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
// transform cropper dataURI output to a Blob which Dropzone accepts | |
function dataURItoBlob(dataURI) { | |
var byteString = atob(dataURI.split(',')[1]); | |
var ab = new ArrayBuffer(byteString.length); | |
var ia = new Uint8Array(ab); | |
for (var i = 0; i < byteString.length; i++) { | |
ia[i] = byteString.charCodeAt(i); | |
} | |
return new Blob([ab], { type: 'image/jpeg' }); | |
} |
This file contains 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
/* | |
* Translated default messages for the jQuery validation plugin. | |
* Locale: PT_BR | |
*/ | |
jQuery.extend(jQuery.validator.messages, { | |
required: "Este campo é requerido.", | |
remote: "Por favor, corrija este campo.", | |
email: "Por favor, forneça um endereço eletrônico válido.", | |
url: "Por favor, forneça uma URL válida.", | |
date: "Por favor, forneça uma data válida.", |
This file contains 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 Deployer; | |
require 'recipe/laravel.php'; | |
// Project name | |
set('application', ''); | |
// Project repository | |
set('repository', 'git@bitbucket.org'); |
This file contains 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 | |
/* | |
Increase or decrease value in CakePHP with little footprint. | |
Add this to your AppModel. | |
Usage: | |
(in Controller) | |
$this->Model->increase('field_name', 1); |
This file contains 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
#!/bin/bash -e | |
clear | |
echo "============================================" | |
echo "WordPress Install Script" | |
echo "============================================" | |
echo "Database Name: " | |
read -e dbname | |
echo "Database User: " | |
read -e dbuser | |
echo "Database Password: " |
This file contains 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
SUBSYSTEMS=="input", ATTRS{name}=="Keychron K2", RUN+="/bin/sh -c 'echo 0 > /sys/module/hid_apple/parameters/fnmode'" |
OlderNewer