Skip to content

Instantly share code, notes, and snippets.

View rodrigobarona's full-sized avatar
🏠
Working from home

Rodrigo Barona rodrigobarona

🏠
Working from home
View GitHub Profile
/**********************************************
* Ink v1.0.5 - Copyright 2013 ZURB Inc *
**********************************************/
/* Client-specific Styles & Reset */
#outlook a {
padding: 0;
}
@rodrigobarona
rodrigobarona / gist:9242874
Last active August 29, 2015 13:56
Tracking Google Analytics on a 1 page website using hashtags
Generically, your code could look like this:
_gaq.push(['_trackPageview',location.pathname + location.search + location.hash]);
You could either bind that code to every time you have a hash change within your application,
or you could use a generic hashchange plugin (http://benalman.com/projects/jquery-hashchange-plugin/), that uses the HTML5 onhashchange, and some
backwards compatible hacks for older browsers, and bind this code to that event, so that it
fires every time your hash changes.
Using that plugin, your code could look like:

Google Speech To Text API

Base URL: https://www.google.com/speech-api/v1/recognize
It accepts POST requests with voice file encoded in FLAC format, and query parameters for control.

Query Parameters

client
The client's name you're connecting from. For spoofing purposes, let's use chromium

lang
Speech language, for example, ar-QA for Qatari Arabic, or en-US for U.S. English

<?php
/**
* A simple Facebook PHP example.
*
* - This is not a "Facebook SDK".
* - This example uses Curl, Hash, JSON, Session extensions.
* - This does not use the JavaScript SDK, nor the cookie set by it.
* - This works with Canvas, Page Tabs with IFrames, the Registration Plugin
* and with any other flow which uses the signed_request.
@rodrigobarona
rodrigobarona / gist:5712718
Created June 5, 2013 09:25
Cookies Legal EU
Our website uses delicious cookies to improve your experience. We'll assume you're ok with that.
(by http://etchapps.com/)
@rodrigobarona
rodrigobarona / gist:5547769
Created May 9, 2013 14:25
Rinning SASS on Chrome DevTools (see on video http://youtu.be/kVSo4buDAEE?t=18m1s)
On Chrome Canary Settings:
Experiments -> Support for Sass
General -> Enable source maps
General -> Auto-reload CSS upon Sass save
On Terminal:
$ sass --watch --scss --sourcemap sass:css
.sticky {
position: -webkit-sticky;
position: -moz-sticky;
position: -o-sticky;
position: -ms-sticky;
position: sticky;
}
@rodrigobarona
rodrigobarona / gist:5317658
Created April 5, 2013 08:43
Metadata - Data Updated / Created
<meta name="DC.Date.updated" content="2013-04-04" scheme="W3CDTF" />
+info: http://gsitecrawler.com/en/faq/info/date-meta-tag/
<!-- Smart Banner -->
<!-- Get ID from http://j.mp/XUmOng -->
<meta name="apple-itunes-app" content="app-id=XXXXXXXXX"/>
@rodrigobarona
rodrigobarona / gist:5187752
Created March 18, 2013 14:58
Meta Tag - Force latest IE rendering engine (even in intranet) & Chrome Frame
<!-- Always force latest IE rendering engine (even in intranet) & Chrome Frame -->
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">