Playing with D3.js to get a drill down behavior for a hierarchical data collection represented in pie charts. See live example
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
# 0 is too far from ` ;) | |
set -g base-index 1 | |
# Automatically set window title | |
set-window-option -g automatic-rename on | |
set-option -g set-titles on | |
#set -g default-terminal screen-256color | |
set -g status-keys vi | |
set -g history-limit 10000 |
When times get tough and people get nasty, you’ll need more than a killer smile. You’ll need a killer contract.
Used by 1000s of designers and developers Clarify what’s expected on both sides Helps build great relationships between you and your clients Plain and simple, no legal jargon Customisable to suit your business Used on countless web projects since 2008
…………………………
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
# ~/.gitconfig | |
# Add this to your global git configuration file | |
# Change phpstorm to webstorm, if you use that. | |
# Diff and merge tool changes | |
# Run `git difftool <directory/file>...` or `git mergetool <directory/file>...` | |
[merge] | |
tool = phpstorm | |
[diff] | |
tool = phpstorm |
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
# Railscast | |
http://railscasts.com/episodes/308-oh-my-zsh | |
# Install Zsh | |
sudo apt-get update && sudo apt-get install zsh | |
# Install Oh-my-zsh | |
wget –no-check-certificate https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O – | sh | |
# Make ZSH default shell |
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
//This would be good for setting up a stock dev environment. So instead of dumping in a DB, you would run an initializer with options | |
$users[0] = array( | |
'first_name' => 'Daniel', | |
'last_name' => 'Pataki', | |
'user_login' => 'danielpataki', | |
'user_pass' => 'mysupersecretpass', | |
'user_email' => 'mysupermail@mymail.com', | |
'display_name' => 'Daniel', | |
'description' => 'Guitar-wielding Web developer', |
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
/** | |
* Disable admin bar on the frontend of your website | |
* for subscribers. | |
*/ | |
function themeblvd_disable_admin_bar() { | |
if( ! current_user_can('edit_posts') ) | |
add_filter('show_admin_bar', '__return_false'); | |
} | |
add_action( 'after_setup_theme', 'themeblvd_disable_admin_bar' ); | |
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
add_filter( 'all_plugins', 'hide_plugin_list' ); | |
function hide_plugin_list( $plugins ) { | |
if ( is_admin() ) { | |
//Only run this if we're in the Admin panels | |
unset( $plugins[ 'advanced-custom-fields/acf.php'] ); | |
//Admin only plugins | |
if ( ! current_user_can( 'administrator' ) ) { | |
unset( $plugins[ 'better-wp-security/better-wp-security.php'] ); |
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 | |
add_filter('upload_dir', 'mu_media_upload_dir'); | |
function mu_media_upload_dir($upload) { | |
$site_title=str_replace( ' ' , '_' , get_bloginfo('name','raw') ); | |
$upload['path'] = ABSPATH . '/shared/' . $site_title; | |
switch_to_blog(1); | |
$upload['url'] = site_url() . '/shared/' . $site_title; | |
restore_current_blog(); | |
$upload['subdir'] = ""; | |
$upload['basedir'] = $upload['path']; |
OlderNewer