Skip to content

Instantly share code, notes, and snippets.

View nncl's full-sized avatar

C. (Bruno) Almeida nncl

View GitHub Profile
@nncl
nncl / Stuff.md
Last active January 5, 2017 10:21

Stuff

  • Only english
    • HTML
    • CSS
    • JS
  • Sass
    • Directories's Structure
    • Nesting: 3
  • HTML/HTML5
@nncl
nncl / gist:82807d2da6df33eb4c97
Created December 4, 2015 20:21 — forked from jonathanmoore/gist:2640302
Get the share counts from various APIs

Share Counts

I have always struggled with getting all the various share buttons from Facebook, Twitter, Google Plus, Pinterest, etc to align correctly and to not look like a tacky explosion of buttons. Seeing a number of sites rolling their own share buttons with counts, for example The Next Web I decided to look into the various APIs on how to simply return the share count.

If you want to roll up all of these into a single jQuery plugin check out Sharrre

Many of these API calls and methods are undocumented, so anticipate that they will change in the future. Also, if you are planning on rolling these out across a site I would recommend creating a simple endpoint that periodically caches results from all of the APIs so that you are not overloading the services will requests.

Twitter

@nncl
nncl / Pictures from Facebook's Account Gallery.md
Last active December 3, 2015 14:01
It will teach you how to get a json document with pictures from a facebook's gallery.
@nncl
nncl / ie67891011-css-hacks.txt
Last active November 24, 2015 15:52 — forked from ricardozea/ie67891011-css-hacks.txt
IE CSS hacks - IE6, 7, 8, 9, 10, 11
IE6 Only
==================
_selector {...}
IE6 & IE7
==================
*html or { _property: }
IE7 Only
==================
@nncl
nncl / Be MEAN Instagram - MongoDB.md
Last active September 7, 2017 21:12
Be Mean Instagram

Be MEAN Instagram - MongoDB

Getting Started

Configure your CLI to MongoDB, bro:

$ 
@nncl
nncl / maps.md
Last active November 6, 2015 19:47
@nncl
nncl / PHP Varible to JS.md
Last active October 15, 2015 22:28
Getting a PHP variable with jQuery

#PHP Varible to JS

On your .php file, for example:

$var = 'My PHP variable';
echo $var;

And in our .js file we'll make a POST to get the data from PHP:

@nncl
nncl / WordPress Stuff.md
Last active November 29, 2016 18:28
Here we'll teach you how to do some useful stuff with WordPress.

Sass without Grunt/Gulp.md

  1. Run sass --watch style.scss:style.css
@nncl
nncl / IONIC Stuff.md
Last active December 28, 2015 19:27
Ionic stuff