Skip to content

Instantly share code, notes, and snippets.

View tvachon's full-sized avatar

Todd Vachon tvachon

  • OnCourse Systems for Education
  • Media Pa
View GitHub Profile
@tvachon
tvachon / .block
Last active December 19, 2017 16:15
Heatmap
license: mit
@tvachon
tvachon / .block
Last active December 14, 2017 16:32
D3 v4 Sankey Diagram
license: mit
@tvachon
tvachon / .block
Last active December 14, 2017 16:32
D3 v4 100% stacked chart
license: mit
@tvachon
tvachon / .block
Last active December 14, 2017 16:33
D3 v3 Grouped Stacked Chart
license: mit
@tvachon
tvachon / index.html
Last active August 29, 2015 14:00
A touch-friendly HTML/CSS inertial scrolling div.
<!DOCTYPE html>
<meta charset="utf-8">
<head>
<style>
body {font-family: helvetica, arial, sans-serif;}
a {text-decoration: none;}
.window {
margin-top: 12px;
overflow-y: hidden;
@tvachon
tvachon / PHP image randomizer
Created September 27, 2013 14:21
GA trackable PHP image randomizer
<?php
$supportbox_array = array(
'<a href="GOOGLE-ANALYTICS-CAMPAIGN-LINK"><img src="IMAGE-LINK" style="margin: 0 auto;" alt="ALT-TAG" /></a>',
'<a href="GOOGLE-ANALYTICS-CAMPAIGN-LINK"><img src="IMAGE-LINK" style="margin: 0 auto;" alt="ALT-TAG" /></a>',
'<a href="GOOGLE-ANALYTICS-CAMPAIGN-LINK"><img src="IMAGE-LINK" style="margin: 0 auto;" alt="ALT-TAG" /></a>',
'<a href="GOOGLE-ANALYTICS-CAMPAIGN-LINK"><img src="IMAGE-LINK" style="margin: 0 auto;" alt="ALT-TAG" /></a>',
@tvachon
tvachon / iOS_scrolling_div.html
Created June 25, 2012 20:22
Scrolling div compatible with iOS
<!-- a div for text to accompany the image -->
<div style="margin-top:50px;">DESCRIPTION TEXT CAN GO HERE</div>
<!-- Create a 600px wide div as a viewport to a wider image. Let webkit know that it should scroll when touched on mobile. -->
<div id="framecont" style="background-color:#ffffff; height: 100%; width: 600px; overflow: scroll !important; -webkit-overflow-scrolling:touch !important;"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=yes">
<!-- Set pixel width in the div below to the width of your actual image -->
<div class="inside" style="width: 1000px;">
<img src="image1000px_wide.jpg" />
</div>
</div>