This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Generate geo location using Ip Address | |
$user_ip = 'getenv('REMOTE_ADDR')'; | |
$geo = unserialize(file_get_contents("http://www.geoplugin.net/php.gp?ip=$user_ip")); | |
$country = $geo["geoplugin_countryName"]; | |
$city = $geo["geoplugin_city"]; | |
$lgn = $geo['geoplugin_longitude']; | |
$lat = $geo['geoplugin_latitude']; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* This code is licensed under the terms of the MIT license | |
* | |
* Deep diff between two object, using lodash | |
* @param {Object} object Object compared | |
* @param {Object} base Object to compare with | |
* @return {Object} Return a new object who represent the diff | |
*/ | |
function difference(object, base) { | |
function changes(object, base) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ansible RDS Multi-AZ Postgres | |
# | |
# Assumes existing Security Group, VPC, and RDS Subnet Groups. | |
# | |
# To install Ansible on OSX: | |
# sudo easy_install pip | |
# sudo pip install paramiko PyYAML jinja2 (might be prompted to install XCode & re-run) | |
# sudo pip install ansible | |
# sudo pip install boto | |
# sudo mkdir /etc/ansible |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if ( class_exists('EM_Gateway') ) : | |
class BraintreeGateway extends EM_Gateway { | |
var $gateway = 'braintree'; | |
var $title = 'BrainTree'; | |
var $status = 4; | |
var $status_txt = 'Processing (BrainTree)'; | |
var $button_enabled = false; | |
var $supports_multiple_bookings = true; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!doctype html> | |
<html ng-app="sampleKinveyApp"> | |
<head> | |
<meta charset="utf-8"> | |
<title>Bootstrap, from Twitter</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta name="description" content=""> | |
<meta name="author" content=""> | |
<!-- Le styles --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Marionette.Gauntlet v0.0.0 | |
// -------------------------- | |
// | |
// Build wizard-style workflows with an event-emitting state machine | |
// Requires Backbone.Picky (http://github.com/derickbailey/backbone.picky) | |
// | |
// Copyright (C) 2012 Muted Solutions, LLC. | |
// Distributed under MIT license | |
Marionette.Gauntlet = (function(Backbone, Picky, Marionette, $, _){ |