Skip to content

Instantly share code, notes, and snippets.

View juanbzpy's full-sized avatar
🎯
Focusing

juan bz juanbzpy

🎯
Focusing
View GitHub Profile
@juanbzpy
juanbzpy / social-sharing-alignment.html
Created August 30, 2012 23:04 — forked from thebigreason/social-sharing-alignment.html
Align Facebook Like, Twitter Tweet and Google +1 buttons
<div class="social">
<span class="twitter">
<a href="http://twitter.com/share" class="twitter-share-button" data-url="[your-url-here]">Tweet</a>
</span>
<span class="google">
<g:plusone size="medium" href="[your-url-here]"></g:plusone>
</span>
<span class="Facebook">
<iframe src="https://www.facebook.com/plugins/like.php?href=[your-url-here]&amp;show_faces=false&amp;layout=button_count" scrolling="no" frameborder="0" style="height: 21px; width: 100px" allowTransparency="true"></iframe>
</span>
/*!
* quantize.js Copyright 2008 Nick Rabinowitz.
* Licensed under the MIT license: http://www.opensource.org/licenses/mit-license.php
*/
// fill out a couple protovis dependencies
/*!
* Block below copied from Protovis: http://mbostock.github.com/protovis/
* Copyright 2010 Stanford Visualization Group
* Licensed under the BSD License: http://www.opensource.org/licenses/bsd-license.php
@juanbzpy
juanbzpy / demo.html
Created December 31, 2012 07:08 — forked from njonsson/demo.html
<?xml version='1.0' encoding='utf-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html lang='en-US' xml:lang='en-US' xmlns='http://www.w3.org/1999/xhtml'>
<head>
<title>
passwordComplexity jQuery plugin demo
</title>
<style type='text/css'>
* {
font-family: Helvetica, Arial, sans-serif;
var app = app || {};
//object literal
app = {
init: function(){
this.cache();
this.bind();
},
cache: function(){
this.anchor = $( 'a' );
// Source: http://ianstormtaylor.com/oocss-plus-sass-is-the-best-way-to-css/
// Sass
%separator
border-top: 1px solid black
hr
@extend %separator
.separator
@extend %separator

Moving from jQuery

Events

// jQuery
$(document).ready(function() {
  // code
})
var app = app || {};
//object literal
app = {
init: function(){
this.cache();
this.bind();
},
cache: function(){
this.anchor = $( 'a' );
<html>
<body style="padding:0; margin:0;">
<!-- reloader.html -->
<iframe id=reloader src="/" style="margin:0;border:none;padding:0;height:100%;width:100%"></iframe>
<script>
(function test() {
document.getElementById('reloader').src = document.getElementById('reloader').src;
setTimeout(test, 500); // 500ms = 1/2 second
})();
</script>
if (typeof window.localStorage == 'undefined' || typeof window.sessionStorage == 'undefined') (function () {
var Storage = function (type) {
function createCookie(name, value, days) {
var date, expires;
if (days) {
date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
expires = "; expires="+date.toGMTString();

tmux cheatsheet

As configured in my dotfiles.

start new:

tmux

start new with session name: