I hereby claim:
- I am joeyblake on github.
- I am joeyblake (https://keybase.io/joeyblake) on keybase.
- I have a public key whose fingerprint is DE24 0AE3 4CCD 38A5 2BF6 CF41 96F2 ADE8 0680 4686
To claim this, I am signing this object:
git submodule update --init --recursive |
<?php | |
add_filter( 'carbon_fields_attachment_id_from_url' , __NAMESPACE__ . '\get_attachment_id_from_url', 10, 2 ); | |
function get_attachment_id_from_url( $attachment_id, $url ) { | |
if ( 0 === $attachment_id ) { | |
$dir = wp_upload_dir(); | |
$filename = basename( $url ); | |
$filename = str_replace( [ '.doc', '.pdf', '.xls' ], [ '-doc', '-pdf', '-xls' ], $filename ); | |
$filename .= '.jpg'; |
//row markup | |
$row = '<div class="row-fluid">%s</div>' | |
//$posts = whatever you are trying to put in a grid. | |
$span_divs = array(); | |
foreach ( $posts as $post ) { | |
//make a span box | |
$span_divs[] = sprintf( "<div class="span4">%s</div>" , $post); | |
} | |
//chunk the array of grid items into a number if items |
# BEGIN Cache Enabler | |
# | |
# This version is meant for Apache 2.3.9 or later. | |
# | |
# Reference: https://www.keycdn.com/support/wordpress-cache-enabler-plugin#apache | |
<IfModule mod_rewrite.c> | |
RewriteEngine On | |
RewriteBase / | |
# set blog sub path |
I hereby claim:
To claim this, I am signing this object:
/* | |
* redirect all subdomains example | |
* example domain name testsite.com | |
*/ | |
// split the incoming host to get the first element | |
var incoming = req.headers.host.split('.')[0]; | |
// check if it matches your domain | |
if ( incoming !== 'testsite' ) { |
#!/bin/bash | |
# copy this file to /usr/sbin | |
# if you have other hosts entries that you would not like to lose, make sure they get added to the hosts.mamp.bak file | |
cat /etc/hosts.mamp.bak > /etc/hosts | |
echo 'clean!' |
# ----------------------------------------------------------------- | |
# .gitignore for WordPress | |
# Bare Minimum Git | |
# http://ironco.de/bare-minimum-git/ | |
# ver 20150227 | |
# | |
# This file is tailored for a WordPress project | |
# using the default directory structure | |
# | |
# This file specifies intentionally untracked files to ignore |
<?php | |
/* | |
Plugin Name: R Debug | |
Description: Set of dump helpers for debug. | |
Author: Andrey "Rarst" Savchenko | |
Author URI: http://www.rarst.net/ | |
License: MIT | |
*/ | |
/** |
add_filter('sp_auto_flush_fb', '__return_false'); |