Skip to content

Instantly share code, notes, and snippets.

@davekelly
davekelly / README.md
Last active Oct 26, 2016 — forked from silviaegt/README.md
Bibliographic metadata sunburst
View README.md

metadata_sunburst

An attempt to visualize bibliographic (Dewey) metadata with D3 based on Kerry Rodden's Sunburst

View keybase.md

Keybase proof

I hereby claim:

  • I am davekelly on github.
  • I am davekelly (https://keybase.io/davekelly) on keybase.
  • I have a public key ASBPbBvtc0vKV14XahM8mmiDIwlBZP30bTyACX8V-2Zl0Qo

To claim this, I am signing this object:

@davekelly
davekelly / 0_reuse_code.js
Last active Aug 29, 2015
Here are some things you can do with Gists in GistBox.
View 0_reuse_code.js
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
View README.md
View index.html
<!DOCTYPE html>
<html>
<head>
<title>Map</title>
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js"></script>
<style type="text/css">
svg {
background: #eee;
}
@davekelly
davekelly / WordPress URL Update SQL
Created Aug 19, 2013
Update all urls in a WordPress database. Used when migrating a site from one server to another (for example, test to production)
View WordPress URL Update SQL
UPDATE wp_options SET option_value = replace(option_value, 'http://www.old-url.com', 'http://new-url.com') WHERE option_name = 'home' OR option_name = 'siteurl';
UPDATE wp_posts SET guid = replace(guid, 'http://www.old-url.com','http://new-url.com');
UPDATE wp_posts SET post_content = replace(post_content, 'http://www.old-url.com', 'http://new-url.com');
@davekelly
davekelly / gist:3918937
Created Oct 19, 2012
Add Intercom.io snippet to Magento site
View gist:3918937
<?php
/*
* /app/design/frontend/default/your_theme/template/page/intercom-io.phtml
*/
// Settings for the intercom.io app.
if( $this->helper('customer')->isLoggedIn() ): ?>
<?php $customer = Mage::helper('customer')->getCustomer()->getData(); ?>
<script id="IntercomSettingsScriptTag">
@davekelly
davekelly / gist:2769687
Created May 22, 2012
Add a custom field to a Custom Taxonomy (WordPress)
View gist:2769687
<?php
/**
* Used to attach a gallery shortcode to a custom taxonomy (but has more general uses)
*
* Uses code from:
* @link http://sabramedia.com/blog/how-to-add-custom-fields-to-custom-taxonomies
*/
// in functions.php / custom post setup file...
@davekelly
davekelly / gist:2354729
Created Apr 10, 2012
Settings for Nettuts+ Fetch SublimeText Plugin
View gist:2354729
// http://net.tutsplus.com/articles/news/introducing-nettuts-fetch/
// Config settings for commonly used files & packages
{
"files":
{
"jquery": "http://code.jquery.com/jquery.min.js"
},
"packages":
{
"bootstrap": "https://github.com/twitter/bootstrap/zipball/master",
You can’t perform that action at this time.