Skip to content

Instantly share code, notes, and snippets.

Keybase proof

I hereby claim:

  • I am nagarjun on github.
  • I am nagarjunp (https://keybase.io/nagarjunp) on keybase.
  • I have a public key ASDxsZlu6v48W6kkgBPjqak6bo7c7avu2DJthz8kx4FVGgo

To claim this, I am signing this object:

@nagarjun
nagarjun / aircraftIcaoIata.json
Created April 26, 2016 08:27
List of ICAO and IATA aircraft type designators
[
{
"icaoCode": "A124",
"iataCode": "A4F",
"description": "Antonov AN-124 Ruslan"
},
{
"icaoCode": "A140",
"iataCode": "A40",
"description": "Antonov AN-140"
@nagarjun
nagarjun / timezone.js
Created October 22, 2015 16:11
JSON of timezone offsets and their timezone strings.
var zones = {
"-12:00" : "Etc/GMT-12",
"-11:00" : "Etc/GMT-11",
"-11:00" : "Pacific/Midway",
"-10:00" : "America/Adak",
"-09:00" : "America/Anchorage",
"-09:00" : "Pacific/Gambier",
"-08:00" : "America/Dawson_Creek",
"-08:00" : "America/Ensenada",
"-08:00" : "America/Los_Angeles",
@nagarjun
nagarjun / gist:230ab547f3a50801f2ee
Last active August 29, 2015 14:10 — forked from etozzato/gist:85da5cb66ab935d06ebf
Destroy any jQuery click handlers that have been set before transitioning to a different route.
// in the component's didInsertElement
$(window).on('resize', function() {
return Em.run.debounce(that, 'resizeWindow', 250);
});
// in the route's willTransition
actions: {
willTransition: function() {
$(window).off('resize');
}
@nagarjun
nagarjun / getTitle.php
Created November 10, 2013 09:20
Get the Title by passing the URL using PHP.
/**
* Get the contents of Title tag from URL.
*/
function get_title($URL)
{
// Set the user agent so external servers don't block us.
ini_set('user_agent', 'Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.11) Gecko/2009060215 Firefox/3.0.11');
$page_contents = file_get_contents($URL);